Skip to content

Conversation

@ngavars
Copy link
Contributor

@ngavars ngavars commented Dec 12, 2025

This PR adds a second I2C interface (Wire1) and uses EnvironmentSensorManager in t114 variant. This automatically adds support for all the sensors that EnvironmentSensorManager supports.
The Wire1 (and thus sensors) is currently enabled only for Heltec_t114_repeater and Heltec_t114_without_display_repeater targets.
Tested with t114 repeater (no screen, no gps). All the t114 build targets are building ok.

@ngavars
Copy link
Contributor Author

ngavars commented Dec 15, 2025

Tested on t114 with GPS too - it's working.

@IoTThinks
Copy link

Are you able to add sensor support to Heltec T114 with display?
For Heltec V3, I have issue when trying to support sensors on Wire1 while still keeping Wire for OLED.

Whenever, Wire1 is active, Wire instance seems clear / resets and can not be used.

@ngavars
Copy link
Contributor Author

ngavars commented Dec 16, 2025

Are you able to add sensor support to Heltec T114 with display? For Heltec V3, I have issue when trying to support sensors on Wire1 while still keeping Wire for OLED.

Whenever, Wire1 is active, Wire instance seems clear / resets and can not be used.

My change adds EnvironmentSensorManager as a sensor manager class. It will only activate Wire1 and scan for sensors on boards without display because those boards are often used as repeaters. Repeaters often use sensors (current, temperature, humidity etc) and I was surprised that t114 implementation did not support any.
Heltec t114' s with display on the other hand are mostly used as companions and do not require any sensors (except for the GPS, of course), hence they will not jump though extra hoops, trying to init sensors. But this does not mean that they wouldn't work if pins are defined.

Regarding V3: if I remember correctly, it already has sensor support. Pins 17 and 18 are tiny and located in the middle of the board. Has something changed in this regard?

@IoTThinks
Copy link

Ok, thanks a lot for sharing.
There is a bug when both Wire and Wire1 are active. Let me figure it out.

I use GPIO41 and 42 for Wire1 instead of the tiny GPIO17 and 18.

fschrempf and others added 8 commits December 17, 2025 22:14
The reboot() method is the same for all NRF52 boards. Use a shared
implementation.

Signed-off-by: Frieder Schrempf <[email protected]>
Use a common begin() method that can be called from derived classes
to contain the shared initialization code.

Signed-off-by: Frieder Schrempf <[email protected]>
Some NRF52 boards are able to use the internal power-efficient DC/DC
regulator. Add a new class that can be inherited by board classes to
enable this feature and reduce the power consumption.

Signed-off-by: Frieder Schrempf <[email protected]>
The startOTAUpdate() is the same for all NRF52 boards. Use a common
implementation for all boards that currently have a specific
implementation.

The following boards currently have an empty startOTAUpdate() for
whatever reasons and therefore are not inheriting NRF52BoardOTA to
keep the same state: Nano G2 Ultra, Seeed SenseCAP T1000-E,
Wio WM1110.

Signed-off-by: Frieder Schrempf <[email protected]>
The function in the derived class is virtual per definition. Mark it
to make this clearer to the reader.

Signed-off-by: Frieder Schrempf <[email protected]>
The RAK4631/RAK4630 module are able to use the DC/DC converter. Enable
it to reduce power consumption.

Signed-off-by: Frieder Schrempf <[email protected]>
@ngavars
Copy link
Contributor Author

ngavars commented Dec 17, 2025

Rebased, all good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants