Atmel ATSTK600 500 Starter Kit and Development System. ATSTK600 ATSTK600 データシート

製品コード
ATSTK600
ページ / 61
 
AVR079
 
 
37
8133A-AVR-04/08 
Table 9-13. Command format. 
Offset Field 
Size 
Values 
0 Command 
ID
(1)
 1 
byte 
XPRG_ERASE 
1 Memory 
type
(2)
 
1 byte 
Application, Boot, EEPROM, Fuse, Lockbits… 
2 PageMode
(3)
 
1 byte 
Bitfield, see description below 
3 Address
(4)
 4 
bytes 
Any 
address 
7 Length
(5)
 
2 bytes 
1 to 512 
9 Data
(6)
 
N bytes 
N data bytes, size is given  by the Length parameter 
Notes: 
1.  The command identifier 
2. XPRG_MEM_TYPE_APPL 
XPRG_MEM_TYPE_BOOT 
XPRG_MEM_TYPE_EEPROM 
XPRG_MEM_TYPE_FUSE 
XPRG_MEM_TYPE_LOCKBITS 
XPRG_MEM_TYPE_USERSIG 
3. If 
Memory type is XPRG_MEM_TYPE_APPL, XPRG_MEM_TYPE_BOOT or XPRG_MEM_TYPE_EEPROM: 
Bit 0: Write page 
Bit 1: Erase page 
4.  The start address of the data to be written. The address is in the TIF address space 
5.  Can be any value between 1 and 512. If page programming, and the actual page size is bigger than 256, the 
operation must be split into two or more XPRG_WRITE_MEM operations, where only the last operation has the 
Write page bit set. 
Note: Only APP, BOOT and EEPROM handles page operations, for any other memory type, the Length field must 
be set to 1. 
4.  The data to be written. The size is indicated by the Length field. 
 
Table 9-14. Answer format. 
Offset Field 
Size 
Values 
0 Command 
ID
(1)
 1 
byte 
XPRG_WRITE_MEM 
1 Status
(2)
 1 
byte 
 
Notes: 
1.  The command identifier. 
2.  One of the defined error codes. 
 
9.2.6 XPRG_READ_MEM 
This command handles reading of the different XMega memories: application, boot 
and eeprom, signatures, fuses, lockbits and factory calibration values.