arduino-esp32: v2.0.9, Arduino IDE v2.0.4.
MCU: ESP32-S3
I have had some success getting I2C slave comms working in the ESP32-S3 using the Wire library with an NXP2132 MCU
as a master and it's working perfectly.
Here's a summary of my I2C comms:
[M - S] Master (NXP) writes the slave address (W) followed by 21 bytes to the slave (ESP32-S3).
Restart bit sent and then the slave address (R) and 100 bytes are read from the slave.
Last byte is NACKed by the master and then stop bit is sent by the master.
The trouble is that there is existing firmware which I need to support for the NXP2132 master MCU which does not fully conform to the i2c specs. The last byte read is not NACKed by the NXP and the stop bit is not sent.
As a work around, in place of the stop bit, I am currently trying to reset the i2c peripheral following a timeout after reading the last byte (I'm using the SCL_MAIN_FSM timeout interrupt for timing of sending the stop bit). I'm not having much luck getting this to work though.
On the first read the slave sends the 100 bytes as expected, but on the next read, following the i2c peripheral reset, the first byte read is incorrect (always 0x45), following this byte the message data is correct. I'm not sure how the tx fifo is getting a garbage byte added in there on the second read message.
Just wondering if anyone could help to think of a possible work around for this? I though it should have a decent chance of working as the first read request is always working correctly.
ESP32-S3 I2C Slave no end transaction
Jump to
- English Forum
- Explore
- News
- General Discussion
- FAQ
- Documentation
- Documentation
- Sample Code
- Discussion Forum
- Hardware
- ESP-IDF
- ESP-BOX
- ESP-ADF
- ESP-MDF
- ESP-WHO
- ESP-SkaiNet
- ESP32 Arduino
- IDEs for ESP-IDF
- ESP-AT
- ESP IoT Solution
- ESP RainMaker
- Rust
- ESP8266
- Report Bugs
- Showcase
- Chinese Forum 中文社区
- 活动区
- 乐鑫活动专区
- 讨论区
- 全国大学生物联网设计竞赛乐鑫答疑专区
- ESP-IDF 中文讨论版
- 《ESP32-C3 物联网工程开发实战》书籍讨论版
- 中文文档讨论版
- ESP-AT 中文讨论版
- ESP-BOX 中文讨论版
- ESP IoT Solution 中文讨论版
- ESP-ADF 中文讨论版
- ESP Mesh 中文讨论版
- ESP Cloud 中文讨论版
- ESP-WHO 中文讨论版
- ESP-SkaiNet 中文讨论版
- ESP 生产支持讨论版
- 硬件问题讨论
- 项目展示
Who is online
Users browsing this forum: No registered users and 81 guests
- All times are UTC
- Top
- Delete cookies
About Us
Espressif Systems is a fabless semiconductor company providing cutting-edge low power WiFi SoCs and wireless solutions for wireless communications and Internet of Things applications. ESP8266EX and ESP32 are some of our products.