Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Too many PWM's shorting out power? (http://www.chiefdelphi.com/forums/showthread.php?t=101008)

Landonh12 23-01-2012 22:06

Too many PWM's shorting out power?
 
First of all, this could apply to programming, motors, or electrical. I'm a programmer, so i'm going to post this here. If it needs to move somewhere else, someone in authority please do so.

I am programming in this year's LabVIEW.

Okay. We have been putting together a test robot to propel the basketballs into the hoops. We have 4 Jag's running (Drive) and 1 Victor running (Shooter).

All of the Jag's are put into the Digital Sidecar PWM slots 1, 2, 3, and 4.

The Victor is put into PWM slot 5.

When i disable the Victor, and run our Drive code, it runs just fine. No problems, no tinks, nothing. But, when we enable the Victor, and disable the drive code, nothing happens. Absolutely nothing. Could this be something wrong with the sidecar or something wrong with the Victor? All of the code is fine, all of the RefNum's are exactly the same.

Thanks, for any help.
Team Fusion 364

engunneer 23-01-2012 22:19

Re: Too many PWM's shorting out power?
 
if you plug the victor in to the PWM where a Jag was, does it enable with the drive code?

What do your LEDs do?

Is the victor response the same with and without a motor connected?

if the victor is not in the system, and you enable the drive and shooter code, does the drive still work?

Are your loops looping?

Alan Anderson 24-01-2012 01:08

Re: Too many PWM's shorting out power?
 
When you say "disable the Victor", what do you mean?

Since you're asking about programming, it would help greatly if we could see your code. Show us at least the relevant sections of Begin and Teleop.

WizenedEE 24-01-2012 01:42

Re: Too many PWM's shorting out power?
 
Is your digital sidecar powered by wires coming from the PD board? ie, are the BAT, 5V, and 6V LEDs on? I've heard that could make one or two PWMs work but not all of them. That doesn't theoretically make much sense, since the sidecar circuitry is mostly pass through for PWM, but hey.

EricVanWyk 24-01-2012 03:18

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by WizenedEE (Post 1112473)
Is your digital sidecar powered by wires coming from the PD board? ie, are the BAT, 5V, and 6V LEDs on? I've heard that could make one or two PWMs work but not all of them. That doesn't theoretically make much sense, since the sidecar circuitry is mostly pass through for PWM, but hey.

Actually, the PWM signals are buffered on the DSC. It does make sense :)

Landonh12 24-01-2012 13:55

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by Alan Anderson (Post 1112460)
When you say "disable the Victor", what do you mean?

Since you're asking about programming, it would help greatly if we could see your code. Show us at least the relevant sections of Begin and Teleop.

Disabling the Victor in the code.
I will post a picture later today, around 5 CST.

@WizendEE
Yes, the 5v and 6v lights are on.

zaphodp.jensen 24-01-2012 15:28

Re: Too many PWM's shorting out power?
 
Troubleshooting information and Ideas:

Do you have your Victor PWM cable plugged in the correct direction?

Does enabling both do anything different?

Does plugging a Jaguar into the victor's cable work? Does plugging the victor into a Jaguars cable work?

Does changing the PWM port to say, 8 make it work?

What the problem sounds like is a hardware problem and not a software problem.

Alan Anderson 25-01-2012 00:05

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by Landonh12 (Post 1112673)
Yes, the 5v and 6v lights are on.

If the BATT LED isn't also on, that supports the idea that you might not be getting power to the Digital Sidecar properly.

slijin 25-01-2012 00:11

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by WizenedEE (Post 1112473)
Is your digital sidecar powered by wires coming from the PD board? ie, are the BAT, 5V, and 6V LEDs on? I've heard that could make one or two PWMs work but not all of them. That doesn't theoretically make much sense, since the sidecar circuitry is mostly pass through for PWM, but hey.

The reason it works is because the DS leeches power from the cRIO, which is generally enough to run a few of the outputs, but not all.

