DocBohn / CowPi_stdio

A library to interface with the Arduino serial monitor using familiar stdio functions.
Apache License 2.0
0 stars 0 forks source link

Troubleshoot running multiple LCD displays. #33

Open DocBohn opened 1 year ago

DocBohn commented 1 year ago

As I'm shooting a video of the LCD1602 & LCD2004 side-by-side, we're seeing some surprising behavior on the LCD2004.

DocBohn commented 1 year ago

If we start "Advancing past\nthe bottom\n" on the second row instead of the third, it correctly displays that text on the second and third rows, and then \n goes to the first row. But if we start "Advancing past\nthe bottom\n" on the third row, it correctly displays that text on the third and fourth rows, and then \n goes to the second row.

DocBohn commented 1 year ago

When it's just the LCD2004 without the LCD1602, everything behaves as expected.

DocBohn commented 1 year ago

We've already seen that running one LCD display over I2C and one over SPI won't work -- but that isn't surprising, given the current design. I'm not sure why the LCD1602 is mucking up the LCD2004 when they're both using I2C (with different addresses).

DocBohn commented 1 year ago

Current hypothesis (and this seem incredibly plausible) -- the ddram_address variable is not unique to each display. https://github.com/DocBohn/CowPi_stdio/blob/main/src/file_streams/hd44780_streams.c#L33