Quote:
|
Originally Posted by TEAM1949
I understood the idea of the whole thing and it is very helpful. ammm in addition, 127,0 in drive doesn' stop the robot.
You are forggeting that the drive doesn't use values of pwm.
to stop the robot I wiil write 0,0 (speed, direction)
but that one was great.
I will test it tomorrow.
Can you or anyone else give another varient?
TNX ahead.
edit:
d = GetGTSensor ( GTS_DIG_IO ) ;
d = d/ GEAR_COUNT_PER_INCH ;
d equales both of those lines?
|
Thanks for pointing out the "Drive" error. I forgot that we modified the code so that 127 is "stop." That was way back near the beginning! But you are correct, the unaltered Drive would be Drive(0,0) equals stop.
Yes d equals both of those lines. The first line gets the absolute gear tooth count (which isn't distance), then the second line CHANGES d to equal the number of inches travelled. If you find any other problems be sure to post, because remember others are looking too, and we don't want to lead anyone astray!
