Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Can't add motors.. (http://www.chiefdelphi.com/forums/showthread.php?t=102179)

Luiz12 07-02-2012 13:20

Can't add motors..
 
Hi I'm current part of a rookie team and I can't seem to add a motor to our control. I started from the original code and just added everything below. I'm using a victor but I cant seem to make the motor run.

Joe Ross 07-02-2012 13:41

Re: Can't add motors..
 
Your code snippets look good on their own. You mentioned that you added this to the default code. The default code already uses PWM 1 for the robot drive. Using it for your separate motor would cause a conflict. Have you tried it on a different PWM channel?

Another potential problem (to quote Alan Anderson) "Correctly plugging a PWM cable into a Victor is maddeningly difficult to do, and nearly impossible to tell when you've failed without trying to control it. It sometimes seems to me that consistently getting it right takes years of experience and practice."

zaphodp.jensen 07-02-2012 13:59

Re: Can't add motors..
 
Have you reworked your DB 137 Cable? Have you gotten a robot to actually drive?

arizonafoxx 07-02-2012 14:44

Re: Can't add motors..
 
In your code it sort of looks like there is an extra space at the end of "Ball Motor" in the begin vi. This will cause a problem. Every variable has to be exactly the same in all 3 vi including spaces. This problem has got us a few times especially with our new programmers. We have spent several hours sometimes troubleshooting all the hardware when in reality when we changed the variables to a different name the problem went away.

Cecil 07-02-2012 14:51

Re: Can't add motors..
 
Quote:

Originally Posted by arizonafoxx (Post 1121721)
In your code it sort of looks like there is an extra space at the end of "Ball Motor" in the begin vi. This will cause a problem. Every variable has to be exactly the same in all 3 vi including spaces. This problem has got us a few times especially with our new programmers. We have spent several hours sometimes troubleshooting all the hardware when in reality when we changed the variables to a different name the problem went away.

Good eye.. I would suspect that to be the problem too.

MJ Miller 07-02-2012 15:51

Re: Can't add motors..
 
I echo what arizonafoxx stated, but add another possible scenario. At the beginning of the season, we flashed our laptop with the 2012 version of the software. However, the 3 updates made available after kickoff were NOT applied. These included updates for Labview, Utilities and the Driver Station. The students used this computer to flash the cRIO, build, and deploy the default code. The default code was edited slightly to include a 4 motor drive system and Arcade drive. Result? The robot ran with no problems!

However, when we tried to add a motor just as you claim, then nothing would work! Not even the drive motors. Weird stuff.

But, installing the 3 updates to the computer, re-imaging the cRIO, and re-compiling the code fixed the failure we encountered and all is well now. :)


All times are GMT -5. The time now is 00:43.

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