Log in

View Full Version : Code problems, I think.


Josh987
21-02-2010, 14:08
The code deploys without error but when I take the joystick to all forward or backwords (1, -1) or full left or right, the motors stop working alltogether. If i slowly ramp up to full left, right, forward, or backwards though it works fine. I think this is a code problems so any help is much appreciated.

dotbran
21-02-2010, 14:12
How are your Jags set?

Josh987
21-02-2010, 14:41
Sorry, I don't know what you mean. In the code I have opened 4 motors on jags. All the jumpers on the jags seem to be right. The wheels only stop now when i go about half power left, i can go full in all other directions.

dotbran
21-02-2010, 14:46
I don't know what you mean.

Oh, sorry. I meant to ask whether they are set to stop or coast.

The wheels only stop now when i go about half power left, i can go full in all other directions.

Are you using any watchdog or wait delays in TeleOp?

Josh987
21-02-2010, 16:03
The jags are set to coast, no delays in the program. When the wheels stop working the jags get a slow yellow flash( think that means no servo connection.)

Josh987
21-02-2010, 17:50
So i have worked it down to this problem, when i have all 4 motors at full forward, the crio stops suppling power to the digital sidecar( the 5v light turns off). If i then toggle the enable, disable on the drivers station the digital sidecar turns on and then stops when at full power. We used a new battery and changed the side car.

Michael Fadaie
21-02-2010, 18:24
Our team had the same problem. Is the game adapter hooked up to the 12v spot on the pwer distribution board?

Josh987
22-02-2010, 10:48
The game adapter is hooked up correctly, but we had it connected through the ethernet cable to the crio (Before it's asked, yes it was in port 1). I have tried multiple different codes, tank/arcade 4 wheel have the problem, even when i tried using 2 two wheel arcade drives the same problem occurred. I am starting to think this is a electrical problem not code so I might post it there.

Josh987
22-02-2010, 11:20
So the plot thickens, we have just found out that if you unplug any 2 pwm cables (that are connected to jags) the motors are able to go full power and the digital side car doesn't lose the 5v signal from the crio.

Joe Ross
22-02-2010, 11:42
Disconnect all the cables from your digital sidecar, including the 37 pin cable, but keep the power cable plugged in. When you do this, do all 3 power LEDs shine brightly? If not, you have a problem with the power cable.

I'm a little concerned when you say the digital sidecar looses it's 5v signal from the cRIO. Can you show some pictures of how its wired?

Josh987
22-02-2010, 14:51
No, all 3 lights don't show up.

Alan Anderson
22-02-2010, 16:27
No, all 3 lights don't show up.

That's conclusive. You need to correct the 12v power input to the Digital Sidecar. It should come from a 20A circuit breaker on the Power Distribution board. Make sure the wires are stripped the proper length so that the Wago connectors (red/black and white) bite down on the bare wire.

Josh987
22-02-2010, 22:19
Yepp that was the problem, we had the wires reversed.
Thanks very much for all the help.