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.

ADS1259的SPI读取数据问题,回读寄存器数据错误。

Other Parts Discussed in Thread: ADS1259

你好,我最近在调试ADS1259这款芯片,遇到读取寄存器返回值错误的问题。目的是通过DSP28377D的SPI接口实现对ADS1259转换数据的读取。

在调试的时候,首先进行寄存器回读验证,DSP能够正常发送数据,但回读的数据不对。

参照官方的资料,返回的第三个字符应该是config0的配置值,即0x05,但是现在返回的字符是随机的。请问这可能是什么问题呢?

ADS1259初始化程序如下:

void InitADS1259(void)

{

//RESET->0 initially

   SET_RESET1();

   SET_START();

   SET_CS();

 

   delayns1(70);   //延迟至少2^16个tclk时钟

   CLR_RESET1();       //拉高START

    delayns1(70);

    SET_RESET1();

 

    CLR_CS();

    WriteToADS1259(SDATAC);//send SDATAC command 禁止读命令,才能往ADS1259寄存器写指令进行配置

    delayns1(10);

 

    WriteToADS1259(opcode1_W);//Write register opcode bytes, starting at address 0, 9-byte block.从0地址开始连续写9个字节的指令

    delayns1(10);

    WriteToADS1259(opcode2_W);

 

    delayns1(10);

    WriteToADS1259(0x0500);

    delayns1(10);

    WriteToADS1259(0x1000);

    delayns1(10);

    WriteToADS1259(0x0300);

 

    delayns1(10);

    WriteToADS1259(0x0000);

    delayns1(10);

    WriteToADS1259(0x0000);

    delayns1(10);

    WriteToADS1259(0x0000);

 

    delayns1(10);

    WriteToADS1259(0x0000);

    delayns1(10);

    WriteToADS1259(0x0000);

    delayns1(10);

    WriteToADS1259(0x0000);

    delayns1(10);

}