Last try for help with NXT robot

46 views
Skip to first unread message

V Belt

unread,
Dec 13, 2013, 11:08:38 PM12/13/13
to cs4hsrobo...@googlegroups.com
I borrowed an "extra" NXT Mindstorms kit from a private school as our public school doesn't have any at present. I've actually been working with 2 students and we unfortunately have had difficulties since building the robot. The problem is that both motors work independently of each other, but will not work in tandem. The private school instructor who lent us the kit and has done robotics for years took a look and has never seen such a problem and has no idea why this is happening. I did call Lego Tech Support and all they could offer was to update the firmware, which we had already done twice, or check the programming, which was also done and was correct. The conclusion would then be that the NXT brick is defective, which means the end of the road for me and my 2 students - sigh! IF anyone has any other possible ideas, we'd love to hear about them, otherwise, we'll sadly be ending our journey.  THANKS and we've loved the video instruction!

Michael Rabourn

unread,
Dec 14, 2013, 6:36:40 PM12/14/13
to cs4hsrobo...@googlegroups.com
This may be too basic, but are you making sure that you are using a MOVE block which by default controls two motors at once rather than a MOTOR block that controls a single motor? Also, if you are using a MOVE block and it is set to motors B and C, then the cables that go from the motors to the NXT brick ports must be B and C also.

Michael Rabourn

unread,
Dec 14, 2013, 6:40:54 PM12/14/13
to cs4hsrobo...@googlegroups.com
P.S. As a troubleshooting tip, I would plug each motor (one at a time) into each port(A,B,C) and use a MOTOR block to see if each motor works independently with each port. That should allow you to determine if it is one of your motors or one or more of the ports on the NXT.

Michael Rabourn

unread,
Dec 14, 2013, 6:49:24 PM12/14/13
to cs4hsrobo...@googlegroups.com
Last idea. If motors and ports all seem to work, I would test each cable. It is possible that you are not getting a good connection. Hope this helps. Good luck.

Jennifer Kay

unread,
Dec 14, 2013, 9:34:47 PM12/14/13
to cs4hsrobo...@googlegroups.com
Michael has great suggestions. Here are some more thoughts.

If one of your cables is bad, that could explain it. Unplug both your motors, plug them in using different cables. Make sure you've plugged them into the correct ports. Does that help?

If not, can you explain what happens if you write a program that just has a move block go forward for one rotation. Do both the left and right motors move? Does the left one move a full rotation? How about the right one? If one seems to move a full rotation and the other doesn't, swap the cables. Still the same behavior on the same motors? If so, maybe one of the motors is defective. The robot comes with three motors so you could replace one. 

One last thing comes to mind off the top of my head. it's possible that one of the motor ports on the NXT is broken. If both the left and right motors move, but one doesn't move the full rotation when you program it to do so, try plugging that motor into a different port (and then remember to adjust your move block so the NXT knows where your motor is plugged in)

Good luck!

-- Jennie



Message has been deleted

Jennifer Kay

unread,
Dec 15, 2013, 9:51:21 AM12/15/13
to cs4hsrobo...@googlegroups.com
Just to clarify my question more:

  1. Unplug the motor from port B
  2. Write a program that moves forward by one rotation and adjust the configuration panel so that B is unchecked - you're only moving C forward by one rotation
  3. Does this work?

Now try the reverse (C unplugged, B plugged in, C is unchecked)

The reason I want you to try this is the following. If you tell the NXT to move one motor on its own, it just pays attention to that motor and does its best. But if you tell it to move two motors in tandem, then it tries to sync them - if it notices (or thinks it's noticing) one motor moving faster than the other, it will slow the faster one down. So if your NXT is confused about the speed that one of your motors is moving, this could result in weird behavior.
So here's another test: I'm going to assume that your motors are plugged into ports B&C as is the default.

  1. Write a program that has a single move block in it that rotates the motor in port B only (you'll have to uncheck port C in the configuration panel) forward by one rotation. Test it. Does the motor move forward exactly one rotation?
  2. Write another program to do the same test on motor port C only (unchecking port B). Does that motor move forward exactly one rotation?

My bet (hope!) is that one of them won't. Let's suppose B doesn't work. So now, plug the motor that's in port B into port A instead. Write the third version of the program where only port A moves forward 1 rotation (unchecking ports B&C in the configuration panel and checking port A). Does it work?

If so, then yes, your NXT brick probably is the problem, but you can probably get around the problem by using ports A&C. (Similarly, if you discover port C is bad, you'd have to use ports A&B.)

So now test - plug into A&B and try moving forward (with A&B selected) by one rotation. If it does one of the following things it's a good sign:

  1. Drives forward for one rotation
  2. Drives backward for one rotation
  3. Drives one wheel forwards and one backwards for one rotation

If it does #1 you're in great shape

If it does #2 you can experiment with swapping which motor is A & which is B and see if that helps

If it does #3 you will be able to use the NXT, but you'll have to do some "advanced" programming. Every time you want the motors to move forward one rotation you'll have to

  1. Move forward unlimited on motor A
  2. Move backward one rotation on motor B
  3. Stop motor A

Make sense? Hopefully not necessary though,

Jennie


rka...@att.net

unread,
Dec 15, 2013, 8:43:08 PM12/15/13
to cs4hsrobo...@googlegroups.com
If you are using a Move Block with a Duration Setting of Unlimited and this is the only block on the Sequence Beam, the NXT will sometimes just jerk forward for a millisecond and then stop. Change the duration setting from Unlimited to any of the other three settings. 


V Belt

unread,
Dec 18, 2013, 10:49:00 PM12/18/13
to cs4hsrobo...@googlegroups.com
This email post bounced back the other day - not sure why:

So, we went through your checklist and some worked and others didn't. Then
lo and behold - and I mean all of a sudden - everything started to work
correctly! No rhyme or reason as we were trying things over and over again,
and we were shocked as we were just expecting it to not work again and it
started working with the A and C and then it began working with B and C,
whereas before it wouldn't. So we're happy and keeping our fingers crossed
that it doesn't decide to start misbehaving again! We can't say we did
anything in particular to get the motors to work in tandem, so I don't have
a specific "answer" as to what the problem was or why it began following
directions, but THANK YOU for writing all those questions out as it gave us
something to follow.

Back on the road, but quite a bit behind and next week we're off for 3
weeks, so we'll keep plugging away!

Cheers and thanks to everyone for responding!
Valerie

myrobostation BG

unread,
Nov 13, 2017, 6:12:01 AM11/13/17
to CS4HS Robots Course Forums
Unfortunately, there are not many on-line resources that provide introductory tutorials for the NXT™ brick programming, especially for people without previous programming experience.Since neither the robot assembly nor programming are trivial tasks, I will start with a basics of NXC programming, then demonstrate how to use NXC to get and process inputs from different sensors, how to combine sensors with motors, how to create stable mechanic, and finally how to combine everything in a robot.
Reply all
Reply to author
Forward
0 new messages