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/MSP-TS430DA38: MSP430F2252

Part Number: MSP-TS430DA38
Other Parts Discussed in Thread: MSP430F2252, MSP430WARE, PCF8574,

Tool/software: Code Composer Studio

helo sir,

     i have working in msp430f2252..i getting code and got output from your web site like //ti resoruce explorer/msp430f2252/software/msp430ware/device/msp430f2252/peripheral_Example/Register_level/USCI_B0 I2C Master TX multiple bytes to MSP430 Slave  -OK

//ti resoruce explorer/msp430f2252/software/msp430ware/device/msp430f2252/peripheral_Example/Register_level/USCI_B0 I2C Master RX multiple bytes from MSP430 Slave  -NOT WORKING

here i have dought for bpth address should be 0x48 so we write address 0x48(8th bit mode like write=0) and read address 0x49(8th bit mode like read=1).

 

so i confuse can you explain this details.

thanking you

siru

  • The Read/Write bit is not part of the I2C slave address, so I2CSA (master) and I2COA (slave) should be the same: 0x48 in this case.

    I don't see the exact name of your Examples in the Web Resource Explorer. Are you using the "i2c_standard_master" and "i2c _standard_slave"? What is it exactly that isn't working?
  • The first byte of an I2C transaction contains the 7-bit address and the R/W bit.

    On the MSP, the address register contains only the address, and the UCTR bit controls the R/W bit. (The hardware automatically combines them.)

    When using the address 0x48, the I2C byte will be either 0x90 or 0x91.
  • my problem is can not jump interrupt on  void __attribute__ ((interrupt(USCIAB0TX_VECTOR))) USCIAB0TX_ISR (void)  from this code USCI_B0 I2C Master RX multiple bytes from MSP430 Slave.but the interrupt section properly excuted in this code like USCI_B0 I2C Master TX multiple bytes to MSP430 Slave.

    can you give any solution?

    i m using pcf8574 write is good but read opration not get the result..

    explain difference between this . 

      __bis_SR_register(CPUOFF + GIE);     

     __bic_SR_register_on_exit(CPUOFF);   

    thanking you..

    siru

  • thaking you clemens,
    i m using pcf8574 i did write opration and got result. but read cannot result give me a sample code or idea to this.



    siru..
  • The PCF8674 is always a slave, so the MSP must be the master.

    Whether to do reading or writing has nothing to do with being master or slave.
  • The PCF8574 slave address is 0x20+n, where n depends on how A0-A2 are connected (n=0 is a good first guess). [Ref Data Sheet (SCPS068J) Figure 16.]

    If you use a different address (0x48, e.g.) you will get a NACK. At first glance, the Example msp430x22x4_usci_i2c_standard_master.c doesn't seem to deal well with NACKs.

    > __bis_SR_register(CPUOFF + GIE);
    > __bic_SR_register_on_exit(CPUOFF);
    The first puts the CPU into (enabled) sleep mode. The second (from an ISR) takes it out of sleep mode. [Ref User Guide (SLAU144J) Sec. 2.3.1. The examples are in assembly, but the point is there.]
  • thank you bruce..

      it is more help thanking you...

  • Part Number: MSP-TS430DA38

    Tool/software: Code Composer Studio

    i am using pcf8574 i did not read and write the sample code for this USCI_B0 I2C Master Interface to PCF8574, Read/Write.my connection is (A0+A1+A2)=gnd, sda & scl both are connected 10k resisitor.but this sample code cannot take rection on my chip with link msp430f2252.pls can you help me..

    thanking you

    siru

  • Hello Siranjeevi,

    I've merged your newest thread with this one as the two topics seem to be the same. For further discussion on this topic, please keep to this thread.

    Please also see the following application note to help resolve your I2C communication issues.

    http://www.ti.com/lit/slaa734

  • thank you jace,

        i have got the result from pcf8574.This problem is device address is 0x38 and read opration giving input for pcf8574. change any pin value '1s' or '0s' ..and important think in this area A0+A1+A2=gnd.

    thanks you for all for helping this task..

    siru

**Attention** This is a public forum