by i-Bot » Thu May 03, 2007 10:26 am
by i-Bot
Thu May 03, 2007 10:26 am
I don't understand how this works, I couldn't make it work.
You are reading a pulse input from the Gyro using an analog input. Do you have the Gyro actually enabled ?
I would propose the following to see the Gyro working:
MOTOR G24
SPEED 10
GYROSET G6A,0,1,1,1,0,0
GYROSET G6D,0,1,1,1,0,0
GYRODIR G6A,0,0,0,0,0,0
GYRODIR G6D,0,0,0,0,0,0
GYROSENSE G6A,0,250,200,250,0,0
GYROSENSE G6D,0,250,200,250,0,0
gm:
DIM t AS BYTE
t = PEEK(1328)
t = t * 3
SERVO 12,t
GOTO gm
The location 1328 will have a value which is proportional to the Gyro angular velocity in the range 4 to 56. (1329..1331 for other gyro)
I don't understand how this works, I couldn't make it work.
You are reading a pulse input from the Gyro using an analog input. Do you have the Gyro actually enabled ?
I would propose the following to see the Gyro working:
MOTOR G24
SPEED 10
GYROSET G6A,0,1,1,1,0,0
GYROSET G6D,0,1,1,1,0,0
GYRODIR G6A,0,0,0,0,0,0
GYRODIR G6D,0,0,0,0,0,0
GYROSENSE G6A,0,250,200,250,0,0
GYROSENSE G6D,0,250,200,250,0,0
gm:
DIM t AS BYTE
t = PEEK(1328)
t = t * 3
SERVO 12,t
GOTO gm
The location 1328 will have a value which is proportional to the Gyro angular velocity in the range 4 to 56. (1329..1331 for other gyro)