ATmega168 MCU powers energy-saving thermostat

Earlier this month, Bits & Pieces took a closer look at a smart thermostat in the Netherlands powered by an Arduino Mega 2560 (ATmega2560 MCU), as well as a three-zone thermostat built around an Atmel-based Arduino Uno (ATmega328).

Today, we’re going to get up close and personal with a thermostat equipped with a stand-alone Atmel ATmega168 AVR micrcontroller that was built to regulate Andrian’s boiler.

“After a few minutes, the [boiler] warms the water enough so that the water temp exceeds the thermostat limit. The thermostat changes state and drives an electric valve to move the water from the boiler to the radiators. The electric valve is slow and takes a few minutes to make a full turn,” Andrian wrote in a recent blog post.

“While the water is moving from the boiler to the radiators, circularly cool water is coming back from the radiators. Τhe water temp in the boiler is getting cooler and after a few minutes falls under the thermostat’s limit. The thermostat changes state and stops the valve from driving the water to radiators. This happens again and again until [all the] water in the radiators is warm. ”

To prevent this issue – opening and closing the electric valve in minimal increments – Andrian designed a thermostat capable of delaying the sample points. More specifically, it monitors the boiler temp, driving the electric valve only when the overall water temp exceeds the thermostat limit. Subsequently, the device waits half an hour or more before once again checking the water temperature.

Key project specs include:

  • 

One LM7805 regulator and two capacitors (simple power supply design)
  • 
Rotary/push-button switch (menu selection and configuration)
  • 
Two relays driving external electric valves
  • HD4780 LCD display

“The main MCU is the [Atmel] 8-bit AVR ATmega168, with a buzzer [alerting] the user for a button press or a limit exceeded,” Andrian explained.

flashingmcu

“[Meanwhile], two LM35 temp sensors one internal and one external measure the ambient and pipe – boiler temp. You [will] also notice a 32.768Khz crystal, used to implement a real time clock which [tracks] real time delays.”

Interested in learning more about Andrian’s AVR-thermostat? You can check out the project’s official page here.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s