Posts Tagged ‘LEDs’

R.I.P. Workshop – Final Day

Posted by Erin, the RobotGrrl on Friday, July 15th, 2011

Today was the final day of building everything before all of our supplies and junk goes away. I can’t believe it is almost the end, and the robot has become very built over the past few days, but it still is not exactly how I want it.

I started off by doing some wiring! Found some yellow LEDs for the eyes, and Niklas is lending me his IR sensor!

Here is how the robot face looks with the LEDs and sensor on it. Its antennas are ends of serial cables!

The LEDs are mounted through the back of the face plate:

Sometime before making the arms, I sent a tweet out for name suggestions. @Kiteaton had a wonderful suggestion- “SCRUMBLEFLIT”, and it just sounds so perfect for this robot. It sounds like “what on earth is going on!” in robot language.

Here are the arms mounted on the stepper motors thanks to much hot glue!

The hand is made out of copper wire, with lots of solder, and the keys say “ROBOT”!

Inside of this can there are screws, to try to make noise. I chose Orange C plus for this because it is tasty and sounds like the programming language, C++.

Took some time to visit the place where I will be showing off SCRUMBLEFLIT, the town hall! It is a pretty decent town hall!

Afterwards I went back and worked with the LEDs for a bit. They are interesting because they cast light along the edge of the circle in the doorknob.

I created a blink that seems believable. I do it by quickly (but not too quickly) fading the LEDs to a low light, to signify the eyelid closing, then it jumps back to bright light, to signify the eye open. Blinking on robots is tricky, because if you don’t do it properly, it looks like as if it is glitching out.

After this, I was working on the arms again. Everything was going fine, the arms were moving, then everything stopped. The power supply wasn’t on anymore. As Niklas later taught me, what might have happened is an exposed wire might have touched the outside casing of the supply, making it go into shutdown mode. Apparently power supplies are really dangerous and can explode a lot. Hopefully it doesn’t make SCRUMBLEFLIT explode!

Anyway, I sort of got it working again a little while later, but the problem now is that it takes ages for the stepper motors to “warm up”. What happens is that everything is plugged in and working, but the steppers aren’t moving. However, if I take the power out of the steppers and plug it back in, you can hear and see it react to the voltage, but it doesn’t keep moving. This has happened before in the previous days, still unsure about what is causing it though. It usually goes away by itself, but when it doesn’t, it is really annoying.

We will see what happens tomorrow. I have to wake up early and move my robot from one place to another since it is in the studio right now, so hopefully it isn’t raining then! Tomorrow will have a lot of explaining about what the robot COULD have done and what it SHOULD do. I enjoy talking about robotics nevertheless though. :)

Everyone’s projects are absolutely stunning! We created so much in a short amount of time, with unplanned materials. Creativity has some amazing super powers!

Here is a video of the robot’s eyes blinking!

Posted in: R.I.P. Banff.

Breaking and Fixing

Posted by Erin, the RobotGrrl on Wednesday, November 10th, 2010

How do you know what is going to break, and at what time? Robotics is full of detailed hardware and software implementations where if one thing breaks, it can cause many other things to not work as well. Being a ninja in preparedness can go a long way, but what can be expected in demo-ing robots?

At the Ottawa Mini Maker Faire, one of the first perf-board circuits that I designed, for MANOI’s hockey stick, got a short circuit and didn’t work. Granted, the circuit wasn’t the best designed, I recall that I went for an “artsy” approach by making it three dimensional. Also, the LEDs were in series, so once one of them burnt up, the other ones didn’t work.

IMG_0114

I guess you can expect old things to break eventually. But what about new things?

The force sensitive resistor on MANOI’s wrist snapped and tore the conductive plastic. This was due to the motion that MANOI was undergoing. But why didn’t it break the other times MANOI did the motion? Also, why didn’t it just pop out of its header socket, like it was designed to?

IMG_0108

Here is the fixed version of the perf board that I did in many hours. It looks much more neater and “one dimensional”.

IMG_0127

As for the force sensitive resistor, I’m probably going to make a capacitive sensor or a sensor using conductive foam and felt. That way everything will be more flexible.

To sum up, I think this is an answer that we’re always chasing in robotics: How do we prepare for the things that can break? One way is with simulation, avoiding the dangerous environments for robots in the real world. Or maybe we could have robots that test robots. That would be pretty cool. Either way, it’s something to think about for the future, especially when we can have serious implications of such events happening, with UAVs and rovers.

Posted in: Other, Projects.

Friday Night Robotics – MusicBox!

Posted by Erin, the RobotGrrl on Sunday, October 11th, 2009

