School project.

Dependencies:   Timezone NTPClient BSP_DISCO_F746NG Grove_temperature

Revision:
13:41debc0b9063
Child:
14:3ac7c08dbc52
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/button_functions.h	Mon Jan 18 13:39:58 2021 +0000
@@ -0,0 +1,19 @@
+/**
+@file    helper_functions.h
+@author  Tu Tri Huynh
+@date    January 18, 2021
+@brief   Functions related to Grove Button.
+*/
+
+/**
+This function reverses the bool value inputted if button press is registered.
+@is_fahrenheit Bool value to reverse.
+1/18/2021
+*/ 
+void button_switch_temp_unit(DigitalIn& button, bool& is_fahrenheit)
+{
+    if (button.read() == 1 )
+    {
+       is_fahrenheit = helper_reverse_bool(is_fahrenheit);
+    }
+}
\ No newline at end of file