Go to Post I want to wish everyone a Happy Ship Day. - JohnBoucher [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 12-02-2014, 23:24
xXhunter47Xx's Avatar
xXhunter47Xx xXhunter47Xx is offline
Lord of Lazy
AKA: Austin $wagmaster1337
FRC #4738 (Patribots)
Team Role: College Student
 
Join Date: Jan 2014
Rookie Year: 2013
Location: San Diego
Posts: 305
xXhunter47Xx will become famous soon enough
Window Motor problem

We are trying to have two window motors attached to one victor run when a limit switch is not pressed. The window motors are not running no matter what position the switch is in. We're trying to have it run in periodic tasks.
Here's our labview program.
Begin.vi

This is our switch init


This is our victor init

Periodic Tasks.vi

This is where we want the window motors to run. In the "false" part of the case structure, the constant is 0.

Any help is appreciated. Thanks!
Reply With Quote
  #2   Spotlight this post!  
Unread 13-02-2014, 07:10
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,752
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Window Motor problem

Do you have errors showing up in the diagnostics windows that help?

What value is the limit switch if you probe the wire? If you probe the value going into the motor? This will help identify whether it is a SW or HW/Electrical issue.

Also, if you put the robot into Test mode, you can scroll to find the Pullback motor. You can see the value that periodic updated with. You can also set the value yourself if you want to run the motor a bit. Keep in mind that unless your code reads the robot mode, periodic loops tend to operate even in test mode, so the interactive motor set features may be overwritten by periodic.

Greg McKaskle
Reply With Quote
  #3   Spotlight this post!  
Unread 13-02-2014, 08:39
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,100
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Window Motor problem

Quote:
Originally Posted by Greg McKaskle View Post
What value is ... going into the motor? This will help identify whether it is a SW or HW/Electrical issue.
If a HW issue is indicated, you can use a digital voltmeter to measure the signal on the PWM cable going into the Victor*. If you have a signal, and the Victor is not responding, you may have the PWM connector plugged into the Vic improperly. This is a common problem.

* ask for more detail if you want to pursue this

Reply With Quote
  #4   Spotlight this post!  
Unread 13-02-2014, 08:56
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Window Motor problem

The Periodic Task code must be placed inside an infinite loop (with a suitable delay timer).

What you show will be executed only once in the first few milliseconds that your code is executing, and will never be checked again.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
Reply With Quote
  #5   Spotlight this post!  
Unread 13-02-2014, 09:00
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,100
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Window Motor problem


A bit off-topic, but... It appears from your code that you are calling the Window motors "Pullback" motors. Are you using Windows motors to pull back your catapult arm?


Reply With Quote
  #6   Spotlight this post!  
Unread 13-02-2014, 18:06
xXhunter47Xx's Avatar
xXhunter47Xx xXhunter47Xx is offline
Lord of Lazy
AKA: Austin $wagmaster1337
FRC #4738 (Patribots)
Team Role: College Student
 
Join Date: Jan 2014
Rookie Year: 2013
Location: San Diego
Posts: 305
xXhunter47Xx will become famous soon enough
Re: Window Motor problem

Quote:
Originally Posted by Ether View Post

A bit off-topic, but... It appears from your code that you are calling the Window motors "Pullback" motors. Are you using Windows motors to pull back your catapult arm?


Confidential. But yes, we are using it to pull back the catapult. We have a custom CNC dog ear mech attached to 2 window motors. I can get you pictures once the robot is done if you'd like.

@Mark
Okay, that sounds about right. I'll place it in a loop and see what happens. Give me about 20 minutes. Thanks!
Reply With Quote
  #7   Spotlight this post!  
Unread 13-02-2014, 18:18
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,100
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Window Motor problem

Quote:
Originally Posted by xXhunter47Xx View Post
yes, we are using it to pull back the catapult.
I was just wondering because the window motors are very low power.


Reply With Quote
  #8   Spotlight this post!  
Unread 13-02-2014, 19:12
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,011
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: Window Motor problem

Quote:
Originally Posted by Ether View Post
I was just wondering because the window motors are very low power.
Ah, but they're using two!

I can imagine a mechanism that resets a catapult not needing to operate faster than, say, 10 seconds. In such a (hypothetical) case, two such motors sound sufficient. Not ideal or recommended, but sufficient.
__________________

I am N2IRZ - What's your callsign?
Reply With Quote
  #9   Spotlight this post!  
Unread 13-02-2014, 20:15
xXhunter47Xx's Avatar
xXhunter47Xx xXhunter47Xx is offline
Lord of Lazy
AKA: Austin $wagmaster1337
FRC #4738 (Patribots)
Team Role: College Student
 
Join Date: Jan 2014
Rookie Year: 2013
Location: San Diego
Posts: 305
xXhunter47Xx will become famous soon enough
Re: Window Motor problem

It runs fast enough. Don't worry about that . It's supposed to automagically roll the arm once teleop is enabled. And I got it to work by putting it in a while loop.

After doing that though, the pressure switch isn't sending signal to the DSCar to turn on the compressor. It worked before I implemented the window motors but now it doesn't work. Labview says that I don't have to run the control loop in a while loop as well because that's just redundant, but could that be the case?

Last edited by xXhunter47Xx : 14-02-2014 at 00:26.
Reply With Quote
  #10   Spotlight this post!  
Unread 14-02-2014, 07:31
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,752
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Window Motor problem

If you open the compressor control subVI, by double clicking, you will see that it already contains a loop that runs as long as there is a compressor opened that needs to be controlled.

Please check that the compressor is opened in Begin and registered by name. This will also allow you to use Test mode to see the value of the compressor pressure switch and spike. This will help verify what channels the code is using and what it is commanding. If the SW is doing the right things and the robot is enabled, you may want to check the electrical side of things.

Greg McKaskle
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 21:06.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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