B+B SmartWorx WLNN551 Manual De Usuario

Descargar
Página de 37
Airborne DP550 Family Databook
 
 
B&B Electronics, Inc. 
 
  
21 
7.3 
SPI Protocol 
A SPI message is composed of a 4 byte header followed by 0 or more bytes of 
data.  The header data is full-duplex.  That is, the TX message header is sent to 
the Airborne Device Server module by the host at the same time that the RX 
message header is sent to the host from the Airborne Device Server. 
The TX message header consists of a Command (CMD) byte, followed by three 
Parameter (PARM) bytes.  They are described in the SPI Commands section 0 
below. 
The RX message header is shifted out as the first four bytes of an SPI message 
regardless of the contents of the TX message header.  The RX message header 
consists of a RX Data Available field and a TX Buffer Available field.  The RX 
Data Available field indicates the number of data bytes the Device Server has 
available for the host.  The data can be received by the RXDATA command.  The 
TX Buffer Available field indicates how many data bytes the Device Server is 
able to accept from the host.  This data is to be shifted in by the host using the 
TXDATA (Table 16) command.  Both fields are 16 bit values and are stored in 
little-endian format (Least significant byte first). 
 
The /SPI_SEL signal must be de-asserted between successive SPI messages.  The 
messages will not be processed correctly if /SPI_SEL is held asserted across multiple 
messages. 
 
Table 13 - TX Message Header 
CMD 
PARM1 
PARM2 
Table 14 - RX Message Header 
RX Data Available 
TX Buffer Available 
 
 
 
SPI data is transferred most significant bit first (msb).