Not applicable
Apr 25, 2016
08:22 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Apr 25, 2016
08:22 PM
Hi,
I'm creating a project referring to the Usage example in the I2C Slave "Help" for XMC1302.
I only made 2 changes,
1. Change the IO pin mapping
2. Slave address to 0x16
Setup
I2C master I2C Slave (address 0x16)
P13 SCL ---------------------- P20 CLK
P12 SDA ---------------------- P21 SDA
I2C_SLAVE_Receive(&I2C_SLAVE_0, slave_rx_data, DATA_COUNT); ==> OK
I2C_SLAVE_Transmit(&I2C_SLAVE_0, slave_rx_data, DATA_COUNT); ==> NG
slave receive api was able to receive the correct data, however WRONG data was transmitted using the slave transmit api.
Seems like tx buffer was offset/corrupted. Anyone encounter the same problem?? Any suggestion/idea??
Thanks
I'm creating a project referring to the Usage example in the I2C Slave "Help" for XMC1302.
I only made 2 changes,
1. Change the IO pin mapping
2. Slave address to 0x16
Setup
I2C master I2C Slave (address 0x16)
P13 SCL ---------------------- P20 CLK
P12 SDA ---------------------- P21 SDA
I2C_SLAVE_Receive(&I2C_SLAVE_0, slave_rx_data, DATA_COUNT); ==> OK
I2C_SLAVE_Transmit(&I2C_SLAVE_0, slave_rx_data, DATA_COUNT); ==> NG
slave receive api was able to receive the correct data, however WRONG data was transmitted using the slave transmit api.
Seems like tx buffer was offset/corrupted. Anyone encounter the same problem?? Any suggestion/idea??
Thanks
- Tags:
- IFX
1 Reply
Not applicable
Apr 27, 2016
11:43 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Apr 27, 2016
11:43 PM
Hi,
Thank you for reporting this.
This is due to the SCL line not set to input/output. This allows the slave to send the data even when the buffer is empty.
This will be fix in the July APP release.
Workaround: (for now)
For SCL= P1.3 in XMC1300 project , add the following code after DAVE_init(); in main.c:
XMC_GPIO_SetMode((XMC_GPIO_PORT_t *)PORT1_BASE, (uint8_t)3, XMC_GPIO_MODE_OUTPUT_OPEN_DRAIN_ALT6);
Eticket (#293328657) is filed for this update in APP:
https://www.infineonforums.com/support/dave3/index.php?option=com_maqmahelpdesk&Itemid=0&id_workgrou...
Regards,
Daryl
Thank you for reporting this.
This is due to the SCL line not set to input/output. This allows the slave to send the data even when the buffer is empty.
This will be fix in the July APP release.
Workaround: (for now)
For SCL= P1.3 in XMC1300 project , add the following code after DAVE_init(); in main.c:
XMC_GPIO_SetMode((XMC_GPIO_PORT_t *)PORT1_BASE, (uint8_t)3, XMC_GPIO_MODE_OUTPUT_OPEN_DRAIN_ALT6);
Eticket (#293328657) is filed for this update in APP:
https://www.infineonforums.com/support/dave3/index.php?option=com_maqmahelpdesk&Itemid=0&id_workgrou...
Regards,
Daryl