Skip to content

Commit 97fd95e

Browse files
committed
clang
1 parent 9aa8f37 commit 97fd95e

File tree

1 file changed

+24
-24
lines changed

1 file changed

+24
-24
lines changed

src/components/i2c/WipperSnapper_I2C.cpp

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -127,31 +127,31 @@ bool WipperSnapper_Component_I2C::attachI2CDevice(
127127
// AHTX0 Sensor
128128
if (msgDeviceInitReq->has_aht_init) {
129129
// TODO: Implement handling in future release
130-
/* uint16_t addr = (uint16_t)msgDeviceInitReq->aht_init.address;
131-
WS_DEBUG_PRINTLN("Requesting to initialize AHTx sensor");
132-
WS_DEBUG_PRINT("\tSensor Addr: ");
133-
WS_DEBUG_PRINTLN(addr, HEX);
134-
WS_DEBUG_PRINT("\tTemperature sensor enabled? ");
135-
WS_DEBUG_PRINTLN(msgDeviceInitReq->aht_init.enable_temperature);
136-
WS_DEBUG_PRINT("\tHumidity sensor enabled? ");
137-
WS_DEBUG_PRINTLN(msgDeviceInitReq->aht_init.enable_humidity);
130+
/* uint16_t addr = (uint16_t)msgDeviceInitReq->aht_init.address;
131+
WS_DEBUG_PRINTLN("Requesting to initialize AHTx sensor");
132+
WS_DEBUG_PRINT("\tSensor Addr: ");
133+
WS_DEBUG_PRINTLN(addr, HEX);
134+
WS_DEBUG_PRINT("\tTemperature sensor enabled? ");
135+
WS_DEBUG_PRINTLN(msgDeviceInitReq->aht_init.enable_temperature);
136+
WS_DEBUG_PRINT("\tHumidity sensor enabled? ");
137+
WS_DEBUG_PRINTLN(msgDeviceInitReq->aht_init.enable_humidity);
138138
139-
// TODO: Create I2C Driver using the an AHT driver sub-class!
140-
I2C_Driver *aht = new I2C_Driver(addr, this->_i2c);
141-
// Attempt to initialize the sensor driver
142-
if (!aht->initAHTX0()) {
143-
attachSuccess = false;
144-
return attachSuccess;
145-
}
146-
// Initialize device-specific sensors
147-
if (msgDeviceInitReq->aht_init.enable_temperature == true) {
148-
aht->enableAHTX0Temperature();
149-
}
150-
if (msgDeviceInitReq->aht_init.enable_humidity == true) {
151-
aht->enableAHTX0Humidity();
152-
}
153-
// Push to vector for sensor drivers
154-
activeDrivers.push_back(aht); */
139+
// TODO: Create I2C Driver using the an AHT driver sub-class!
140+
I2C_Driver *aht = new I2C_Driver(addr, this->_i2c);
141+
// Attempt to initialize the sensor driver
142+
if (!aht->initAHTX0()) {
143+
attachSuccess = false;
144+
return attachSuccess;
145+
}
146+
// Initialize device-specific sensors
147+
if (msgDeviceInitReq->aht_init.enable_temperature == true) {
148+
aht->enableAHTX0Temperature();
149+
}
150+
if (msgDeviceInitReq->aht_init.enable_humidity == true) {
151+
aht->enableAHTX0Humidity();
152+
}
153+
// Push to vector for sensor drivers
154+
activeDrivers.push_back(aht); */
155155
attachSuccess = true;
156156
} else {
157157
WS_DEBUG_PRINTLN("ERROR: Sensor not found")

0 commit comments

Comments
 (0)