Here's how I built/converted a regular Wii Nunchuck into a Bluetooth Nunchuck Controller for my electric skateboard! If you are not familiar with my series of electric skateboards, I have an excellent set of instructables here, here, and here.
I've been using my DIY Smartphone Controller to control the speed of my latest prototype, but I wanted something that was more tactile, and that's what inspired me to build this mini-project! This Nunchuck is also compatible with my old smartphone receiver circuit, meaning you can switch back and forth between using the smartphone app and the nunchuck!
I also included a dead-man's switch for safety, and a settings button, which will cycle between beginner, intermediate, and expert modes by limiting the maximum speed and braking power.
The Nunchuck is powered by a 500mAh lithium-ion cell, which, at a current draw of ~50mA, gives it a run-time of about 10 hours. The cell can also be recharged using a micro-USB plug located at the back of the device.
Here's a short video explaining how the Nunchuck controller works, and how to build it! Give it a watch; it adds a further level of explanation to this Instructable!
Most of my projects are based on the Atmel/Arduino platform, so I decided to use it for this project. However, I did not need the full functionality of an Arduino, nor did I need it's power consumption, so I decided to use an AtTiny85 as the "brains" behind this project. Alternatively, you can use the AtTiny45 for this project as well (which is cheaper)
In order to program the "brains" you will need an:
I have included the sketch that I used for the project with this step. In order to program it to the AtTiny, follow these steps:
For more information about program the AtTiny, consult the following tutorial.
Additionally, you will need to pair the HC-05 to the Bluetooth Receiver before you solder the circuit! Meaning, you will need to build the receiver first, then pair, then build this circuit. Here's a very easy tutorial on how to paid two HC-05 modules together.
The next step is to open up the Nunchuck and make space for the electronics. I did so with the help of a dremel, by grinding the circuit-board off near the screw holes, and making a little hole in the back where the switch will be. I also got rid of some of the supports inside the Nunchuck, as I needed extra space for the electronics.
Now is also a good time to locate the connections to the potentiometer and buttons. Use the diagram above to identify the respective pads, and solder some thin, 5-10cm long wire to each pad. This will help with the other steps.
Now it's time to build the circuit! Here is the parts list:
I used the "dead-bug" soldering technique to solder all of the components according to the schematic above. The connections to the Nunchuck are right above the AtTiny85, and they go:
Lower Button - Upper Button - Ground - Potentiometer Output - VCC
from left to right... You can also follow the schematic fully, and put in a programming header and a UART header (for testing the output to the HC05 module. I only put in the programming header, and that allowed me to upgrade the software in the future.
In order to power the circuit that was made in the previous step, it is necessary to make a lithium-ion charging/power circuit. The materials you will need for the power circuit include a:
Lipo Protection Circuit (1S)
The circuit we built in the previous step can take anywhere from 3.6v to 6v, so a Li-Po cell is the best and easiest way to provide power to it. Build the circuit above using some thin, flexible, stranded wire. Flipping the switch will turn on the Nunchuck!
Now it's time to put everything together! The fit might be a bit tight, but the basic premise is to get everything into the Nunchuck without breaking anything. I used tape to temporarily hold everything together, and then I used hot glue when I was satisfied with the fit. The end of the nunchuck (where the USB port is) was hot glued shut, which required pouring layers of hot glue and waiting for them to dry.
This Bluetooth Nunchuck is compatible with my Prototype Smartphone Controller for electric skateboards. If you build this project correctly, the Nunchuck will automatically pair with your electric skateboard! If you are paired with the skateboard, you will need to turn off the Nunchuck before you can connect with your smartphone.
Since then, I have updated the schematic and the software behind the controller. I have included the Eagle CAD files, the software, and everything you will need to build the my newest version in this step!
If you have any questions, please ask in the comments! My next instructable will be about my carbon-fiber electric skateboard, and then next one after that will be a full-on, cheap, Boosted Board knockoff! Stay tuned!
Also, if you would like to support me by buying one of these pre-made controllers, you can do so here. Thanks!