I am using the SPICC26XXDMA.c in SPI_MODE_CALLBACK as SPI_SLAVE.
I am confused how to handle asynchronous read/writes. In order to be listening for a read as a slave I first need to call SPI_transfer() but I don't know when that read is going to come. I also need to write to the bus so I again need to call SPI_transfer(). This could happen while I'm waiting for a transfer (really, I'm always waiting for a transfer). The second call to transfer does nothing if I'm already waiting for a transfer.
This whole scheme seems flawed to me. I can't really find many examples period, let alone something that works like this. I found a loopback example which handles a transfer each way but not asynchronously.
I would appreciate some examples or just some help in general