Monday, February 9, 2015

Crawl, Walk, Run

I believe the title phrase came from one of Jim Collins' books, on how people and companies can learn and develop new skills. In part, it is about maintaining discipline.

For example, when my husband tries out a new recipe, he is a stickler for sticking to it exactly, the first few times. (I, on the other hand, see recipes as a starting point. It's not unusual for me to look at the ingredients list and say "I don't like this, so I'll substitute that.")

When it comes to building a Lego MindStorms robot, I've been trying to stick with the crawl - walk - run discipline that my husband used in cooking. So our first robot, is straight from the Robotics Invention System book that came with the kit.




I had been trying to use the RIS software on a Virtual Machine(VM), but even in Ubuntu the VM was not registering the USB Tower.  So last night, I went searching:


  1. Configuring the Lego USB Tower on Linux
    • Step 1 worked perfectly, locating and installing the USB Tower driver
    • I attempted Step 2, and got to the "make" command, which failed.
  2. Making the Lego USB Tower Device Permissions Permanent
    • this worked fine.
  3. Since I was having trouble with the Virtual Machine, I decided to try skipping the RIS graphical user interface, and go straight to Not Quite C (NQC). Adrian Smith's Blog (Using Lego Mindstorms on Ubuntu) directions worked perfectly.  I got out the RIS CD again, and was able to install the firmware on the RCX brick:

  4. Next, I began to read up on the NQC programming language.
  5. I have an old edition of Definitive Guide to LEGO MINDSTORMS, Second Edition, except that my copy is First Edition, and designed for the RIS 1.0 and 1.5 (vs. my 2.0).  Dave has his own "bumpbot", which while not the Lego design I used, has the commands I needed to run our robot.
    • So, this morning, I typed in his NQC bumpbot1 code, and tried to load it on my RCX.
    • I got an error: "Downloading Program: error. Could not open serial port or USB device."
    • I confirmed that the USB driver was installed, that the USB Tower was connected to the laptop.
    • I turned on the RCX and set it to Program 1.
    • From the NQC Manual, I knew that I needed to put -Trcx2 in the command line for it to load my RCX.
    • Apparently Adrian's -Susb is also required.
    • so: "nqc -Susb -Trcx2 -d develop/code/bumpbot1.nqc" worked, and it loaded the RCX.
Here it goes:


No comments:

Post a Comment