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.

RF generator packet format cc112x

Other Parts Discussed in Thread: CC1120

Hello,

I am trying to receive with smartrf studio with CC1120 packets that are generated from a vector signal generator (VSG).

The packet in VSG is composed like this:

0x5555 - preamble;

0xF68D - Sync;

0x04 - Lenght;

0x1234 5678 - Data Field;

0x F4AE - CRC-16 (Modbus);

the CRC was calculated on byte 0x0412 3456 78 (calculated over lenght field and data field);

calculating CRC on 0x12345678 (calculated over data-field) result is the same.

in swru295 pages 36-37 it is not clear if crc is calculated on lennght, address and data fields(fig 11) or only data field top of page 36).

 

It seems that I have a problem on CRC. Is it correct? If you need other data let me know.

Regards

Alberto.

  • CRC calculation is tricky...

    I used SmartRF Studio as sender and receiver to check what CRC CC1120 sends. I sat up Studio to send 0x12345678 and I sat the receiver to fixed package format and the package length to a few byte more than I send to get the CRC into the FIFO I got 0xBB60 as CRC.

  • I used the VSA generator with this packet :

    0x5555;

    0xF680;

    0x04;

    12345678;

    0xBB60;

    using the same method you used @receiver side. Results attached.

    Lenght and datafield are correctly received, CRC changes.

     

    What is it?

    Alberto.

  • Alberto,

    What TER meant, I think, is that he set up the transmitter to be in variable packet length mode and transmitted 0x12345678, but used fixed packet length mode to be able to see what happens.  Because he's in variable packet length mode, the data transmitted is 0x0412345678CCCC, where CCCC=the CRC.  The CRC is calculated over the length byte and data field.  For the 0x0412345678 sequence, the CRC is 0xBB60 (see below).

    Put your receiver in variable packet length mode to receive, and it should work.

    CRC calculation:
              FFFF (start)
    04 -> 7D19
    12 -> 1862
    34 -> E2EB
    56 -> E8B8
    78 -> BB60

  • Thank you GrantC,

    Thank you TER.

    I understood TER's indications,

    I restarted all boards, reconfiguring SmartRF studio and my Vector Sig. Gen.... now I am able to use Vector Signal Generator to Transmit and The CC1120 to receive, it is OK.

    Is there some application note to learn how calculate CRC, in particular on CC1120?

     

     

  • See DN502:

    http://www.ti.com/lit/an/swra111d/swra111d.pdf