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.

CCS/MSP430G2553: MCP4726 interfacing with MSP430G2553 microcontroller

Part Number: MSP430G2553
Other Parts Discussed in Thread: MSP430WARE

Tool/software: Code Composer Studio

Hello guys,

As a beginner i started with MSP430G2553 ti microcontroller and i'm trying to interface it with a DAC having part no MCP4726. This is 12 bit DAC with I2c communication interface. I tried ti exaples but it didn't work well.

Please help this beginner to interface this DAC with msp430g2553 using i2c protocol.

Thanks in advance

  • Hey Alok,

    I think the best code example for you in this case would be msp430g2xx3_usci_i2c_standard_master.c found in your MSP430ware or here: dev.ti.com/.../ Looking quickly at the DAC, it's an I2C slave device so this example should get you close.

    I would run the example and scope the I2C lines. You should be able to see and follow the I2C communication and see if it's correct.

    Some common issues I would suggest checking:

    Do you have external pull-up resistors on the I2C lines?
    What is the slave address and is this loaded correctly?

    Thanks,
    JD
  • Hey JD
    I already tried this example and i used pullups resistor for both sda and scl line. For this DAC slave address is 0x60 i'm using what i got from its datasheet.
    Actually here three mode available for i2c communication in this DAC, i tried all but i'm doing some mistake,If possible can u go through its datasheet once for me .
    Thanks for your positive answer
  • Hey Alok,

    Unfortunately, I don't have time to go through the datasheet in detail. Most slave devices will have a few slave addresses available, usually selected via GPIOs.  I would confirm that you have these GPIOs configured to match your slave address.  

    I would suggest that you scope the I2C lines and compare them to the timing diagrams in the DAC's datasheet.  If there are differences we can discuss those details here.  

    Thanks,

    JD

**Attention** This is a public forum