This Friday I had the most awesome idea of a weekend project ever! A 21st century MusicBox, using an Arduino and have blinking LEDs!

I had a Sparkfun box lying around, which is an ideal size for an Arduino and a WaveShield.

Friday Night Robotics - MusicBox!

I wanted to have LEDs outlining the box, so I went to work on it:

Friday Night Robotics - MusicBox!

Friday Night Robotics - MusicBox!

Just as a disclaimer- I designed it wrong, so the LEDs don’t work well. If you’re looking to follow my steps, DON’T DO IT! :P

Friday Night Robotics - MusicBox!

Friday Night Robotics - MusicBox!

Then, installing them into the box:

Friday Night Robotics - MusicBox!

It looks nice!

Friday Night Robotics - MusicBox!

Once all of the connections are made, it’s pretty tight in there:

Friday Night Robotics - MusicBox!

The problem though, is that I designed it so that all the LEDs are in series. Since al LEDs aren’t created equally, some suck up more power and therefore can’t share it with the others. This is what happened:

Friday Night Robotics - MusicBox!

It’s pretty sad! :( But, I think that I can fix it because I soldered the resistors together, not the actual LEDs together. :D I was too excited to start this project, so I didn’t bother to plan =) I guess planning would have been better, but it would also have been too boring.

I also worked on a NXT LED blinky thingy. There are these HiTechnic Protoboards that you can get, and basically you attach them to one of the sensor inputs, and you can control power to certain ports and such.

In this case, there’s 6 output pins that you can control. Sounds like an opportunity to use LEDs to me! :D

NXT + LEDs

This is what the setup looks like:

NXT + LEDs

It goes like this: NXT -> HiTechnic ProtoBoard Sensor Adapter -> 6 LEDs

In order to output instructions to the HiTechnic ProtoBoard, you need ‘drivers’, or headers. They’re located here.

Here is the code for the LEDs, in RobotC:

  1. #pragma config(Sensor, S1,     HTPB,                sensorI2CCustom9V)
  2. //*!!Code automatically generated by ‘ROBOTC’ configuration wizard               !!*//
  3.  
  4. /*
  5.   Crazy LEDs!
  6.   Erin K
  7.   Oct. 9th, 2009
  8. */
  9.  
  10. #include "drivers/common.h"
  11. #include "drivers/HTPB-driver.h"
  12.  
  13. byte theLEDs[] = { 0×01, 0×02, 0×04, 0×08, 0×10, 0×20 };
  14.  
  15. task main() {
  16.  
  17.   // Setup all the digital IO ports as outputs (0xFF)
  18.   if (!HTPBsetupIO(HTPB, 0xFF)) StopAllTasks();
  19.   wait1Msec(200);
  20.  
  21.   while(true) {
  22.  
  23.     // The delay time
  24.     int theTime = 50;
  25.  
  26.     // LEDs going up
  27.     for(int i=0; i<6; i++) {
  28.       if (!HTPBwriteIO(HTPB, theLEDs[i])) nxtDisplayTextLine(5, "ERR WRITE");
  29.       wait1Msec(theTime);
  30.     }
  31.  
  32.     // LEDs going down
  33.     for(int i=5; i>=0; i) {
  34.       if (!HTPBwriteIO(HTPB, theLEDs[i])) nxtDisplayTextLine(5, "ERR WRITE");
  35.       wait1Msec(theTime);
  36.     }
  37.  
  38.     alive();
  39.  
  40.   }
  41.  
  42. }

This is what the code does:

To wrap up this Friday Night Robotics, I checked out the Adafruit Ask an Engineer chat. It was pretty cool! I learnt about how LEDs work, and how much it costs to create a Teenyduino! Everyone should check it out, Saturday at 10:00PM EST.

The only things that I didn’t get to do that I wanted to was play with MANOI and the iRobot Create. I’m kinda worried that MANOI’s batteries are drying out as they haven’t been exercised in a while :S EEP!

Posted in: Art, Programming, Projects, Robot.

Fading LEDs – Circuit & Arduino Way

Posted by Erin, the RobotGrrl on Monday, September 7th, 2009

Someone recently commented on one of the posts and asked:

Hey Erin, I was just checking around looking for help with a project Im doing. Im not an expert by any means ,I could really use the help and expertise of somone like you. I like your robot too.
Im building a Terniator endo Bust. Its Recast vinyl kit. My …dilemma is ,…The kit came with 2 Red LEDs for the eyes,a bouble A battery pack and a switch. I want to mod this guy so the lights come on slowly,and when switched off they dim out.(3-5 sec.)
The second effect I want is to install a pulsing or vibrating motor inside the scull that comes on momentarily with the lights?
I have other Ideas too. If I can interest you ,Id be will to pay for your help.
I hope this sounds interesting to you, Thanks ,Daniel Shaffer

