Skip to content

Commit

Permalink
tryfix SHT31 sensor on secondary bus
Browse files Browse the repository at this point in the history
  • Loading branch information
caveman99 committed Mar 11, 2024
1 parent 3a8f623 commit 658ed6f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/mesh/NodeDB.h
Original file line number Diff line number Diff line change
Expand Up @@ -248,4 +248,4 @@ extern uint32_t error_address;
#define Module_Config_size \
(ModuleConfig_CannedMessageConfig_size + ModuleConfig_ExternalNotificationConfig_size + ModuleConfig_MQTTConfig_size + \
ModuleConfig_RangeTestConfig_size + ModuleConfig_SerialConfig_size + ModuleConfig_StoreForwardConfig_size + \
ModuleConfig_TelemetryConfig_size + ModuleConfig_size)
ModuleConfig_TelemetryConfig_size + ModuleConfig_size)
2 changes: 1 addition & 1 deletion src/modules/Telemetry/Sensor/SHT31Sensor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ int32_t SHT31Sensor::runOnce()
if (!hasSensor()) {
return DEFAULT_SENSOR_MINIMUM_WAIT_TIME_BETWEEN_READS;
}
status = sht31.begin();
status = sht31.begin(nodeTelemetrySensorsMap[sensorType].first);
return initI2CSensor();
}

Expand Down
2 changes: 1 addition & 1 deletion src/modules/Telemetry/Sensor/SHT31Sensor.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
class SHT31Sensor : public TelemetrySensor
{
private:
Adafruit_SHT31 sht31 = Adafruit_SHT31();
Adafruit_SHT31 sht31 = Adafruit_SHT31(nodeTelemetrySensorsMap[sensorType].second);

protected:
virtual void setup() override;
Expand Down

0 comments on commit 658ed6f

Please sign in to comment.