The document provides instructions for coding an IoT thermostat that allows changing the target temperature from a web page by calling a cloud function. It instructs to 1) add a function to update the target temperature variable, 2) register this function as a cloud function, 3) add a form to the HTML to call this cloud function, and 4) test the functionality. A hint is provided to print temperatures to serial for debugging. The completed thermostat should display current/target temperatures, allow changing the target and mode, and indicate mode with an LED.
Can someone help me code this with these outputs1. In your microc.pdf
1. Can someone help me code this with these outputs?
1. In your microcontroller code,
a) Add a function to update the targetTemp global variable with the declaration:
b) int setTargetTempFromString(String inputString) {...}
2. Register setTargetTempFromString as a cloud function called cF_setTargetTemp
3. In your HTML code, add another form that calls the cloud function cF_setTargetTemp
It may look something like this:
4. Test the functionality of your webpage and microcontroller to set and view the target
temperature.
HINT: For debugging purposes, it may be useful to have your microcontroller print the
current and target temperatures to the serial port.
When you are finished you should have an IoT Thermostat that does the following:
-Displays the current and target temperature value
-Allows you to change the target temp
-Allows you to change the mode
-Indicates the mode of the microcontroller with an LED
*It should look like this:
This is the given code: