Hi everyone, I recently ported SimpliciTI 1.1.0 code to my company's target platform, and now I am testing whether it is fully functional. Around line 373 of mrfi_radio.c, we have: /* verify that SPI is working, PKTLEN is an arbitrary read/write register used for testing */ I am getting stuck on that last assert. I went into the details of it, and can tell you the following: 1) In the mrfiSpiWriteReg function call, the values are all correct. 2) In the mrfiSpiReadReg function call, we see that the write operation apparently was not successful. Any ideas on what might be my problem? Thanks, George Andrew Brindeiro
I am getting stuck in a assert related to SPI, and not really being able to figure out what the problem is.
#ifdef MRFI_ASSERTS_ARE_ON
#define TEST_VALUE 0xA5
mrfiSpiWriteReg( PKTLEN, TEST_VALUE );
MRFI_ASSERT( mrfiSpiReadReg( PKTLEN ) == TEST_VALUE ); /* SPI is not responding */
#endif
We go past the assert, and call spiRegAccess, where addrByte=0x06, writeValue=0xA5 andreadValue=0x0F.
Again we go past the asset, the read and burst bits are properly set. While addrByte=0xC6 andwriteValue=0xDB (correct), readValue=0xFF (reset value).
When I tried to have a fast SPI clock, I got readValue=0x0F on mrfiSpiReadReg, which was even worse (as expected).
Robotron Automation and Technology