The intention was to create windows that understand my flatmate's requirement and open itself to give some ventilation during the winter season, but while doing so and letting the cold air in, the temperature inside should be accordingly controlled to give not only fresh air but also warm atmosphere.
The solution involves a window that gets the weather data from the internet, if the temperature is too chilly it will avoid opening the window, but it it's reasonably cold, the window will get opened to let some fresh air in. While doing so, the temperature inside the room would be monitored to see it's warm enough and if it isn't the heater would be controlled to balance the climate in the room to let a person enjoy some cold and fresh air while also not making the room extremely cold.
I started the project by implementing a temperature sensor which would be used to monitor the room. later I started thinking of ideas the way it would be connected to the heater. I later installed LEDs to indicate the heater's temperature is being increased and used a servo to open the windows. So the Servo would open the windows, and then TMP36 would read the data, if it's getting very cold, the heater would be adjusted and this is when one led glows, if still the temperature is cold, the heater would again be adjusted which is shown by the blinking of second led.
The temperature sensor is getting the analog values and printing it on the serial monitor and when it is in a certain range, the first led blinks. It checks again for the readings which is equivalent to checking if the temperature inside the room is still cold, and if it is the second led blinks.
Next step would be to get the weather data from the internet and feed it to the window which will influence the action of the servo while also implementing by actually opening the window, since the temperature values that I took are quite arbitrary. The window can also be controlled by a voice command.
The logic was implemented the way I wanted to though I had difficulty in getting a low temperature from the sensor and to get a certain value that would blink the LEDs.