Sounds like a great weekend project!

There are two ways to solve this problem: with a circuit, or with a microcontroller.

I can’t exactly help out with the mathematical part of the circuit, but in order to obtain the dimming effects, you would need to first charge a capacitor up when you switch it on, that would be connected to the LEDs. As more and more voltage fills up into the capacitor, the LEDs will make a fade-in effect! When you switch off, the capacitor will have to de-charge (perhaps into a different capacitor). When it is emptying, the voltage will be going lower and lower, making a fade-out effect.

The second part of your question, how to make a vibrating motor come on with the lights… you would have to use a 555 timer IC. These also use capacitors and resistors in order to create a timed circuit. They are a really interesting concept, and I would encourage you to check out these sites about them! :D

Now… if you wanted to use a more extendable option with a microcontroller, that is more easier! I made a post about how to fade many LEDs here, with an Arduino. You could have the LEDs fading in and out while having the motor turning on/off. AND, you could use sensors to create specific behaviours and triggers for the Terniator.

I hope this answers your question, and I hope you will keep us posted on the status of your project! Woohoo for blinking LEDs!

Posted in: Other, Programming, Projects.

Friday Night Robotics – Plain Vanilla

Posted by Erin, the RobotGrrl on Sunday, January 18th, 2009

At first, the title of this post was “Mediocre at Best”, but after I typed it all up, I realized that I did do stuff that makes it a little bit better than mediocre! So, I switched it to “Plain Vanilla”. There really isn’t much stuff to do when I don’t have MANOI around!

I started a new project thingy where it is an extremely simple game of pong. The paddles are stationary, but the trick is that one paddle would be controlled by the computer (in this case- an Arduino), and the other would be controlled by the human with a Wii Nunchuck.

IMG_5122

The paddles are represented by tiny pink LEDs, and the ball is represented by the LEDs in between them.

There is one LED at the top that is used to signal the start of a new game, and/or a goal.

LEDs from top

Since the human player would be using a nunchuck, it would sort of be like Dance-Dance-Revolution where you would have to tilt it a particular way to have the paddle show up. For this, I’m going to use BubbleBoy’s LCD screen:

IMG_5123

It will also be able to display the score! ^_^

I got a little bored of doing this due to numerous conflicting errors when I compiled the code, so I switched to my snowplow robot.

I remember having trouble trying to get the two motors to move with this one, so my main goal was to debug it. It turns out that one of the tab thingys on the DC motor was loose!

I had to snap the robot in half in order to transport it, so now the snowplow is waaay too top heavy =) It’s kind of funny!

Snowplow Bot

I really can’t wait to get my Femsapien that I won from the Robots Podcast contest. I’ll play around with it a bit, then I will hack it and put an Arduino in it! One of the things I really want to do is to try making it Twitter. Since I don’t have an ethernet shield, I would probably have the robot (Arduino) send a variable to Processing, which would then twitter, probably using something like this.

Posted in: Programming, Projects, Robot.

Hockey MANOI – a summary

Posted by Erin, the RobotGrrl on Saturday, January 3rd, 2009

I made a pretty good summary of Hockey MANOI in this thread at Trossen Robotics forum. I figured I should post it on my blog because it is a good summary :D and I broke it down into easy to read parts, so it’s like a whole JOURNEY of awesome!

Hello TRC World! :D

My project is a hockey playing humanoid.

It uses a MANOI AT01 kit, controlled by an Arduino (with an ATmega328) with a Wave Shield, and a SSC-32.

Humanoids have always been associated with walking or running. This project focuses on a different action for humanoids, skating. The end result of this project yields an interesting vision of the possibilities of skating robots.

Introduction

The idea came around when I was trying to make my humanoid (MANOI AT01) walk. Instead of taking a “big bite”, I decided to take a smaller bite and make it slide its feet. However, I quickly realized that when it slides its feet, it looks exactly like a newbie Canadian hockey player!

A Canadian newbie hockey player begins to skate by almost walking. Although the skater doesn’t go far, he does move forward due to the friction between the blade of the skate and the ice.

When I did notice this, I quickly grabbed some lego to create MANOI’s own version of skates, which are similar to rollerskates. I mounted the lego onto the feet using velcro.

The hockey stick I just found laying around. I had to cut a bit of it off, as it was too tall. I use tape and tie wraps to keep it mounted to MANOI.

