ROBOTC.net forums
http://www.robotc.net/forums/

Arduino+NXShield mismatch with NXT lego brick
http://www.robotc.net/forums/viewtopic.php?f=62&t=5598
Page 1 of 1

Author:  zhossain [ Fri Mar 08, 2013 9:39 pm ]
Post subject:  Arduino+NXShield mismatch with NXT lego brick

Hi I am trying to match up the way a motor works under NXT mindstorm brick to NXShield on Arduino using the exact same configuration. But the motor behaves quite differently for the following setup.

angle = 8 degrees
power = 100
use power control = true/checked
Action = Constant
Next action = Brake

When I translate these settings over to NXSheild I use the following

nxshield.bank_a.motorRunDegrees( motor, direction,
100,
8,
SH_Completion_Wait_For,
SH_Next_Action_Brake);

But they behave very differently even with an external 9v power supply on NXShield.

When I run with lego brick, the motor would move very sharply and oscillate to rest (that'st he behavior I actually want). But in NXShield, the motor moves a little bit but not as sharply as the brick and doesn't oscillate. Then I tried to run the motor by putting 0xBD into the registerA of motor 1 but still no to avail.

Does anyone know how to get NXShield to work exactly like the brick under the above settings. Thanks

Author:  JohnWatson [ Wed Mar 13, 2013 11:27 am ]
Post subject:  Re: Arduino+NXShield mismatch with NXT lego brick

Would you be able to post your full code using the [code] tags? Also, is this code being written in ROBOTC or Processing? I ask because the sample programs on the NXShield's site are using Processing.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/