Datasheet
5
AVR061
2525B–AVR–04/03
Set Device Programming
Parameters
Set the device Programming parameters for the current device. These parameters must
be set before the starterkit can enter Programming mode.
Command Cmnd_STK_SET_DEVICE, devicecode, revision, progtype, parmode, polling, selftimed,
lockbytes, fusebytes, flashpollval1, flashpollval2, eeprompollval1, eeprompollval2, pag-
esizehigh, pagesizelow, eepromsizehigh, eepromsizelow, flashsize4, flashsize3,
flashsize2, flashsize1, Sync_CRC_EOP
Command Value 0x42
Response Resp_STK_INSYNC, Resp_STK_OK
or
Resp_STK_NOSYNC (If no Sync_CRC_EOP received)
Table 5. Parameters
Parameter Name Field Usage Field Format
devicecode Device code as defined in “devices.h” 1 byte
revision Device revision. Currently not used. Should be set to 0. 1 byte
progtype Defines which Program modes is supported:
“0” – Both Parallel/High-voltage and Serial mode
“1” – Only Parallel/High-voltage mode
1 byte
parmode Defines if the device has a full parallel interface or a
pseudo parallel programming interface:
“0” – Pseudo parallel interface
“1” – Full parallel interface
1 byte
polling Defines if polling may be used during SPI access:
“0” – No polling may be used
“1” – Polling may be used
1 byte
selftimed Defines if programming instructions are self timed:
“0” – Not self timed
“1” – Self timed
1 byte
lockbytes Number of Lock bytes. Currently not used. Should be set
to actual number of Lock bytes for future compability.
1 byte
fusebytes Number of Fuse bytes. Currently not used. Should be set
to actual number of Fuse bytes for future caompability.
1 byte
flashpollval1 FLASH polling value. See Data Sheet for the device. 1 byte
flashpollval2 FLASH polling value. Same as “flashpollval1” 1 byte
eeprompollval1 EEPROM polling value 1 (P1). See data sheet for the
device.
1 byte
eeprompollval2 EEPROM polling value 2 (P2). See data sheet for device. 1 byte
pagesizehigh Page size in bytes for pagemode parts, High Byte of 16-
bit value.
1 byte
pagesizelow Page size in bytes for pagemode parts, Low Byte of 16-
bit value.
1 byte
eepromsizehigh EEPROM size in bytes, High Byte of 16-bit value. 1 byte
eepromsizelow EEPROM size in bytes, Low Byte of 16-bit value. 1 byte