Development

Development on this project was mainly trial and error. To get all of the motions correct so they all balance together was critical.

Instead of using the controller board that is usually used to control the MANOI, I did a major transplant and substituted it for the Arduino and SSC-32. This allows me to have much more flexibility in terms of sensing and creating motions. The H2H software was too problematic.

Usually what would happen is I would draw out a motion, on paper, that I would want to create, and I would put it into MANOI. Sometimes I got it first try, other times I didn’t. However, the cool part is that a lot of the motions stemmed from the ideas of other motions.

For instance, in the video of MANOI Skating with music (seen below), the motion where MANOI is running is actually a faster version of the sway motion! That was really surprising.

The development for the Wii nunchuck part of the code was quite easy as I had already established all of the variables and settings of when the nunchuck is tilted left or right, forwards or backwards. Instead of using real numbers for it though, I just defined a “home position” of the nunchuck, and subtracted or added numbers to the accelerometer axis, x y and z.

The music part of the wave shield was quite fun and straight forward. I looked around for the songs, and put them on a SD card which plugs into the wave shield. From there, it was just a simple method call inside of the Arduino.

Once the above developments were done, I wanted to create a version of MANOI that could sense if a ball/puck/object was there. I did this by using LDRs and LEDs.

Rest assured, I would have used IR Sensors if I had any ;) This was the best alternative I had, though!

On the left side of the sticks the LEDs are in a yellow casing, and on the right side they are in a clear casing. There is some effect on the reading, however their values change precisely the same when an object is in front of the stick.

The black construction paper enclosure around the LDRs was required to direct the reading. Otherwise, the light from the LEDs saturated the reading and no difference was seen when an object was present or not.

I observed the change between the readings of when there was an object present, and when there was not an object present.

From this, I created a simple neuron, where if the input values succeed a predefined threshold, it will perform an action. In this case, the action would be to shoot the object.

I had to tweak the threshold a little to make it work with smaller objects, such as a roll of electrical tape.

In the video below, you will observe that it does work with a roll of electrical tape, a ball, and a spool of lead solder (the LEAD solder isn’t mine, it’s my DAD’s because he can’t use non-lead solder like the rest of us -_-;). The spool is white, which proves that the theory does work, meaning that the light that is reflected from the LEDs back into the same LDR board does not obscure the readings.

Results

Here are the videos that you can look at!

This is the first video, where I was just getting the motions down.

The program is basically a sequence of movements:

- Forward 6 times
- Shoot 3 times
- Backward 6 times
- Shoot 3 times

As you can see, the forward and backward movements both result in MANOI moving backwards. As I later found out, through trial and error, it was due to the Arduino and power cords limiting the movement of MANOI! Once they were mounted properly, it worked much better.

This is the second video, where MANOI is controlled by the Wii nunchuck!

You press Z to shoot, and you hold C and tilt to move it. :D MANOI can move forwards, backwards, left, right, and home.

This is there third video, where MANOI is playing a little game of hockey by himself while listening to some music. The song that you first hear is the Hockey Night in Canada theme song!

This is the last video, where MANOI can autonomously decide if he should shoot or not.

(The quality in that video is quite yucky, please check out the video on [URL="http://vimeo.com/2641041?pg=embed&sec=2641041"]vimeo[/URL] if you’d like to see it in better quality)

Conclusion

In conclusion, this project was SO much fun! The only time I didn’t enjoy it was when I was trying to hold MANOI, who was whacking me with its stick, with one hand and trying to type in some code with my other hand.

My favourite part was watching people play with the Wii version of the code. They really enjoyed it!

I also liked making the AI part too, that was pretty fun.

Next Steps

The next steps would include coding a modified version of the Bayes filter algorithm to predict if an object is in front of the stick or not.

More sensors would be fun, like three proximity sensors mounted on the front, left and right. This way MANOI could avoid opponents trying to take the ball off of it.

I would also add two more servos in the leg that would allow rotation. This would then allow me to create a more realistic skating humanoid, where there would actually be a stride.

Perhaps I could also add a camera to the head so that it could track where the ball/puck/object is.

That’s my project, I hope you like it! ^_^
You can see more of everything I mentioned at robotgrrl.com

Posted in: MANOI, Programming, Projects, Robot.

Friday Night Robotics

Posted by Erin, the RobotGrrl on Friday, December 26th, 2008

Merry Christmas and Happy Holidays to everyone!
Best of all… it’s ROCK EM SOCK EM ROBOTS DAY! (Boxing Day)

