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.

ADS131A04: CRC Calculations on ADS131A04

Part Number: ADS131A04

I have a ADS13104 up and running reliability.  I want to enable CRC checking on the SPI bus but am having trouble getting commands accepted by the A2D when CRC checking is enabled.

For example, to unlock the device with the command 0x5506, the following bytes are sent to the A2D (in 32 bit mode):

//reset a2d (crc mode disabled)

//unlock registers

06 55 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 - [ 83 DA 00 00 ] (CRC16 of first 5 words is 0xDA83) 

//The response matches the expected 0x00005506

//Setup fixed frame mode, crc mode =1, CRC enabled

4C 43 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 - [ 6C 65 00 00 ]

//The response matches the expected 0x0000432C

//Setup A_SYS_CFG

4B 68 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 - 00 00 00 00 -  [ F1 6F 00 00 ]

//The response does *not* match the expected 0x0000684B - response is 0x00002122.

So the first command that I'd expect the sent CRC value to be evaluated is failing.

  • Hello,

    Thank you for your post!

    I have a few clarification questions/comments to start with:

    AJMAJM said:
    //reset a2d (crc mode disabled)

    //unlock registers

    By default, the ADS131A04 powers up in dynamic-frame mode with CRC disabled. You should only need to send one 32-bit word to unlock the ADC after reset (Figure 53b). Have you tried only sending 0x0655 0x0000?

    AJMAJM said:
    //The response matches the expected 0x00005506

    The expected response for the UNLOCK command is 0x0655 0x0000 (same as what you write to the device in the previous frame). The response should be MSB-aligned.

    AJMAJM said:
    //Setup fixed frame mode, crc mode =1, CRC enabled

    Again - you are still in dynamic-frame mode at this point and CRC is still disabled. You only need to send 0x4C43 0x0000. The correct response in the next frame is the register address and the updated register data (0x4C43 0x0000).

    AJMAJM said:
    //Setup A_SYS_CFG 

    Now that you are in fixed-frame mode with CRC enabled, you must send 6 32-bit words to the device. I believe the CRC word should be 0x9949 0x0000.

    Best Regards,