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.

ads1255 sample voltage with wrong datas

Other Parts Discussed in Thread: ADS1255, REF5025

Hello!

First,thanks for your patience!

I'm using ads1255 with a MSP430 to sample data and send it to a computer with a RS232 cable to view the data.However,i received the data completely false.

For example,when i connect AIN0 with 3.3V ,meanwhile,connect AIN1 with ground.The correct data can be like this:54 6C 67(because ads1255 is 24-bit AD,i use three hex numbers to  express,and the high byte is 54 ,the middle byte is 6c ,the low byte is 67).But i received like this: FF 54 6C(the high byte is ff ,the middle byte is 54 ,the low byte is 6c) .After several experiments , the result was same.So I use the word--"high byte shifts behind"to conclude this problem.And the circuit is drawn the same as the chip provided.

Can you help me?

Regards,

xing

  • Hi Xing,

    Welcome to the TI E2E Forums!

    Are you able to monitor the SPI communication between the MSP430 and the ADS1255 with a logic analyzer or oscilloscope?
    You'll want to make sure that the SPI communication is working properly, otherwise the data seen on the RS232 interface won't be very helpful. Additionally, if you know the SPI communication is good then it can help you debug your MSP430 or RS232 communication.

    Is the ADS1255 operating in SDATAC or RDATAC mode?
    In RDATAC mode you can clock out the 24-bit data with 24 clocks; however, in SDATAC mode you'll need to first send the RDATA command before clocking out the data, so a total of 32 SCLKs are required to retrieve the data (during the first byte on DOUT may be 00 or FF, during this time).

    Double check how your MSP430 code handles the data...
    Since the ADC data is 3 bytes (24 bits), you'll need to bit-shift, concatenate, and sign-extend the data into a 32-bit data type. I've seen programming mistakes when implementing this part of the code that can cause corrupted data.

    If you're able to capture some screenshots, I can help you determine if the SPI communication looks good.

     

    Best Regards,
    Chris

  • Hi,Chris,

    First,thanks for your reply!

    I'm shamed that I have no access to capture some screenshots right now.And I read data as the following picture showed:

    What's more,at first,I have made a ads1255-circuit separately,and I was able to control this circuit with msp430 successfully and received correct data.However,because of project's need,I have to connect ads1255 to msp430 in one circuit,I draw the circuit the same as before,unfortunately,the problem.occurred as I have mentioned above.(I think the phenomenon is very strange,but I can't find where my faults lies)

    Is there any problem occurs because line is too close to disturb the ads1255's pin--DOUT?


    Best regards,

    Xing

  • Hi Xing,

    Do you have a schematic of your circuit that you could share?
    If you had the software working before, maybe there is something that changed on the hardware that is causing problems...

    I'd also be willing to take a look at your code to see if there is anything that looks odd to me.

    Best Regards,
    Chris
  • Hi Chris,

    I'm so sorry that I haven't responded you for a long time!And here is my schematic of my circuit.

    430主板.PDF

    6433.Schematic Prints.pdf

    Best Regards,

    Xing

  • Hi Xing,

    Looking at your PCB layout, I noticed that you don't have a dedicated ground plane layer. Instead the AGND and DGND signals are routed as traces. These connections may be very inductive and lead to many signal integrity issues...

    (If you'll notice on the ADS1255EVM (a 4-layer PCB), layer 2 is a solid ground plane which makes for much lower ground impedance/inductance. I know with only a 2-layer board it is more difficult to provide a ground plane, but a 24-bit device like the ADS1255 will be very sensitive to any layout issues!)

    Additionally, it looks like you are using a shunt reference for the ADS1255. This will not provide the lowest output-impedance reference source and may lead to large gain errors. I would recommend using a buffered reference source, such as the REF5025, as the reference to the ADS1255.

    Best Regards,
    Chris

  • Hi Chris,

    Thanks for your reply! I'll have a try!

    Best Regards,

    Xing