Atmel ATSTK500 500 Starter kit and development system. ATSTK500 ATSTK500 Hoja De Datos

Los códigos de productos
ATSTK500
Descargar
Página de 37
 
18 
AVR068 
2591C-AVR-06/06 
Table 5-43. Valid Result Values for the answer to this command 
Values Description 
STATUS_CMD_OK Operation 
succeeded 
STATUS_RDY_BSY_ 
TOUT 
No response from target device within specified timeframe 
5.3.4.1 Mode byte description 
•  Bit 0: This bit indicates whether to use byte ‘0’ or page ‘1’ programming.  
•  Bit 1-3 are the pagesize bits, pagesize are given in bytes not words, see table 
below: 
Table 5-44. Pagesize bit configuration 
Pagesize 
Bit 3, 2, 1 
256 
0 0 0 
0 0 1 
0 1 0 
0 1 1 
16 
1 0 0 
32 
1 0 1 
64 
1 1 0 
128 
1 1 1 
•  Bit 4-5 are not in use.  
•  Bit 6 must be set to ‘1’ when it is the very last page to be programmed, otherwise 
‘0’ 
•  Bit 7 indicates if a page write should be issued (Transfer data to flash). Normally it 
should always be set ‘1’. However, if the page size of the target device is too large 
to be covered by one Program Flash command (because the amount of available 
SRAM in STK500 is limited) this can be used to let 2 or more commands fill the 
page buffer of the target device. The transfer data to flash flag should then only be 
set on the last command. 
Note: 
Only Bit 0-3 are set in the XML file, cause Bit 6-7 are not static and must be 
controlled by the PC Frontend. 
5.3.5 CMD_READ_FLASH_PP 
This command will read data from the FLASH memory of the target device if it 
succeeds. For devices with the FLASH organized in pages, the data address and size 
used with this command must confirm to that of the device. I.e. one ReadFlash 
command is used to read one page in the target device. 
XML PATH: /AVRPART/ICE_SETTINGS/STK500_2/PpReadFlash/ 
Table 5-45. Command format 
Field  
Size 
Values 
Description 
Command ID 
1 byte 
CMD_READ_FLASH_PP 
Command id 
Nmb bytes 
(MSB) 
1 byte 
 
Total number of bytes to program 
(MSB) 
Nmb bytes 
(LSB) 
1 byte 
 
Total number of bytes to program 
(LSB)