Grove temperature sensor library
Dependents: Grove_Temp_Hello_world
Grove_temp_sensor Class Reference
Setup a new class for Grove_temp_sensor sensor. More...
#include <Grove_temp_sensor.h>
Public Member Functions | |
Grove_temp_sensor (PinName pin) | |
Create a Grove_temp_sensor object connected to the pin. | |
float | read_F () |
Read the temperature in Fahrenheit. | |
float | read_C () |
Read the temperature in Celsius. | |
float | operator= (Grove_temp_sensor &rhs) |
Shorthand to read the temperature value. |
Detailed Description
Setup a new class for Grove_temp_sensor sensor.
Definition at line 10 of file Grove_temp_sensor.h.
Constructor & Destructor Documentation
Grove_temp_sensor | ( | PinName | pin ) |
Create a Grove_temp_sensor object connected to the pin.
- Parameters:
-
pin to connect to
Definition at line 5 of file Grove_temp_sensor.cpp.
Member Function Documentation
float operator= | ( | Grove_temp_sensor & | rhs ) |
Shorthand to read the temperature value.
- Parameters:
-
returns temperature in Celsius
Definition at line 32 of file Grove_temp_sensor.cpp.
float read_C | ( | ) |
Read the temperature in Celsius.
- Parameters:
-
returns temperature
Definition at line 22 of file Grove_temp_sensor.cpp.
float read_F | ( | ) |
Read the temperature in Fahrenheit.
- Parameters:
-
returns temperature
Definition at line 10 of file Grove_temp_sensor.cpp.
Generated on Fri Jul 15 2022 19:00:04 by 1.7.2