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.

ADS1015: ADS1015 output code will sometimes change to 0XFFFF then turn back to the right value, then change to 0XFFFF.

Part Number: ADS1015

Hi team,

My customer is using the ADS1015 now, and meet some problmes below.

ADS1015 output code will sometimes change to 0XFFFF then turn back to the right value, then change to 0XFFFF.

The schematic is below. we only  configure Conversion register C303

The code is below.

void  InitADS_task(void)

{

         s16 temp=0;

         float temp_a=0;

         while(1)

         {

// printf("-----------------------------------------------\n");

             rtems_task_wake_after(2000);

             Write_TMP_reg_word(0x01,  0x03C3); //actually "0xC303"

             rtems_task_wake_after(10);

             Read_TMP_reg(0x01);

             temp=(s16)Read_TMP_reg(0x00 );

             temp=(*((s8*)&temp)  << 8 & 0xff00)   | temp >> 8;

             temp=temp>>4;

//            printf( "temp :0x%02x   %d  \n"  , temp ,temp);

             temp_a=(temp/2048.0* 4.096);

//            printf("temp_a= %.2f \n\n" , temp_a );

             temp_VCSEL=temp_a;

//            printf("temp_a= %.2f   ,%.2f \n\n" ,

temp/2048.0,temp/2048.0*4.096 );

         }

}

From the datasheet, the chip should not generate code like 0XFFFF? Could you please help check why and give some suggestions?

Thanks.

BR

Frank

  • Frank,

    You are correct in that the device should not be reporting FFFFh. The ADS1015 LSB data reports 0 for the last four bits.

    To debug this problem, I would try to capture a data read of FFFFh with an oscilloscope or logic analyzer. It is possible that that there is some disruption in the I2C transaction. Make sure that during the data read, the ADS1015 sent an ACK to as a response to the device read. If the device is not responding, the SDA will be high because it requires the SDA to be pulled down by the device.

    When you capture the data read of FFFFh, you can post the result here and we can look at it together.

    Joseph Wu