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.

DAC71416: Unable to get DAC output voltage

Part Number: DAC71416

Hi,

i am having a problem in getting a output from the DAC0 pin,

i enabled all registers which are needed for the output to come at DAC0.

microcontroller: STM32F103C8T

Vcc = +15v

Vss = -15v

Vaa=Vdd= 5v

Vio= 3.3v

/LDAC = /RESET = /CLEAR = 3.3v

TOG0=TOG1=TOG2= Gnd they are grounded

SPI configuration

CS : /CS

CLK: SCLK

MISO : SDO

MOSI : SDI

Vref= using internal refernce 2.5v

for SPICONFIG_____________________________________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x03);//enable spiconfig

SPIx_Transfer(0x0A);

SPIx_Transfer(0x8E);//Enable streaming mode ,sdo,sdo updates at falling edge
SPIx_DisableSlave();

for GENCONFIG_____________________________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x04);// GENconfig
SPIx_Transfer(0x3F);//activate the internal reference
SPIx_Transfer(0x00);//DAC does not operate in differentiate mode
SPIx_DisableSlave();

for BRDCONFIG__________________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x05);//enable BRDCONFIG
SPIx_Transfer(0xFF);
SPIx_Transfer(0xFF);

for DACPWDWN_____________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x09);//Enable DACPWDWN
SPIx_Transfer(0x00);
SPIx_Transfer(0x00);
SPIx_DisableSlave();

for BRDCAST________________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x0F);//Enable BRDCAST
SPIx_Transfer(0xFF);
SPIx_Transfer(0xFF);
SPIx_DisableSlave();

for DACRANGE________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x0A);//enable DACRANGE_a
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_DisableSlave();


SPIx_EnableSlave();
SPIx_Transfer(0x0B);//Enable DACRANGE_b
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_DisableSlave();


SPIx_EnableSlave();
SPIx_Transfer(0x0C);//Enable DACRANGE_c
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_DisableSlave();


SPIx_EnableSlave();
SPIx_Transfer(0x0D);//Enable DACRANGE_d
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_Transfer(0x11);//set the output range for corresponding DAC from 0 to 10v
SPIx_DisableSlave();

for DAC0_______________________________________________

SPIx_EnableSlave();
SPIx_Transfer(0x10);//Enable DAC0
SPIx_Transfer(0xFF);
SPIx_Transfer(0xFF);
SPIx_DisableSlave();

i attached the DAC schematic below

i attached my program below

is there any correction please tell it.

i am not getting the output voltage at DAC0 output pin.

my output is only 0.3v is comming at DAC0 out pin.

i need to get some voltage as minimum voltage as 1v but not 0v.

Thanking you, 

  • Sai,


    There are other ways than looking at the code or the schematic to debug the operation of the DAC in your circuit.

    It's also important to verify that your communications are being received by the device. In addition to writing to the device, it would help to read back the registers to confirm that the device has received the original write. If the register read comes back with the register default value, then the write wasn't done properly.

    In that case, it's also helpful to look at the SPI waveforms from the microcontroller to the device to see that the SPI is being sent correctly. The waveforms should match the timing diagrams and the timing characteristics listed in the tables in the datasheet.

    You should verify the digital signals and ground going to the device and make sure the signals make it all the way to the DAC. I would also make sure the microcontroller and the DAC use the same supply or you may need a level translator.

    I'll try to read through your code, but go through my suggestions and see if any help.


    Joseph Wu

  • Hi Joseph

    the above given code which was posted by me is correctly worked for me.

    thank you,

    sai.