I am using the Aardvark I2C/SPI Host Adapter in the SPI Slave mode. How can I specify multiple responses for the Aardvark to return, such that each packet returns a different response?
To provide some background, the delay between bytes in my application is short enough that the Aardvark adapter can only echo what is reads from MOSI after the first byte. MOSI is not connected to the SPI master, so I have tied the MOSI and MISO signals together with a 1K resistor. I have no control over the timing of SCLK or the timing between packets. The timing is too fast for a typical computer to change the response in real-time.
Thanks for the question! The Aardvark adapter, along with the Control Center Software can store one response to any packet, as a slave. The response cannot be changed on the fly, so to change the data that the Aardvark adapter slave sends, the Aardvark adapter's set response must be set to a different value each time. For example, for the Aardvark adapter to send AA in the first read, BB in the second read, and CC in the third read:
The following is an example of how that can be done. Please note this example uses an Aardvark I2C/SPI Host Adapter, the Control Center Software and the Total Phase SPI Flash Demo Board. If necessary, the SPI Flash Demo Board can be substituted with an off-the-shelf SPI slave device.
For additional information, please refer to the following documents:
We hope this answers your question. If you have other questions about our host adapters or other Total Phase products, feel free to email us at sales@totalphase.com or submit a request for technical support.