tryfix SHT31 sensor on secondary bus

pull/3339/head^2
Thomas Göttgens 2024-03-11 13:51:26 +01:00
rodzic 3a8f623f8a
commit 658ed6fd28
3 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -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)

Wyświetl plik

@ -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();
}

Wyświetl plik

@ -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;