Just as a fair warning, if this entry has more bizarre grammar mess-ups than usual, it’s because I ate too many jelly beans, and all I can think of is jelly beans! Robot jelly beans, jelly bean slushie, a meadow of jelly beans, jelly bean snow… *goes on and on* I think in pictures… and all I can think of right now is a DANCING JELLY BEAN ROBOT! Hahaha, joking. (Or am I?) ^_^

I hardly realized it was Friday today, so it doesn’t really feel like a FNR.

Last Friday, although I didn’t blog it, I was working on the LEDs that you’ll see on the stick, and the program! This Friday I tested and twirked the program so I can blog it.

Here is MANOI!

MANOI Hockey AI

Do you notice something different about the stick?

MANOI Hockey AI

The stick now has two perf boards on it! These perf boards have three yellow LEDs surrounding a LDR which has black construction paper around it.

MANOI Hockey AI

MANOI Hockey AI

The reason why I chose these yellow LEDs was nothing scientific. These were the only ones I had where I could have some consistency across the two boards. The LEDs on the left are inside of a yellow casing. The ones on the right are in a clear casing. There is a little bit of a difference in the readings of the LDRs, but they both work the same.

I would have really liked to do a different version of this but with an IR sensor and a FSR, but, as I mentioned above, these were the only things I had, and they will for sure get the job done!

What happens is the LDRs “spit out” a reading of the amount of light around it. I use the cardboard to ensure it is directed at what we want to be observing. When there is no object between the two LDRs, the reading is very high. Yet, when there is an object between the two, the reading drops a fair amount. This is because the LDR cannot sense the light from the opposite LEDs. I also tested this with a fairly white object (my DAD’s lead solder spool (eeew lead)) and it does work, meaning the reflected light from the LEDs back into the LDR (on the same board) does not obscure it. You can see for yourself in the video below. :)

I tinkered with the LDRs’ amount that it to create a threshold that will trigger MANOI’s shot. From what I learned at Stanford, this is simply called a neuron. It has input values, and if they meet a certain threshold,it will do something. This is a very primitive form of AI, but big things come in simple steps. =)

Here is a video of MANOI action! Pretend that the roll of tape is a hockey puck… it almost looks the same!


MANOI Hockey Robot AI from RobotGrrl on Vimeo.

It is also on youtube, here.

At the beginning, you see the LEDs flash. This means that the Arduino is soon going to evaluate the LDR levels. It takes five samples from each LDR, one every 500 ms. It then makes an average, which is the baseline used for comparing the LDR value against the threshold.

Yes, I agree, that this can completely become messed up. I will probably implement a markov approach to create (and update) the baseline. However, I’ll probably only do that after I make a modified Bayes algorithm for the AI. :)

You might have noticed something different about MANOI’s other hand. I’m giving it a gripping claw so that it can grip stuff. It won’t be meant to hold on to anything precious, but it could emphasize an effect here or there.

MANOI Hockey AI

While I was adding on the boards, there was just not enough room for all of the stuff that I needed… like +5V and -Gnd. I made a thing with headers and inverted headers so I can easily plug it in!

MANOI Hockey AI

It saves much needed space on the wave shield:

MANOI Hockey AI

Just to add, today I was using an Arduino with an ATmega328. :)

There are more pictures that you can look at in this photoset on Flickr!

This project is almost finished! I just will add in an algorithm improving the AI, make more videos… and that’s it! I will continue the project later on, though with a few more things. I’ll add servos that can rotate the leg so I can make the robot actually skate, and many more things that I am still thinking of. :P

Can you believe that the Trossen Robotics robot contest deadline is really soon? Yikes!! :P
I just have to take a few more videos and work out what I will say in my post… what do you think the judges will be looking for? Hopefully it won’t end up like BubbleBoy in crabfu’s competition… x_x

Though, when crabfu was on Daily Planet (I actually saw it on TV (like two months before all of the robot websites started to go crazy over it), not on youtube) he described his robots as having character because you can interact with them through a control pad.

I think that is completely opposite, because then it is just the human expressing their character through a machine. When you don’t have to use a remote, yet the robot still interacts with its environment, that’s when a robot truly has character. :d

Now we know why BubbleBoy obviously lost… He can have his definition, and I’ll have mine. :) His works are very interesting though! I never knew you had to start a fire to make a steam thingy move. I figured you would just boil water or something… hahahaha :D (I never thought as far as you would need fire to make water boil, though… EPIC NOT-WIN!) XD

I hope you really enjoyed this blog post. It makes a lot more sense now that one can see what the finished robot will look like!

Posted in: MANOI, Projects, Robot.