Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: PCT2075_Hello Brushless_STM3_ESC_2019_10 Alternator2020_06
PCT2075.cpp
00001 #include "I2CTempSensor.h" 00002 #include "PCT2075.h" 00003 00004 PCT2075::PCT2075( PinName i2c_sda, PinName i2c_scl, char i2c_address ) 00005 : I2CTempSensor( i2c_sda, i2c_scl, i2c_address ) 00006 { 00007 init(); 00008 } 00009 00010 PCT2075::PCT2075( I2C &i2c_obj, char i2c_address ) 00011 : I2CTempSensor( i2c_obj, i2c_address ) 00012 { 00013 init(); 00014 } 00015 00016 PCT2075::~PCT2075() 00017 { 00018 } 00019 00020 float PCT2075::read( void ) 00021 { 00022 typedef I2CTempSensor base; 00023 00024 return( base::read16() / 256.0 ); 00025 } 00026 00027 PCT2075::operator float( void ) 00028 { 00029 return( read() ); 00030 }
Generated on Wed Jul 13 2022 08:50:39 by
1.7.2