backstory conversation with Frits
Hello Frits,
I am adapting your code to the Arduino. So far I have most of the elements working. However, I can not figure out how the SHFL variable is returned to 0. I can see that the shuffle delay only happens when SHFL =0, but SHFL is incremented by one (SHFL = SHFL+1) before the “if” statement. And I can not find out how SHFL returns to 0 or possibly a negative number.
I am amazed by your robot and your ideas for drumming. I am using solenoids to move the sticks. I would love to share some photos of my robot if you are interested.
Cheers
Charles
Hey Charles,
Fantastic :)
Charles question first: The variable “SHFL” is a single bit. And so, if you increase it more than the value 1, you overflow it, and it turns zero. Ugly coding is my middle name
I am a self-taught robot builder. Here are some of the projects I have done:
This is a BEAM circuit. I used the little Solarbotics pager geared motors and took off the spring and cut the piece that prevented full rotation:
http://www.youtube.com/watch?v=gxeHcueqj0c
This is a Halloween costume I created using servos and an Arduino:
http://www.youtube.com/watch?v=FE9nvD7tDS4&context=C4537180ADvjVQa1PpcFMQLtfRVvdRcO4esk4_uLET1jo6deSk2uQ=
And a biped I scratch built:
http://www.youtube.com/watch?v=P_2QIr0ir0c&feature=context&context=C4537180ADvjVQa1PpcFMQLtfRVvdRcO4esk4_uLET1jo6deSk2uQ=
And an 8 legged walker:
http://www.youtube.com/watch?v=RRCJKMY2TKA&feature=context&context=C4537180ADvjVQa1PpcFMQLtfRVvdRcO4esk4_uLET1jo6deSk2uQ=
I just uploaded a video of my Drum Machine to YouTube: http://youtu.be/PDIl2oeA2FE
I still need to add the sound recorder/playback and complete the code, but all of the components are working.
I also have this page with some photos of my early robots. I have been neglectful of adding new information. I am currently also working on a robot that uses a netbook and a vision system to identify a colored object and drive up to and touch it. It uses a compass for navigation. It also uses a sound board to speak.
I just re-worked a hexapod that I scratch built and hacked an old Nintendo Power Glove as a controller. It uses xbee units to communicate. The hexapod has five different gaits all based on insect walking motions.
I am sure that my code is pretty funky. I took a couple of simple BASIC programming classes back in the early 1980s. However, I can get most things to work the way I want them to.
I recently had an article published in SERVO magazine about using a horse syringe and a balloon and coffee grounds to make a “universal gripper.” You can read some of the article here:
http://servo.texterity.com/servo/201201/?folio=44#pg44
I think that’s about it. I am very interested in working with you two on the drum machine; it sounds like fun.
You have made 3 “milestones” in my book - so I know you are good:
A) Conversion to Arduino. Only one other person (TheCowGod) have I
seen do this (Though I think he just wrote his own code)
B) Fixed the Pager-moter-issue; These are extremely costly. Solenoids
sounds cheaper!! (Though a lot of cobber and funky magnetic
pulse-stuff)
C) Your robot is actually funky!
I have a been compressing my video into 15 fps. But here’s a full quality version of my little drummer so far:
http://www.youtube.com/watch?v=nYlqiqa5VEw&feature=youtu.be
Let’s keep in contact.
Cheers
+++++++++++++++++++++++++++++++++++++++++++++++++
Wehee!! Thanks! I think you want the sticks to be approx 60% of the
current length. Much faster, more precise.
Cheers,
Frits
So Sad! They look so cool long. But I will try what you suggest. It will probably improve the drumming! Thanks
You know, I’ve never registered at Let’s Make Robots. I guess it’s time. I was thinking of creating an Instructable detailing the steps.
I finally found some time to transfer all of the song data. Now I have to code the control structure to select songs to play. It looks like that the aaaa: and other areas choose which song to play. They use a “random” number, but it looks like the number is just incremented in a different part of the code. So that aaaa: plays song 1 then the next time song 2 and so on till it is reset back to the first song.
Would it work just to have a totally random song selected? Or it could make sure that it didn’t repeat a song it just played but select a different song. Would that work with your plan? Does it matter?
Cheers
Charles
I wrote this code in many versions. But I think I always worked from this principle: although the result in reality is random: first the robot is “getting inspired” from the surroundings, and then it plays.
Other versions did more for this, but they had other downsides. Challenge is always memory, which I like, it keeps a virtual border around creativity.
As I remember it, the version you have is more or less a random remix of some tracks, so if you have no feeling for the principle of the robot “being inspired”, just make it random.
I am thinking of adding a CDS photocell sensor to the robot. That way I could use that data to have it choose which songs to play, based on the amount of light in the area.
************************************************************************