This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC430F5137: CRC check probleam

Part Number: CC430F5137
Other Parts Discussed in Thread: SIMPLICITI

Hi,

I am working on CC430F5231 module. I have started with example code given in SLAA465C. I am using  LT_FIFO code. But the ready code provided by TI seems not working. It always transmits data but CRC check always fails even if data is correct. Can anybody help me to resolve it? 

Thanks.

  • Piyush, 

    Have you been able to use SmartRF Studio to confirm that the devices are communicating correctly? I always suggest starting with SmartRF studio, as both the transmitter and the receiver. Then you go to the next steps and create your own software based on the example code in SLAA465C, but still use SmartRF studio as a receiver. By doing this you can confirm if your transmitter code is working as expected to be able to narrow down the problem.

    Regards,
    /TA

  • Piysush, 

    In my experience with this driver, I have found what I consider a bug. I just want to help you by making you aware of what I found and how I got around. I found that when using the code the chip would throw an error and the driver would stop responding. I traced it down to this function:

    // *****************************************************************************
    // @fn ReadSingleReg
    // @brief Read a single byte from the radio register
    // @param unsigned char addr Target radio register address
    // @return unsigned char data_out Value of byte that was read
    // *****************************************************************************
    unsigned char ReadSingleReg(unsigned char addr)
    {
    unsigned char data_out;

    // Check for valid configuration register address, 0x3E refers to PATABLE
    if ((addr <= 0x2E) || (addr == 0x3E))
    // Send address + Instruction + 1 dummy byte (auto-read)
    RF1AINSTR1B = (addr | RF_SNGLREGRD);
    else
    // Send address + Instruction + 1 dummy byte (auto-read)
    RF1AINSTR1B = (addr | RF_STATREGRD);

    while (!(RF1AIFCTL1 & RFDOUTIFG))
    ;
    data_out = RF1ADOUTB; // Read data and clears the RFDOUTIFG

    return data_out;
    }

    where I needed to modify one line of code:

    From :  data_out = RF1ADOUT1B; // Read data and clears the RFDOUTIFG

    To      : data_out = RF1ADOUTB; // this call does not perform auto write

    This actually could fix your CRC error issue also, but I still recommend by starting with SmartRF Studio as a "known good software"

    Regards,
    /TA

  • Yes, I have tried with smartRF studio and done communication sucessfully with minimum packets drop/error. In my current hardware the probleam is if i use the CRC check then it always fails but if I ignor it then almost 90% received data are correct.

    Thanks
    -Piyush
  • Thanks

    I will try with your suggestion and let you know.
  • Piysuh,

    I will assign a team member to try the example code to see if we can replicate your findings.

    Regards,
    /TA
  • Thanks a lot.

    I am also trying, but still it is not working. I will post here, If I will get anything.

  • Hello Piyush,

    I set up the basic Rx/Tx example in Smart RF Studio for two EM-CC430F5137-900 boards and they weren't communicating successfully. I then tried attaching the accompanying antennas just in case that was the problem and it turns out that the boards do indeed need the antennas for communication, even with the boards right next to each other. I am now able to confirm that the LT_FIFO example code from TI ( SLAA465C ) works on my bench-top with no CRC error and proper wireless LED toggling.

    Are you using the accompanying antennas with your evaluation boards when you run the example code?

    -Matt

  • Hello Matthew,

    Yes I am using chip antenna attached with the hardware. The same hardware tested using RF studio and worked with fine more than 10k packets of 50 bytes with very few failure. But when I am using  LT_FIFO example from SLAA465C, it is not working. specially CRC check. If I skip CRC check then the received data seems corrects (>70% avg).

    I am facing similar issue mentioned the thread

    https://e2e.ti.com/support/wireless_connectivity/proprietary_sub_1_ghz_simpliciti/f/156/t/569071

    But from that discussion I am not able to find a solution for my problem. 

    Any ways as my received data is correct most of the time, I am trying to insert manual CRC check in my code. Which will increase payload but I can afford it. 

    Thanks

    -Piyush

  • Piyush,

    I have some questions regarding your setup:

    1) What exact board and device are you using because there is a discrepancy between the device mentioned in the title versus the device mentioned in the problem description
    2) Are you using the Fixed or Variable LT_FIFO example?
    3) I did a clean import of the Fixed LT_FIFO example on my boards and was able confirm proper operation. Are you able to do the same with no modifications to the code?

    -Matt
  • Dear Matthew,

    1) What exact board and device are you using because there is a discrepancy between the device mentioned in the title versus the device mentioned in the problem description

    I am using a development board based on CC430F5137. (Sorry for my typing mistake in the initial problem description.) This hard ware I bought form online. The same hardware is working and tested with the simpliciTI protocol for more than 6 months and working fine. This HW runs with 433 MHz. I also tested this HW with RFstudio 7 and works fine as mentioned previously.

    2) Are you using the Fixed or Variable LT_FIFO example?

    Yes, I am using LT_FIFO example mentioned in SLAA465C Application report. I have imported the code from the folder CC430x513x RF examples>RF_Examples_CCS>Fixed_LT_FIFO.

    I have modified the code a bit. The changes I have done are

    433MHz in RFsettings(file generated from RFstudio)

    Make one transmitter which transmits data periodically (*approx 1s) and toggles LED after transmission.

    Another receiver which only receives data and toggles LED then send it to the serial port (this is optional) which is connected to the machine. 

    I have not used the code without these small changes because my hardware has different connections. But I think It should work. 

    Now If I enable the CRC check then it shows no data receive successfully because of CRC failure. But if I skip CRC check and send the data to serial port then it seems data are correct most of the time.

    3) I did a clean import of the Fixed LT_FIFO example on my boards and was able to confirm proper operation. Are you able to do the same with no modifications to the code?

    Yes, it was clean import with minor warnings like the project has built with different compiler etc.. etc..

    With out little modification I can't say that if it is working or not because my hardware has different connection and frequency. 

    If you need more info pleaselet me know.

    Thanks

  • Piyush,

    The best method to start debugging the problem is to find the bug that arose during the changing of the example code during the porting for your device and frequency. Please re-import the example and only change the lines of code necessary to run the basic Tx/Rx example which wirelessly toggles an LED (P1.0) at the push of a button (P1.7). Once that code is made please test it and send it to me so I can test it as well.

    You said you purchased your hardware from online, have you tried using the TI provided EVM for the CC430F5137 to help in the debug process? What hardware are you working with?

    -Matt
  • Dear Matt,

    I am doing similar and also started as you have suggested. I will try once again and will do minimum changes to get the problem.

    I have started with the kit http://www.ti.com/tool/MSP-EXPCC430RFX

    and later I switched to another hardware similar to ez430. This is similar to this kit https://www.aliexpress.com/item/CC430F5137-development-board-CC430F6137-CC430-ez430-development-board-MSP430-CC1101/32642794077.html

    This new hardware I have tested tested with RF studio and works very well with simpliciTI also used it for some projects. 

    As suggested by you I will do import the code once more and try to get the problem. And will send it to you if I will face similar problem. 

    Thanks

    -Piyush

  • Piyush,

    Sounds great, I will keep an eye out for the results and the code!

    Best regards,

    Matt

**Attention** This is a public forum