I’m trying to port the Inky library over to C++ so I can use it from an ESP32 using the Arduino tool set. All great journeys begin with a first step and in this case that first step is to try to query the EEPROM using I2C.
After many attempts I was only able to see good data once, maybe twice (400x300, 3, ?, ?). All of the other reads I end up with bogus data, generally FFFFFFFF, FFFFFFFF, 255, 255, 255.
Thought I would try to port the code for the Inky library. It looks pretty straight forward but I’m running into this very first issue where I can’t verify that I’m properly talking to it (via I2C).
Doesn’t the Inky wHat use SPI? I could be wrong but I do believe i2c is just used to read the ID eprom?
The other E-Inks you listed all look to also be SPI?
It does use SPI, that is correct. I haven’t gotten that far yet. The Inky library uses I2C to read the EEPROM to get the information about the display. This is what I posted about above and the problem I’m having. I too am trying to read the information from the EEPROM and generally get 0xFF for all reads.
Wow, just wow! I did a little more research to better understand what read_i2c_block_data actually does. The second argument is the command byte, I’m guessing allowing you to maybe read data from other things from the same address. Anyways, it’s written to the bus before the read, so there is actually an extra 0x0 written to the I2C bus. I added one more byte of 0x0 to my initial write and the data is now correct. I’m able to read the EEPROM.