Friday, February 27, 2015

Tips on Lego Mindstorm

Thanks to the Duxbury High School Lego Robotics Team for allowing me to observe their Lego Mindstorm Class for Alden students in Grades 3-5 as part of Engineering Week.  They taught me a valuable lesson, you don't have to use the instructions! I was so caught up with building the official robots that I forgot that the whole point to Legos is the individualized creativity with the pieces. Now this type of learning isn't for everyone but I've always hated instructions and doing step by step Lego instructions was a huge set back for me.  I'd rather trial and error free build and problem solve throughout the process. That's closer to tinkering anyway.

In a 3 day consecutive after school class, each team built their own robots for battle.  The first day was a lot of experimenting with the parts. The students immediately delved into the kits asking questions about sensors or just building something with gears that physically moved without electricity.  The second day was building their robots for battle, and the third day was the actual battle where the winning robot needed to be pushed out of the circle ring.

I was so excited after the 2 classes I attended that I came immediately back to the library, threw the instructions aside and actually looked at the pieces themselves to build a car. I suggest building first and to have a plan of what sensors to use (that way if you have kids that just want to program they can get started while you build). I knew that I wanted the two large motors to drive the car and a motion sensor. From there I just built the housing to keep it in place being mindful that one side of the EV3 Block (the Gameboy looking piece) has alphabet ports for the motors while the other side includes the number ports for the sensors. Once you start programming on the computer, you have to make sure the letters/numbers on the top of the blocks below match the ports that you used on the EV3 block.  (Motors were connected to port B + C while motion sensor was connected to port 1).  My goal was that the car would keep driving until the motion sensor is set off and then it will back up, turn and play a note.

My Program
For a brief programming explanation this is my sequence of events, after the green triangle I built a loop where the main motors go forward until the motion sensor is hit (first green and orange block). Outside the loop is another main motor command green block where both wheels are going backward (hence -50 under the speed dial) then the third block is turning with one motor rotating -50 and the other 50 under the speed dial to make the wheels turn. The last green block is the music note which can upload sounds or just play a note.
My Robot


I had the car built and the program running in under 2 hours but I'd suggest a longer class so the students have time to build their own custom bots while others are programming the bot or everyone has time to build a few bots (first hour) and then program them (2nd hour). It does require the computer software so you'll need sufficient laptops. I think ideally 4 or 5 kids per Mindstorm set so they can all stay engaged.  I'm still learning so from here maybe I'll watch an actual Lego Mindstorm programming tutorial video or two or maybe I'll just keep experimenting. Look for updates soon! I just found some great tutorials online for programming the bots with sensor explanations.


Lego Mindstorm Robotics Test 1 from Duxbury Free Library on Vimeo.

No comments:

Post a Comment

Thanks for commenting!