Question
It is that time of year folks: fall and winter make us pay attention to our thermostat for creature comfort. In this assignment, we will
It is that time of year folks: fall and winter make us pay attention to our thermostat for creature comfort. In this assignment, we will be building a system to manage the temperature of a house/apartment that has a thermostat, furnace, and air conditioner, all tied into one integrated system. In the future, you can modify this program (and I encourage that) to account for while loops and timing delays, but as for right now, we are going to manage the interface manually using if blocks and select case blocks.
There are a few basic intuitive rules for the system:
The AC unit activates when it is warmer inside than the thermostat asks for and cools the room by one degree.
The furnace unit activates when it is colder inside than the thermostat asks for and warms the room by one degree.
The temperature of the room rises 1/2 degree if the temperature outside is warmer than the temperature inside.
The temperature of the room decreases 1/2 degree if the temperature outside is cooler than the temperature inside.
In this assignment, we will make a form that puts the whole thing together into one unit that we will execute with buttons.
Your program should include:
Prompts for the user to input the outside temperature, inside temperature, and thermostat temperature and labels that will store that information and display it to the user.
Buttons that will execute each of the following tasks (each of these tasks should also execute a temperature adjustment based on the differences in temperature...if these buttons are pushed in error, only the temperature adjustment should occur):
Run the AC unit
Run the furnace unit
Adjust the thermostat
Adjust the outside temperature
When any of the labels change value (which they should at some point), change the color of the AC (blue) and furnace (red) buttons to prompt the user what they need to do (use the furnace or use the AC). If no change is needed, prompt the user to change the thermostat or adjust the outside temperature.
You are not limited as to how to do this assignment, with the exception that you should use if blocks or select case blocks to achieve it (including concepts we have seen before). While I acknowledge that this can be done using one or the other, please use both somehow in the exercise for the sake of practice.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started