View Single Post
  #1   Spotlight this post!  
Unread 24-01-2009, 21:09
smcmahon's Avatar
smcmahon smcmahon is offline
The Architect
AKA: Sean McMahon
FRC #2656 (QUASICS)
Team Role: Coach
 
Join Date: Jan 2008
Rookie Year: 2008
Location: Pittsburgh, PA
Posts: 197
smcmahon is an unknown quantity at this point
Post using a switch/button to turn on a motor

As a novice LabView programmer, I'm going to post this here to see if it's a viable way to code the outcome I'm looking for... which it this:

I have a CIM motor. It's connected to a Jaguar, and then to PWM channel 10 on the digital sidecar in Slot 4. I want to set a speed for this motor in the code (preferably in percentages, like 85%). And then I want to have a switch turn that motor on/off. In the final outcome, I imagine I'll actually have a joystick turn this on/off, but for now, I want to test it with a button on the Front Panel.

I've attached the code I wrote. It's in a while loop, which I am hoping is controlled properly by the ON/OFF switch (Boolean). Does this look like it will work to do what I want?
Attached Thumbnails
Click image for larger version

Name:	labview_code.jpg
Views:	154
Size:	77.6 KB
ID:	7216  
Reply With Quote