Compal Electronics Inc PICONODE User Manual

Page of 52
PicoNode Integration Specification
 
 
 
27 
 
7.4 SPI Bus Timing Example 
This section provides an example illustration of an exchange of messages first from master 
(Host) to slave (Node) and then from slave (Node) to master (Host). Each step in the timing 
sequence is described below: 
 
Figure 20 SPI Timing Example 
 
Note that MRQ state transitions must respect the timing requirements shown in Chapter 5. 
The following items pertain to the numbered bubbles above: 
1.  Host has a message that it desires to send to Node. The first thing that it does is drive MRQ 
and CS high. 
2.  The Host then waits for the Node to drive SRDY high. No SPI bus transaction with the Node 
can occur before this. 
3.  After SRDY is high, the Host can start with the SPI data transaction. This is accomplished by 
driving the Node CS line low and then having the Host toggle the SCLK, and MOSI lines and 
having the Node toggle the MISO line according to the data to be transferred. The SPI Host 
interface specifies that first a MMsg pair is exchanged. 
4.  A MHdr pair is exchanged. Note that the payload of the message is appended to the MHdr. 
5.  The Host detects that the transaction is complete and that it does not wish to send more 
messages to the Node at this time. It drives the MRQ line low. Since MRQ is low, CS, SCLK 
and MOSI are tri-stated. 
6.  At some time in the future, the Node desires to send a message to the Host. It indicates this 
to the Host by driving SRQ high. Since SRQ is high, the Host drives MRQ and then CS high. 
It then waits for SRDY to go high, which it already is.