Temp Library from C.Evans.
Diff: TMP102.cpp
- Revision:
- 2:1a4fbc01a494
- Parent:
- 0:8818842a3573
- Child:
- 3:0cb40fee2959
diff -r 8818842a3573 -r 1a4fbc01a494 TMP102.cpp --- a/TMP102.cpp Fri Feb 05 17:24:06 2016 +0000 +++ b/TMP102.cpp Sat Dec 04 13:19:13 2021 +0000 @@ -6,11 +6,11 @@ // we now implement each of the methods listed in the header // note the TMP102:: at the beginning of the method name -TMP102::TMP102(PinName sda, PinName scl) +TMP102::TMP102(PinName SDA, PinName SCL) { - // in the constructor, we create the mbed API objects using 'new' - i2c_ = new I2C(sda,scl); - led_ = new DigitalOut(LED_RED); + //New mbed API objects are created in the contructor using new + i2c_ = new I2C(SDA,SCL); + led_ = new DigitalOut(LED_BLUE); } void TMP102::init()