Posts Tagged ‘Lego’

Finishing the RoboGlyphs Project

Posted by Erin, the RobotGrrl on Saturday, June 12th, 2010

Just the fun stuff was left for this project! Here is a photo blog montage of the journey to the finish :D

The first thing to do was to put the black foam backing onto the RoboGlyph. I wasn’t really sure how the glue would look, so I placed a minimal amount on the corners. Next time I do this, I’m going to put glue all over the back since it created a neat effect with the sparkles on the foam. It sort of makes them more sparkly… :)

IMG_7701

Cut the excess foam away with the Xacto knife. Cutting it on a slight inwards angle towards the glyph is much better than a 90 degree cut, I found.

IMG_7703

To mount the RoboGlyphs to their board, I used toothpicks on the back. This is what it looks like from the front:

IMG_7704

Zoomed in:

IMG_7707

The toothpicks fit nicely in the holes of the perf board. I found that if you put glue in the perfboard hole, then put the toothpick in, it will stick better.

IMG_7709

They’re all tilted forward because they don’t have a proper footing yet! =)

IMG_7714

Again, from the back:

IMG_7724

At first I was thinking about using some rubber feet to keep the RoboGlyphs standing, but I didn’t have any on hand. The next best thing: Lego! Plus, there is something else that I can add on to the Lego to make it even more interesting… :)

IMG_7729

The “more interesting” part would be tinfoil! Tinfoil is a conductor, and therefore can have a charge running through it.

IMG_7733

It’s quite a difficult task to manage to put the tinfoil onto the Lego bricks. This try was using hot glue. When another brick is placed on this one, the tinfoil splits.

IMG_7735

I tried using a simple glue stick, and it actually works much better! The tinfoil does not split when another brick is placed on top of it.

IMG_7753

Putting tinfoil inside the brick is much easier. :D

IMG_7776

While the glue is setting for the tinfoil, it’s time to wire up the RoboGlyphs. Thanks to the super simple colour coded wires, the process took a matter of seconds. The Sanguino only has 6 PWM pins, and there are no PWM drivers in my pocket, so the green LEDs will not be controlled by PWM.

IMG_7783

Green is probably the best default colour!

IMG_7787

Red:

IMG_7790

Blue:

IMG_7792

The edge lighting is really cool, even though I didn’t really do it very precisely. You can’t really tell from this photograph, though.

IMG_7803

The Lego 2x4s were glued on to the bottom of the boards. Then they’re placed onto the tinfoil-coated Lego brick. 5V is applied through an alligator clip!

IMG_7808

The other end goes into an Analog In, where the Sanguino checks to see if there’s anything there. If nothing is there… The lights don’t turn on! :D

IMG_7815

There’s a few finishing touches that I have to make. I’d like to connect it to Twitter via Processing, and have it as a permanent setup. I also have to fix the Lego connections, as right now it can only tell if the middle RoboGlyph is disconnected! =)

Posted in: Art, 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.