dyanoshak 26-01-2012 11:16

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by zaphodp.jensen (Post 1112713)
Does plugging a Jaguar into the victor's cable work? Does plugging the victor into a Jaguars cable work?

A side note: Remember that you must configure your code to use either a Jaguar or a Victor (for each motor instance). Jaguar uses the full range of the Servo PWM signal coming out of the cRIO. If your code is configured for a Victor but you really have a Jaguar hooked up, the Jaguar will not swing to full forward or full reverse.

Landonh12 26-01-2012 18:57

Re: Too many PWM's shorting out power?
 
The problem is resolved.
Most of the problem was wiring, and some was programming.
We had the code using a Victor, which is what we were using. Thanks.

Hawiian Cadder 26-01-2012 20:26

Re: Too many PWM's shorting out power?
 
Could you specify the solution you found? We have a Crio that will only do 2 motors controlled at the same time and are utterly stumped.

Landonh12 28-01-2012 12:12

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by Hawiian Cadder (Post 1114239)
Could you specify the solution you found? We have a Crio that will only do 2 motors controlled at the same time and are utterly stumped.

Our cRIO was plugged into the power supply for a camera, so it wasn't getting enough power.
What are you programming in?

el_pablo 01-02-2012 21:45

Re: Too many PWM's shorting out power?
 
We are having the same problem.

When we try to control more than 2 motors with the PWMs, the system starts to have problem.

Scenario 1
With the Axis camera, when running the 2 step motor, one of them starts to skip. Adding a third motor, both of step motors jitters.

Scenario 2
Using 2 jags and 1 victor, one jag skips every few seconds.

So what could be the problem? Power?

Thanks for helping

Alan Anderson 02-02-2012 00:25

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by el_pablo (Post 1118173)
We are having the same problem...
So what could be the problem? Power?

The same symptoms suggest the same fix: make sure you are properly supplying 12 volts to the Digital Sidecar from a 20 amp breaker on the Power Distribution Board.

slijin 02-02-2012 00:49

Re: Too many PWM's shorting out power?
 
Quote:

Originally Posted by el_pablo (Post 1118173)
Scenario 1
With the Axis camera, when running the 2 step motor, one of them starts to skip. Adding a third motor, both of step motors jitters.

To add to Alan's response, check to make sure that the frame of the Axis camera is isolated from the robot's, as the Axis camera is grounded to its frame.

el_pablo 02-02-2012 10:18

Re: Too many PWM's shorting out power?
 
Here is a video I made yesterday during the testing.

It's in french but I wrote in a previous post what is happening.


Youtube video here


As you can see, it jitters even when not running.

Here is a screen shot of our begin.vi


Here is the teleop code


Thanks for helping

Alan Anderson 02-02-2012 12:51

Re: Too many PWM's shorting out power?
 
el_pablo:

When you said "step motor" before, did you mean "servo"?

You're defining the camX and camY servos, but you never command them to move.

The nouveauMotor device reference is not defined in Begin. You should be seeing an error message on the Driver Station telling you about that.

I can't see YouTube videos from where I am, but I'm going to guess that you haven't installed the servo power jumpers next to the PWM pins on the Digital Sidecar for the camera servos. If they are indeed being powered, then a "twitch" is usually an indication that they're not getting a PWM signal, and are just picking up noise on the wires.

el_pablo 02-02-2012 13:59

Re: Too many PWM's shorting out power?
 
Sorry my mistake, they are servos not stepmotors.

The diagrams show the second scenario which includes 2 jags + 1 victor and no servo. Althought they are declared we don't use them in this test case.

Concerning the servos, the power jumpers are installed.

We started the project using the default template. Should I delete a few things before coding?

Thank you

el_pablo 02-02-2012 14:16

Re: Too many PWM's shorting out power?
 
Just figured out that in the begin.vi there were some "junk" declaration out of the screen in which some PWMs were in conflict...

I hope this is source of the problem.



All times are GMT -5. The time now is 19:01.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi