Replies: 2 comments 6 replies
-
Since Zephyr 3.5.0 there is A |
Beta Was this translation helpful? Give feedback.
-
@GeorgeCGV Thanks. In using
and from the should set GPIO HIGH correctly init before I2C and SSD1306 gets initialized. I have verified that I'mgetting 3.26V at the I2C STEMMA connector and SDA/SCK levels look fine. Data is being pushed on to the I2C but SSD1306 is uninitialized. I'll try using What is the best way to get the GPIO 21 pin directly when calling from early_init? Thanks.
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
The request is how to correctly enable power on
I2C STEMMA
connector on a range ofAdafruit ESP32-S3
boards before any I2C andSSD1306
(ST7789
) display driver initialization.The
Adafruit ESP32-S3
boards have on-boardI2C STEMMA
connector to allow I2C devices to beconnected to it. In addition some of the boards have an on-board
ST7789
135x240 TFT display. I'm trying to connect a I2C SSD1306 display and also use the on-board ST7789 display.Power to both the I2C Stemma connector and the TFT is controlled by raising a GPIO pin high at a regulator. I2C STEMMA SDA and SCK have 10K pull-up resistors.
Under Arduino, the initialization takes care of enabling power to I2C connector before the user's setup().
Describe the solution you'd like
I would like to enable power to the I2C STEMMA connector so that I can utilize both the on-board ST7789 display, as well as an I2C SSD1306 display (or any other I2C sensor) connected to the I2C STEMMA connector.
Describe alternatives you've considered
I've tried to use
gpio-hog
and alsoregulator binding
controlled via a GPIO.Here is the
gpio-hog
devicetree overlays that I used to set a GPIO pin high during initialization,and the
regulator binding
with GPIO controlIn my setup, I have a SSD1306 OLED display connected to the I22 STEMMA conenctor.
I’m able to confirm that the power to the display on the I2C STEMMA connector comes on when
I use gpio-hog or the regulator binding. However, the display still doesn’t show anything.
From the “west espressif monitor”, I’ve confirmed that I2C is in a READY state but the
SSD1306 failed to initialize. I do see 3.26V at the display connected via the I2C STEMMA
and the SDA/SCK signals look fine.
I2C is sending commands/data to the display correctly and there are no crashes on the ESP32-S3 and shell works fine.
I suspect that there may be a sequence issue, for example,
gpio-hog
orregulator binding
enabling the I2C powerafter SSD1306 but before I2C initialization.
Is there a way to check the order of I2C, SSD1306 and
gpio-hog
( orregulator binding
) priority in Zephyr?Is
gpio-hog
orregulator binding
the right way to turn on I2C power on initialization?Additional context
Alternatively, Should I be using
SYS_INIT() with PRE_KERNEL
and set the I2C powerGPIO high in early_init() as in the example below?
Beta Was this translation helpful? Give feedback.
All reactions