Our bots are ghost driving

This may be another rookie question, but my kids bots are “ghost” driving. The builds are fine but once the brain and battery are on, the bots keep trying to slowly drive away on their own. There is no program running, just the controller that they programmed in vexcode. We don’t know what this means or how to stop it. Any help would be appreciated.

2 Likes

I would guess its the deadband. The joysticks, while in the center position, may be reporting number greater than 0 - like a 1 or 2 which tells the motors to move. Programmers typically set a deadband value which says that the joystick must be reporting 5 or more before the robot should move.

Often you can simply tap the joystick to get it to get it to center at zero. Also, there is a calibration for joysticks in the settings.

7 Likes

Calibrate the joysticks

Use Vexcode Blocks to program your joysticks, increase your deadband. P
Print out on to the brain screen what signal the joysticks are sending so you can tune the deadband.

5 Likes

Would this also fix an issue with the motors ticking? Our motors tend to make a ticking noise after they’ve been moved while the program is running.

1 Like

This deadband concept is new for me. How do you set a deadband?

We have no idea how to increase the deadband. Looked at all the blocks in vexcode blocks and couldn’t find it.

no idea what the deadband is. tapping works, but they’re 8. they always overtap and have to reset driving where they want to be.

I believe you need to do it with code. This is assuming that you are using the right stick for arcade control.

1 Like

This. ^^^

In this code the line of code that begins the ‘if’ statement evaluates whether the stick is larger than the deadband variable. In this case that value is set discretely at the top to a value of 5.

Now if the joystick does not perfectly center when released and is actually sitting at a value between -5 and 5 (aka -deadband or deadband) then the formula in the ‘if’ statement evaluates to FALSE and the ‘else’ side of the statement runs which stops both motors.

If you are just running default coding or even using vexcode but programming your drive by using the Controller function in devices, you do not have this deadband protection and your -5 on the joystick will actually send a -5% signal to the motors and they will creep.

2 Likes

I think we are just using the controller function. How do I teach them otherwise?