Hangar Heater Cellphone Switch

NOTE: The FONA800 is a 2G cellular device which is being turned off by many carriers and will be obsolete by 2020.

I recommended that you use an LTE IoT device such as those from Particle.io. Their Boron is an excellent replacement device.

Check out the upgraded Remote Heater Controller.

Design

This project lets you send SMS text messages to a controller which allow you to turn an AC outlet on or off. The basics of the project are described at the Adafruit site: Adafruit FONA 800 Shield.

In my implementation, I used an AC plug and socket from a dead rotary timer. This made it a once piece controller that just plugs into the wall and saved adding the 120V plug and socket cords.

A 3D printed box was designed in SketchUp to fit this AC plug/socket component, the 5V-120V relay board, and the Arduino Uno. The box was printed using ABS filament on a PowerSpec 3D Pro Printer. I'd post the box design but the placement of the plug/socket is not likely to fit anyone elses component.

Here's a picture of it in use.

For my wireless carrier, I used T-Mobile which works out to $3 a month and includes 30 messages. The SIM card was free from a local T-Mobile store. You need to make sure the carrier uses GSM (T-Mobile, etc.) not CDMA (Verizon).

FONA 800 Interfaces:

A couple of commands may need to be issued using the FONAterminal.ino program. Send the commands "AT+CLTS=1" followed by "AT&W" to FONA to tell FONA to get is clock sync from the cell network. Power off then on again to get time sync. Query the new message indicator with "AT+CNMI" and you should get 2,1,0,0,0. This mode is set to notify the Uno that a SMS is waiting.

I included a temperature sensor in my design, however, this is not needed and those lines can be commented out. I had a 5k ohm no-heritage thermistor that I read with a simple one line curve fit.

The miniswitch should be connected between the battery and FONA shield. Turn it off when you are not using it since it will drain the battery which isn't a good thing. The larger LiIon battery is definitely needed. I started using a 350mAh LiIon but when the FONA transmitted, it would pull down the voltage and scramble the data.

The two LEDs indicate the operating state of the controller. One is on when the relay is on. The other is on when the Timer function is on. The timer LED also pulses to show you that the control loop is functioning.

Parts List

Software

All coding was done with the Arduino IDE. You will need the Adafruit_FONA library. Location and downloading are described on the Adafruit FONA 800 Test page. The basis for my code came from the FONA examples in the library subdirectory. Here's the current Arduino code for the Hangar Heater.

Operation

The commands are very simple. Just text "ON" to turn the relay on or "OFF" to turn it off. Texting "S" will provide a status of the controller giving you the time, battery voltage and percentage charge, cell signal level, temperature, whether the timer is on, and whether the heater is on. The timer function is turned on with a command in this format: "ONhhmmcc" where hhmm is the hour and minutes past the hour to turn on and cc is the number of hours to turn on. The timer is shut off with an "OFF" command. The controller will always send a confirmation response to any valid command. An example status response would be: "Status: At 18:20 B:4137mV 92% S:-97dbm 35F Lo:20 @04:20 Hi:38 @13:01 Timer=Off Heater=On"