Post Go back to editing

i am getting incorrect values when reading ad4111 channel records

before addressing the problem, I would like to point out the tools I use.

equipment used:

Adc board: EVALAD4111/12SDZ


development board :Easymx PRO v7 (STM32F107)



the compilation method: non os

apis used for compilation: Analog Devices Mbed OS  EVAL-AD717x-AD411x





ad717x_console_app.c  and other defination and source file.




Default values are written to the channel records using the AD717X_Init function. after the installation process is completed, I am reading the device's credentials correctly with the (menu_read_id) function. (the function you use for this operation appears in figure 5. ad717x_console_app.c  this func. int32_t menu_read_id(uint32_t menu_id))


although I didn't write any data to the channel records afterwards, when I read the channel records, I read different values in random ways, while the record value should be 0x0000. (the function you use for this operation appears in figure 4. channel_read(uint32_t menu_id))



I have written the new configuration value to activate all adc channels. (typed value: 0x8000) 

when I read back the register values of the activated channels, I see that the read value is 0xC000. . (the function you use for this operation appears in figure 5. ad717x.c>>  AD717X_WriteRegister(ad717x_dev *device,  uint8_t addr)

AD717X_ReadRegister(ad717x_dev *device, uint8_t addr)



then I update the entire channel records by typing the value 0x0000 to close the channels, and then when I reread the channel records, I saw that the values read were 0x8000. isn't [bit 15] supposed to be zero when the channels are configured to be closed?

Since I can read the ID record, I don't think there is a problem with my SPI interface configuration. I have configured the SPI settings as SPI mode3 as specified in the dataset.(see figure 1)


when I only read the channel records without writing a value on them, random values are read from each channel.( see figure 6)

however, in the ad4111 installation, I see that the value "0x0000" is written to the channel records.

  • Hi,

    What device ID are you getting for AD4111 device? From above screenshot, it looks like 0x986f, is that correct?

    The expected device ID is 0x30Dx (0x30DE). Can you please verify your SPI communication?

    SPI mode 3 is correct. Try with SPI frequency less than 10Mhz.

    I have verified the mbed code and device read/write is working fine with it.

  • the problem was solved by changing the baut rate value in the SPI interface settings.  this is the ID value I read from the device 0x30DE.I can also get consistent records when I read back the values I wrote on the channel records.

    the problem has been solved, thank you for your help.

Reply Children
No Data