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.

how to use DAC8760

Other Parts Discussed in Thread: DAC8760

hi

i want to use DAC8760

my mcu is TMS230F28335

28335 has  SPI features

data word lengh : one to sixteen data bits

but DAC8760 must transmit 24bit including address 1 byte.

question

can DAC8760 possilble receive each 1byte or 2byte  ??

like this..

datain                        -----------                          ----------------

                                                  ---------------------              

                                    1~7                                       8~15 

                               -------          ---                    -----                      -----------

 latch              ------         -------    ----------------      ------------------   

so if

1. transmit each 1byte ??

while(SpiaRegs.SPISTS.bit.BUFFULL_FLAG);
 SpiaRegs.SPITXBUF = 0x01;
 while(SpiaRegs.SPISTS.bit.BUFFULL_FLAG);
 SpiaRegs.SPITXBUF = data && 0xff00;

while(SpiaRegs.SPISTS.bit.BUFFULL_FLAG);
 SpiaRegs.SPITXBUF = data && 0x00ff;

2. transmit each 2byte??

while(SpiaRegs.SPISTS.bit.BUFFULL_FLAG);
 SpiaRegs.SPITXBUF = 0x0001; //  01 : address bit

while(SpiaRegs.SPISTS.bit.BUFFULL_FLAG);
 SpiaRegs.SPITXBUF = data; // data : 16bit

tell me how to use DAC8760 with 28335

  • Hello Kang,

    The DAC8760 interface will latch whatever is in its shift register each time it sees a rising edge on the LATCH pin. When the part starts up the shift register is initialized with all 0's.

    If your controller's SPI peripheral is limited to frame widths less than 24-bits wide then you have two choices to write to the device.

    1. Write byte-sized words to the device with LATCH toggling between each frame. Remember that the DAC8760 latches the input data every time it sees a rising edge on LATCH, though, so this means that it is conceivable that something unintended will happen with each frame until you have filled the input shift register with the 24-bit data of interest. I would consider this a high risk option since there's so many permutations of what may end up in the shift register when you raise the LATCH pin.
    2. Write byte-sized words to the device using multiple SPI frames while LATCH is kept low then brought high once all 24-bits of the desired word have been placed on the bus. There is no consequence to violating a 50% duty cycle on the clock line so this is a perfectly acceptable method to write to the part.