• About
  • Projects & Research
  • Publications
  • Archives
  • Categories
  • Posts Tagged ‘LilyPad’

    Learning from Projects


    2009 - 12.05

    My department encourages undergraduates to do research beginning in their freshman year. I get the impression that many schools limit this to a senior design project, which is rather saddening.

    I’ve stopped reading my CS text books because, well, they’re just not helpful. But then, trying to learn anything more unusual like how to use the tools available is still very difficult. So, I’m just going to do a quick overview of what I’ve learned from using different tool sets.

    LilyPad

    So, the LilyPad series of embedded systems modules is designed for wearable computing. So, the best place to start learning about the LilyPad stuff is from the creator, Leah Buechley. Things to keep in mind:

    • I never needed to create a pad for my units to prevent slippage. But, you’re millage may very.
    • Pins (rather petals) of the LilyPad Arduino are dictated by an int (integer) value.
      • 13 is reserved for the LED that exists on the LilyPad Arduino.
      • RX/TX are for serial connections (see XBee below)
      • Analog (denoted by “a” on the petal) pins retain the same numbering scheme as the digital ones(so there’s an analog and digital pin 0, which are both labeled “0.”)
    • Buttons should be set up connected to two digital pins. One should be written to be HIGH while the other is written to LOW. Then, just do something whenever the HIGH pin reads as LOW. (This is contrary to the standard debounce that is done with buttons.)
    • Do not EVER cross conductive thread lines or allow them to touch one another. This will destroy one or more modules.

    I have used all of the LilyPad modules available. Except for the slide switch it’s pretty much “find the closest example and repeat” (if anyone knows how to use the slide switch, I’d like to know).

    XBee

    Based on the ZigBee standard, XBees are designed for WPAN. Indoors, they are restricted to within a room, but can be separated by miles outdoors.

    This forum post is probably the easiest I’ve seen in getting started. Things to also consider:

    • RX connections go to TX and vice-versa. Weird, counterintuitive, but that’s how it goes.
    • With a firmware update, it’s possible to have the XBee use actuators. This isn’t direct control, more like if one XBee has a pin go HIGH, the XBee it talks to will also have that pin go HIGH.

    Personally, I found it a lot easier just to use the XBees for communication and an Arduino for the actual sensor data and actuator control.

    Trackmate

    Trackmate is a computer vision based tangible object system. From a user standpoint, it’s pretty easy to control: cut out some inch-square icons, tape them on to objects, and use the interface.

    From a programming standpoint, not so much.

    • I recommend the Minim Processing library for any audio work. Seriously, don’t even bother trying to do this from scratch.
    • The code itself, when I last looked at it, was very hardcoded, so don’t expect to change the behavior of the system unless wanting to write it from scratch.
    • Review Processing. While it is derived from Java, it leaves some more advanced things out.
    • Review matrix algebra and vectors. While you won’t be doing math directly, it will help to make sense of some of the values.
    • I did the initial setup using the PlayStation Eye camera as recommended. While I could use the camera’s drivers and operate it from outside Trackmate, it didn’t work with Trackmate (looked like snow). Don’t know why, but it just wouldn’t work for me.

    Combining Projects


    2009 - 10.25

    As I’ve stated before, I need to create one embedded systems and one artificial intelligence project this semester.

    From both professors, I have gotten the impression that the project is intended to demonstrate that I learned something. So, rather than worry about the scale, I’ve decided to combine the two projects into a super-project.

    Not to say it won’t still be quality work. I just as soon do both together than to risk doing one project poorly.

    So, what will I be doing?

    1. Embedding a camera, RGB LED, LilyPad Arduino, a mode switch, and an xBee onto a canvas.
    2. Connecting an xBee to my netbook, Spinnel.
    3. Creating a touch and look modes.
    4. Having Spinnel react to the actions.

    The touch mode will use conductive thread embroidered into the canvas. When the user touches it, the node will activate and do a specific task.

    In look mode, the camera will take pictures.  These photos will be sent to Spinnel for processing. Using OpenCV library, a series of movements will be interpreted as a gesture and the system will activate an event based on this action.

    So, why can I combine these projects? Well, a lot of it comes down to the size of the project. In A.I. many people are doing something that could be done in a couple weeks, like programming a game-playing algorithm. Because I’ve decided on a more advanced topic, I get a lot more flexibility in how and with what tools I approach it with.

    Now, it’s just a matter of getting the time to do it.