School project.
Dependencies: Timezone NTPClient BSP_DISCO_F746NG Grove_temperature
Diff: button_functions.h
- Revision:
- 15:638e65c37d58
- Parent:
- 14:3ac7c08dbc52
--- a/button_functions.h Mon Jan 18 16:13:13 2021 +0000 +++ b/button_functions.h Tue Jan 19 10:05:13 2021 +0000 @@ -10,10 +10,12 @@ @is_fahrenheit Bool value to reverse. 1/18/2021 */ -void button_switch_temp_unit(DigitalIn& button, bool& is_fahrenheit) +bool button_switch_temp_unit(DigitalIn& button, bool& is_fahrenheit) { if (button.read() == 1 ) { is_fahrenheit = helper_reverse_bool(is_fahrenheit); + return true; } + return false; } \ No newline at end of file