Anyone had this experience with NXT-G?

This past week, before our FLL competition, one of our FLL teams had a number of errors saving My Blocks.

At this weekend's competition, we experienced having a robot ignore the simplest of programs---rotate motor C 100 degrees. Instead, motors B and C both rotated forward 100 degrees, randomly. We coaches assumed the student had picked the wrong program; but after repeated demonstrations on the practice mat (between rounds) we were convinced that the error was not hers. (sometimes it worked correctly, other times it didn't.

Some NXT "experts" have never experienced these problems, but I'm hearing from others that some teachers have been reporting these errors. I'd appreciate hearing if you have experienced similar problems, so I can get some productive assistance (if it exists).

We are using new Dell laptops (Vista), purchased and managed by a computer professional from our sponsoring company. The software was a group license of NXT-G, purchased from LEGO Education in September 2008. (We own multiple copies, but used one on all of the computers.) Also, there were two teams using the same equipment. The other team did not have the same problem, but, of course, wrote different programs. (They used three My Blocks, while my team used seven My Blocks.)


Dave Parker said…
If two teams were using the same computer (and sharing the default profile?), it is possible that one of the programs or MyBlocks shared the same name as one of the other team's? If so, they will overwrite each other...

A couple of other classic mistakes are forgetting to re-download after a change, or running the wrong program (e.g. you Save As to "MyProg2" after your improvements but still test run with "MyProg" on the NXT, which now has both on it).

These kinds of errors will cause what you are looking at on the screen to not match what is running on the NXT, which is quite confusing. You can test these theories by carefully re-saving, re-downloading, and re-testing, paying attention to the names used.
I'm not sure if this is the kind of problem you experienced, but I had problems with My Blocks with my FLL team's robot in the Nano Quest season. Since we wanted to have multiple programs, we planned to have one big program that would contain all the sub-programs as My Blocks and would allow the user to select and run them quickly and efficiently. However, the first time I tried to do this, I ran into problems with unpredictable behavior similar to what you described. When I used two or three My Blocks, each containing several Move Blocks, the robot would not execute them consistently. It would move more or less than it was supposed to, and I think it even performed the wrong kinds of moves sometimes. When I used the exact same commands, except without the My Blocks, the program worked fine.

Addendum: Even though in the above-mentioned situation I concluded that the software had a bug, I try to do this only as a last resort. The vast majority of problems that at first seem to be problems with hardware/software turn out to be problems with my design or program. Therefore, I've found that it's a good habit to always assume that the product is working fine and that I have the problem, unless I have very substantial evidence to the contrary.
Brian Davis said…
Jonathon: were there ever any cases where two My Blocks might run at the same time, or two place sin the code would try to run Move blocks at overlapping times?
Anonymous said…
I have had similiar errors; I use the retail version on a widows xp operating system.

The first time an error like this came up the origional myblock worked perfectly; whenevery I used that myblock in another peice of code, the data would not be transfered from the myblock to the proceding code. My solution was to copy the origional myblock from the program with it's surronding code and edit it for the rest of the program.

The next time an error occured it was much more serious. The idea was to combine the string of 2 text blocks into two (the result would be 6 strings of text combined into one) the myblock would have 6 inputs for each peice of text, an output of each pece of text to facilitae later wiring, and the string of combined text. When I created the myblock it was fine, but when I tried to make a new one problems occured: Mindstorms NXT said that it needed to end the program and it asked to send an error report. I tried repeatedly to fix this but the same outcome occured, even if I copied the origional myblock and used it in the program elsewhere, Mindstorms NXT would at least say tthat the program is corrupted.

Do you have any advice for this; it would be tedious to write the code out by hand rather than by the myblock (I need to copy the code up to 36 times just to complete one part of the program)
Anonymous said…
Older (maybe all) versions of NXT-G have a bug that will crash the develpment environment if you use a MyBlock with a text data plug. This is a widely (but not universally) know problem.

A problem many teams have writing program managers is that they forget to reset the motors and rotation sensors. That is one of the first things I look at if a MyBlock works great as a standalone program, but fails when combined with others.

I ran into another fun bug recently. I opened a MyBlock and did a Save As using a new name. I then edited the new MyBlock. The problem is that occurrances of the old MyBlock now used this new MyBlock even though their names (and now contents) were completely different. I was very suprised when sound blocks added to the new MyBlock were played in programs that didn't even use the block. I now use "Manage Custom Palette" when copying MyBlocks.
Fay Rhodes said…
They didn't work on the same computer, but each team carried a back-up file for the other team. However, I think their directions were very similar, so the result should have been similar.

Our assumption has always been that the software works correctly. In fact, we coaches assumed she had selected the wrong program, but thought differently once she'd run it on the practice table for us a couple of times.

I can only say that we have been meticulous about re-saving, re-downloading and re-testing. No doubt, we're imperfect, but I'm no novice at using NXT-G.

Jonathan, your experience sounds most similar. It makes me sorry I encouraged them to use My Blocks. (For Brian---There was no overlap of any blocks in our programs---not even a My Block within a My Block.)

I'm wondering if Motor blocks are more dependable. I tend to use them in my own programs, but was urged (by an FLL "expert") to encourage my team to use Move blocks instead.
Dave Parker said…
I agree with Dean that Jonathan's problem was likely not resetting the rotation sensors between sub-programs in the sequencer program. Not knowing more about Fay's situation, I can't say if her's is related to rotation sensor counts, though.
Fay Rhodes said…
I'm certain they did not re-set rotation sensors. But I don't see the connection between ignoring a 100 degree turn command to a single motor and re-setting the rotation sensors.

Is there a "best source" of authoritative information about this?
Robotica said…
why not upload the programs to the form and have the discussion over there?

Anonymous said…
Though myblocks have cuased any problems for me, I have had troubles with my windows vista laptop. Whether this is due to the many setting that people keep changeing or if its just vista, I don't know. I orriginally used an older laptop (Windows XP), but its graphics were slow and NXT-G was near-impossible to use. Furthermore, Lego Digital Designer does not respond correctly on either laptop for some reason.

I am running the new software for NXT-G, available through the lego shop at home site, and although this should work with vista, the problem continues. Also, this new software allows you to store array variables (of the types logic, number, and text, each with thier own data wires,) but there is no block to dynamically read/write values with these data types.

Anyone know how to fix this?
Anonymous said…
That sounds like a motor encoder problem. reloading the firmware might just fix this.
Anonymous said…
This sounds a bit like problem we've experienced with our two FLL botsl. There are times when, inexplicably, the NXT will begin a mission with a hard and fast turn to the left. It's even happened to me when running the table with the kids.

Another problem we've observed are mission programs the appear to decay with random errors as time progresses. At first I attributed it to batteries going flat. But then noticed it will do this with freshly recharged (lego) batteries as well.

I really hope it's something we're doing. It's really maddening!!

We've inserted motor reset blocks at the beginning of each program.
The NXTs are running 1.03 and 1.05 firmware.
Programming with NXT-G 1.1 on Mac G3's

Any thoughts?
Fay Rhodes said…
I've set up a forum topic for this:

It's under NXT-G.

Popular Posts