Sep 25, 2019
01:15 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sep 25, 2019
01:15 AM
I am trying to use a USIC as IIC master.
The module is enabled, the baudrate set and IIC mode selected (CCR.MODE = 4). When I write the MasterStart byte (using the XMC_I2C_CH_MasterStart() function) the data is written to the FIFO (0x4AE) but nothing happens on the bus.
The TCSR (Transmit Control/Status Register) has the value 0x10000580. As far as I can see the important bits are as expected: TE = 1 (The trigger event has been detected, TDV = 1 (Tha data word in TBUF is valid), TDEN = 1 (A Transmission of the data word in TBUF can be started if TDV=1).
Why is the byte not transmitted? What is the USIC waiting for?
The module is enabled, the baudrate set and IIC mode selected (CCR.MODE = 4). When I write the MasterStart byte (using the XMC_I2C_CH_MasterStart() function) the data is written to the FIFO (0x4AE) but nothing happens on the bus.
The TCSR (Transmit Control/Status Register) has the value 0x10000580. As far as I can see the important bits are as expected: TE = 1 (The trigger event has been detected, TDV = 1 (Tha data word in TBUF is valid), TDEN = 1 (A Transmission of the data word in TBUF can be started if TDV=1).
Why is the byte not transmitted? What is the USIC waiting for?
- Tags:
- IFX
- iic xmc4500
2 Replies
Sep 25, 2019
04:40 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sep 25, 2019
04:40 AM
Hi,
Did you configured the SDA and SCL inputs?
Did you look at the examples in XMCLib?
Regards,
Jesus
Did you configured the SDA and SCL inputs?
Did you look at the examples in XMCLib?
Regards,
Jesus
Sep 25, 2019
10:56 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sep 25, 2019
10:56 PM
I have solved the problem.
It was a hardware problem. Due to a hardware fault (badly soldered wire) the SDA line was short circuited to ground. As the data line was always low, the I2C start could not be applied.
It was a hardware problem. Due to a hardware fault (badly soldered wire) the SDA line was short circuited to ground. As the data line was always low, the I2C start could not be applied.