FX3 SPI transaction question

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

 

   

I have a question on how the FX3 API handles SPI transactions.

        CyU3PSpiTransmitWords    , the master FX3 sends data over MOSI, and also consumes the same amount of data via MISO. Is that MISO data from the slave available to an FX3 application? The     CyU3PSpiReceiveWords     appears to initiate a separate transaction for reading. This implies that the data that had been previously consumed in the Transmit activity would be lost. Or does Receive actually have access to the previous MISO data?   

 

   

When the FX3 initiates an SPI write via

   

 

   

Thank you,

   

JohnR

0 Likes
1 Solution
Anonymous
Not applicable

Yes, the received data is available but TransmitWords currently doesn't store them. For now, you can use the SPI in DMA mode which lets you both send and receive data simultaneously.

   

 

   

See the CyU3PSpiSetBlockXfer(..) function in the API guide for details.

View solution in original post

0 Likes
4 Replies