NXT Trombone (ME-84: Assignment 2)
|From ME-84: Introduction to Robotics|
It took one afternoon to build the first version of my trombone. The idea is that the notes depend on the position of the slider, and are produced when you blow into the sound sensor mouth piece. I had originally wanted to make it look more like a real trombone, but thought it more important to see what could be done with a single Edu kit. The ultrasound sensor can be a little flakey, so I knew the slider would have to be long enough to spread out the eight or so positions required. In the end, I was reasonably happy with the performance of the ultrasound sensor (it performed better than I did!). I also wanted to use a formula to generate the correct note based on the ultrasound sensor reading, but I didn't know how to do a x^y calculation on the NXT at the time. In the end I found the hidden vi that maps notes to frequencies, and used that inside a case statement. At home, I asked my boys (who play piano), if they knew any songs that I would be able to play on the trumpet, and they taught me "Ode to Joy". I also learned how to dynamically control the length of the notes being played, using anotherPlay Note (no wait) and a Stop Note block.
Automated Swing (EN-10: Assignment 2)
|From EN-10: Simple Robotics|
Following some gentle encouragement from my wife, I made the robot look more like a swing seat. I'm pretty happy with how the NXT brick functions as seat, and it helps with the story of this robot as being a model of an "assistive device".
By estimating the period of the swing based on the length of the swing, and then doing some tweaking on top of that, I was able to come up with a motion that worked fairly well. The swing could start from rest and work up to a decent swing motion. The following video shows the robot in full swing (it had been started from rest)...
Of course, it would be much more impressive if the robot "knew" when to swing the legs based on the position of the swing. As a result I spent most of the following week trying to make use of a HiTechnic Accelerometer sensor to time the swing.
In the end, I gave up because of signal/noise issues. Between the vibrations naturally in the swinging and the extra acceleration caused by the motors, it proved to difficult for me (at this time) to solve the timing problem. I would however like to come back to this one when I know a bit more about filtering...