Other Parts Discussed in Thread: HALCOGEN,
Hi. I'm using a TMS570LS3137 HDK board to send and receive SPI messages. I have created a small variation of the HalCoGen generated spiTransmitAndReceiveData function. It is identical to the original except that it uses 8 bit source and destination arrays. I'm seeing some strange behaviour. The code sits in a loop whilst waiting for the Rx complete flag to be true. However this function exits one byte before the transmission is complete. I have attached a scope trace. I set a port pin high when the function is called and low again after it returns.
Can anyone explain why it's doing this and how I get around it?
Thanks
Andy