Fixed AVRISP programmer demo -- can now connect to a target and read/write Sig/Lock/Fuse/OSCCAL bytes successfully.
Changed SPI_Init() to allow for the clock polarity and data sample modes to be set. Changed Dataflash_Init() to no longer call SPI_Init() automatically.
This commit is contained in:
@@ -84,7 +84,8 @@ void SetupHardware(void)
|
||||
|
||||
/* Hardware Initialization */
|
||||
LEDs_Init();
|
||||
Dataflash_Init(SPI_SPEED_FCPU_DIV_2);
|
||||
SPI_Init(SPI_SPEED_FCPU_DIV_2 | SPI_SCK_LEAD_FALLING | SPI_SAMPLE_TRAILING | SPI_MODE_MASTER);
|
||||
Dataflash_Init();
|
||||
USB_Init();
|
||||
|
||||
/* Clear Dataflash sector protections, if enabled */
|
||||
|
||||
Reference in New Issue
Block a user