There are a lot of pieces to this project. I started out using a solderless breadboard and jumper wires / alligator clips to get everything in place and make sure it all worked. These boards are meant for prototyping and can make the wire spaghetti mess a lot easier to sort out.
When I was happy with the setup and placement of components, I transferred everything to a perma-proto breadboard and soldered it in place.Â
Solder headers onto your QT Py and attach it to your breadboard. Connect the G pin to the G (blue) power rail and the 5v pin to the red power rail.Â
We'll be attaching all the G and 5v wires from our components to the power rails we've just created. This is much easier than trying to solder EVERY G wire to that one pin on the QT Py.
The RF remote has two buttons inside: one for starting the smoke and one for stopping it. We need a relay for each button to actuate it using Adafruit IO.
Open up the RF remote by removing the tiny screw on the back. Take the battery out -- you never want to solder to a live circuit. You'll see two momentary switch buttons inside. Carefully and gently solder a tiny wire to each leg of each button. Connect them to your two relays as shown.
Make your wires a little longer than pictured here -- I had to go in and lengthen these a bit to give myself room in the enclosure.
Our Adafruit IO controls use the relays to "hold" these buttons down for a while. The remote wasn't really designed with this in mind, and the little 12v battery in there wears out really fast. When that battery dies, the smoke can't be stopped and the dragon gets out of control quickly. Luckily we have a solution to keep our villagers safe from excessive dragon smoke: we can power the remote using a 12v power boost and bypass the battery altogether.
Solder a red wire to the positive battery terminal on your remote, and a black wire to the negative (the one with the spring). We'll connect the other end of these wires to our 12v booster board.
Flip the board over and attach the relays to the back of the breadboard using thick mounting tape. Solder the connectors to the breadboard as shown: red wires to the red power rail, black wires to the blue power rail. The white wires will connect to pins A1 & A2.
Solder the 12v booster in between the relays. Connect G to the blue power rail and IN to the red power rail.Â
Connect the red wire from your remote battery terminal to 12v, and the black wire to the G power rail.
The PIR sensor will need protection from the elements. I found a little plastic box that fits the sensor and closes tightly, and cut a hole in the top with my dremel that's just the right size for the fresnel lens to poke through.
I sealed the sensor in place with some hot glue, then cut the female connector off and physically soldered the 3 wires to the pins. This gave me a little bit of a lower profile so the sensor fit in the box better, and also gives me more assurance that the wires will stay in place.
Connect the 3 wires from the PIR sensor to the breadboard: red to the red power rail, black to the blue power rail, and yellow to pin A0.
NeoPixel Strand
The NeoPixels will need to be installed in the dragon, which isn't going to be easy. I used a JST connector on the strand so I can put the pixels in place and leave them there while I futz around with the rest of the electronics. I sealed them up really well so they should be waterproof enough to last through the rainy season without having to be removed. I don't want to leave my electronics case out there though, so using a connector is a great way to keep this project working year after year without having to completely disassemble everything.Â
Solder a male 3-pin JST connector for the NeoPixel strand as shown: red to the red power rail, G (white wire in this case) to the blue power rail and the middle wire (Data IN) will go to pin A3.
Caution: the color coding on these connectors varies greatly. It doesn't matter which color goes where as long as the wires match up correctly with your NeoPixel strip. It helps to plug in the female side of the connector before soldering to the strip, so you can get a physical look at which wire is going where.
Solder the other side of the JST connector to your NeoPixel strip. Remember to give yourself enough lead wire on the connectors that the pixels and electronics don't have to be all in the same spot.
I cut a few holes in the sides of my plastic enclosure box so the wires can come out, then stuck the remote to the top with some alien tape. I like keeping the remote outside the box so the buttons can be accessed manually, in case it's needed.
Plug a USB cable into your QT Py. If you've already installed Wippersnapper, you should see a blinking yellow light for a few seconds and then a blinking blue light. This means your board is connecting to WiFi and is ready to make some magic happen.
You should also see power to the RF remote. Press the buttons and be sure a little red light comes on, or turn on your fog machine to be sure the buttons are doing their job.
If that all appears to be working, let's head to Adafruit IO to make our setup Do Stuff!
Troubleshooting
There are a lot of components and connections happening here. Here are a couple things that might be getting in your way:
- If your board isn't giving you yellow and then blue lights, try reinstalling Wippersnapper. Make sure your WiFi credentials are correct and that you are within range of the WiFi network.
- If your remote isn't coming on, be sure you've got the red and black wires from the 12v booster going to the correct battery terminals. The black wire goes to the one with the spring.
- If the remote just won't make the fog happen, remember that the fog machine needs to warm up for a few seconds to a full minute before it's ready to go. There is a red light on the wired controller box that appears when the fog is ready. Wait until that light comes on and then try the remote again.
- Carefully check your breadboard under a magnifier to make sure you don't have any short circuits / solder bridges, especially between the red and black power rails. We used those things a lot, and it's easy to miss a little misplaced blob of solder, which can wreck your whole day. If you try to power it up and don't get power, this is definitely something to check.
Page last edited October 02, 2024
Text editor powered by tinymce.