Frosty 2.0

Frosty 2.0
Welcome to the techno-dystopian Christmas future

Frosty the front-yard Christmas decoration has been upgraded from 1980's fiber-optic technology ( which was admittedly, very high-tech at the time ), to what the new millennium has provided: bright-ass LEDs.

Here is Frosty in his original condition. That broom seems to get broken even before you take it out of the box.

widely available on Ebay

I'm mostly proud that I got this together in time for Christmas. It helped that the bulk of the hardware and software parts were already assembled, having previously powered the LED Jack-o-lantern:

party Jack

BOM:

  • ESP8266 - I'm using a 'devkit' style board but really any of them that expose at least 3 GPIOs
  • 7805 x1 voltage regulator - taking the 9-12V input voltage ( a 3S battery or wall-powered DC transformer ) down to 5V for the MCU
  • IRL520 x3 - an N-type MOSFET capable of handling 100V 10A, to control each of the R, G, B channels of the LED lights
  • SMD5050 RGB LED strip (5m)
  • battery or wall power supply
bench testing. See those 3 transistors? Those switch the R-G-B channels

Frosty AP AF

While completely unnecessary, giving frosty a remote-control UI that can be loaded up on a mobile device is a lot of fun. One of the goals of this project was to get my kid engaged and maybe get a chance to show him some of the code that makes Frosty's lights flash.

This was the primary reason an "ESP" device was used rather than a basic Arduino - it provides the Wifi Access-Point to which it connects itself as a client. By connecting to this AP and accessing the device's IP in a browser - any device becomes a remote control.

192.168.4.1 on "frostynet"

Controls

  • RGB: Manually mix a combination of RGB channels to set any color
  • Red Flashes: Leftover from the Jack-o-lantern, a useful test routine
  • Winter Wonderland: A nice twinkling mode featuring various blue-green hues
  • Crazy Christmas: Intense strobe effects of red and green values
  • Party Frosty: Strobe effect of many randomly-generated colors

For a peek behind the curtain, here is how Christmas mode works:

void christmasColors () {
   everythingOff();
   // alternate red and green
   for (int cycles = 0; cycles <= 120; cycles++) {
     fadeToRGBPWM(250, 0, 0, random(20, 90));
     fadeToRGBPWM(0, 250, 0, random(20, 90));
   }
   everythingOff();
}

The Final Result

This mode is called 'party frosty'

What has been learned?

Originally I wanted to learn how to use transistors for switching actual current-carrying loads ( the LED strip in this case ), and with a different supply voltage than the MCU's circuit. The high-speed switching enabled by the transistors also helps produce the dramatic, seizure-inducing effects that would not have been possible with relays. So YAY for MOSFETs, they have proven to be much easier to work with than BJTs.

Next Steps

As always, it is hard to pick a stopping point when you're just having fun. I would like to hook up an HC-SR04 ultrasonic distance sensor so that Frosty could surprise people as they approach ( or drive by? ).

I need to actually solder up the circuit someday so the whole thing is more durable and therefore more portable.

Other ideas for were to go from here:

  • OTA updates for the ESP
  • integrating with ROS framework