File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ void setup() {
2929 Serial.begin (115200 );
3030
3131 /* The default setup is :
32- * Conversion mode = CONTINUOUS ---> continuoss
32+ * Conversion mode = CONTINUOUS ---> continuous
3333 * Conversion time = C125mS -|
3434 * Averaging mode = AVE8 -|-> new data every 125mS
3535 * Alert mode = data ---> alert pin states that new data is available
Original file line number Diff line number Diff line change 11name =TMP117-Arduino
2- version =1.0.1
2+ version =1.0.2
33author =Nils Minor <
[email protected] >
44maintainer =Nils Minor <
[email protected] >
55sentence =Full-featured Arduino compatible TMP117 driver
Original file line number Diff line number Diff line change @@ -167,11 +167,15 @@ void TMP117::setTargetTemperature ( double target ) {
167167 @return uint16_t read value of the configuration regsiter
168168*/
169169uint16_t TMP117::readConfig (void ) {
170- uint16_t reg_value = i2cRead2B ( TMP117_REG_CONFIGURATION );
171- bool high_alert = reg_value >> 15 & 1UL ;
172- bool low_alert = reg_value >> 14 & 1UL ;
170+ uint16_t reg_value = i2cRead2B ( TMP117_REG_CONFIGURATION );
173171 bool data_ready = reg_value >> 13 & 1UL ;
174- bool eeprom_busy = reg_value >> 12 & 1UL ;
172+
173+ // following bits are a comment in order to not create compiler warnings
174+ // but might be used in the future for some purpose
175+ // bool eeprom_busy = reg_value >> 12 & 1UL;
176+ // bool high_alert = reg_value >> 15 & 1UL;
177+ // bool low_alert = reg_value >> 14 & 1UL;
178+
175179
176180 if (data_ready && newDataCallback != NULL )
177181 newDataCallback ();
@@ -324,7 +328,7 @@ uint16_t TMP117::i2cRead2B (uint8_t reg) {
324328 Wire.beginTransmission (address);
325329 Wire.write (reg);
326330 Wire.endTransmission ();
327- Wire.requestFrom (address, 2 );
331+ Wire.requestFrom (( uint8_t ) address, ( uint8_t ) 2 );
328332 if (Wire.available () <= 2 ){
329333 data[0 ] = Wire.read ();
330334 data[1 ] = Wire.read ();
You can’t perform that action at this time.
0 commit comments