Friday, October 10, 2014

Parallax Scribbler and S2 GUI Programming Fun

My friend, Ken Gracey, at Parallax is teaching a  course in Iowa for 45 teachers who will be learning the S2 robot for their elementary school programs. He posted the announcement on the Parallax Forums here and  said, "The S2 GUI provides a whole semester's worth of projects, but what gets teachers and students really excited is when the robots interact with one another...I know there's more we can do, using the GUI and the sensors on the S2. Can you give me some more ideas about how we can make the S2s communicate with one another - strictly from GUI programming activities."

So here are a couple of ideas that I came up with.

Number One - Here is a demo with two programs written in the GUI (that means they will run on the Original Scribbler and S2, of course). Old blue is programmed to count in binary numbers up to 7 (with 3 LED indicators we have 0 - 7 - 1s column, 2s column and 4s column - On is 1 and Off is 0). See graphics below.

The S2 (because of its encoders and ability to stay on course) is programmed to run 7 circles (can be simply reset to some other number up to 7 in the loop counter). As it passes by, old blue will count as it passes, using the IR detectors.

See the following demo video...

Number Two - Variation on the theme above. Should be easy for your teachers to figure out and students will love it because it resembles a magic trick - "Fire Stealer"

The sneaky S2 sings Charge!, runs erco's figure 8 and "steals" LED light - "fire" - from Scribbler A and drops it off at Scribbler B. When all the light is stolen from Blue A - it says Uh-Oh!, and when all the LEDs are lit on Scribbler B, it says TaDa!

Enjoy the video! The code for both of these examples is available on the Forums at the link above.

Number Three - And last one... maybe!

I call this one Ribbon Following.

I took a black piece of ribbon (weighted with a quarter taped to the back) and attached it to my blue Scribbler. Using the S2 default line following program, the S2 gives chase. The slightly raised ribbon attached to the Scribbler seems to work well - with the usual goofs, of course! I had to adjust the speeds of the two bots to make the following work best. See photo below and...Enjoy this video - Thanks to videographer, scribbler-kart!

No comments:

Post a Comment