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

Los códigos de productos
ATSTK500
Descargar
Página de 31
16
AVR061 
2525B–AVR–04/03
Universal Command
Universal command is used to send a generic 32-bit data/command stream directly to
the SPI interface of the current device. Shifting data into the SPI interface at the same
time shifts data out of the SPI interface. The response of the last eight bits that are
shifted out are returned.
Currently this command is used to read and write Fuse and Lock bits in Serial/High-volt-
age mode. For more information, see the appendix.
Command
Cmnd_STK_UNIVERSAL, byte1, byte2, byte3, byte4, Sync_CRC_EOP
Command Value
0x56
Response
Resp_STK_INSYNC, byte4_out, Resp_STK_OK
or
Resp_STK_NOSYNC (If no Sync_CRC_EOP received)
Extended Universal 
Command
Extended SPI universal command used to clock any number of bytes to the SPI inter-
face of the current device.
Command
Cmnd_STK_UNIVERSAL_MULTI, number_of_bytes, data bytes, Sync_CRC_EOP.
Command Value
0x57
Response
Resp_STK_INSYNC, Resp_STK_OK
or
Resp_STK_NOSYNC (if no Sync_CRC_EOP received)
Table 27.  Parameters 
Parameter Name
Field Usage
Field Format
byte1
First byte of SPI data/command
1 byte
byte2
Second byte of SPI data/command
1 byte
byte3
Third byte of SPI data/command
1 byte
byte4
Fourth byte of SPI data/command
1 byte
byte4_out
The response of the last eight bits to be shifted out from 
the SPI interface
1 byte
Table 28.  Parameters
Parameter Name
Field Usage
Field Format
number_of_bytes
0 - 255 equals 1 - 256 bytes to be sent
1 byte