Go to Post The GDC is the Grinch because they just stole my Christmas! - scottmacdonald [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 10-02-2011, 18:45
BrynneRaines BrynneRaines is offline
Registered User
FRC #2224
 
Join Date: Feb 2011
Location: Michigan
Posts: 3
BrynneRaines is an unknown quantity at this point
Programming an Arm?!?

I've only used Labview for about 7 months and I am still confused. Our team is trying to use a PID to control where the arm starts and stops. For example, only rotating 270 degrees. My problem is that I understand the mechanics of a PID and what it means. I'm just not sure how to even begin building it. I was told to connect a PID to a Motor but what else? How do I even define a program for an arm in the Begin.vi? Some help would be great!
  #2   Spotlight this post!  
Unread 10-02-2011, 18:58
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,856
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: Programming an Arm?!?

Here's an example of a motor position slaved to the position of a joystick.

You can replace the joystick with pre-defined values for preset positions.

You do need a sensor on the arm to feedback where it currently is.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 10-02-2011 at 22:58.
  #3   Spotlight this post!  
Unread 10-02-2011, 21:18
BrynneRaines BrynneRaines is offline
Registered User
FRC #2224
 
Join Date: Feb 2011
Location: Michigan
Posts: 3
BrynneRaines is an unknown quantity at this point
Re: Programming an Arm?!?

Quote:
Originally Posted by Mark McLeod View Post
Here's an example of a motor position slaved to the position of a joystick.

You can replace the joystick with pre-defined values for preset positions.

You do need a sensor on the arm to feedback where it current is.
Thank you! This helped so much.
  #4   Spotlight this post!  
Unread 11-02-2011, 17:09
BrynneRaines BrynneRaines is offline
Registered User
FRC #2224
 
Join Date: Feb 2011
Location: Michigan
Posts: 3
BrynneRaines is an unknown quantity at this point
Re: Programming an Arm?!?

Any other suggestions? Helped but still confused, do I need to make two different programs for the shoulder and forearm. I want the shoulder to move 270 degrees and the forearm 180. How would I do this?
  #5   Spotlight this post!  
Unread 11-02-2011, 20:47
2829ron 2829ron is offline
Registered User
FRC #2829
 
Join Date: Jan 2009
Location: USA
Posts: 92
2829ron will become famous soon enough2829ron will become famous soon enough
Re: Programming an Arm?!?

Have you considered doing a timed function? Motor will only run one way for a set amount of time and then stop. Then run the other way for a set time and stop.
  #6   Spotlight this post!  
Unread 11-02-2011, 21:56
Triapod Triapod is offline
Registered User
no team
Team Role: Programmer
 
Join Date: Mar 2010
Rookie Year: 2005
Location: NJ
Posts: 28
Triapod is an unknown quantity at this point
Re: Programming an Arm?!?

Quote:
Originally Posted by 2829ron View Post
Have you considered doing a timed function? Motor will only run one way for a set amount of time and then stop. Then run the other way for a set time and stop.
I considered this before, but as your battery power decreases, the output you get from your motor also decreases. So even though the time is set, the distance traveled will not be the same. Also the resulting error adds up. I'd go with Mark's idea.

You can do the two motor controls in the same way. Just copy and paste the code you have for one motor: so, have two PID controls, each wired to one of the motors and one of the sensors. The program will be the same, just different device reference and different setpoints.
  #7   Spotlight this post!  
Unread 13-02-2011, 15:57
lucoytoa's Avatar
lucoytoa lucoytoa is offline
Programmer
AKA: Nicolas Xiong
FRC #2276 (STARS of Cypress)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Spring, TX
Posts: 20
lucoytoa is an unknown quantity at this point
Re: Programming an Arm?!?

Quote:
Originally Posted by 2829ron View Post
Have you considered doing a timed function? Motor will only run one way for a set amount of time and then stop. Then run the other way for a set time and stop.
Do you have an example of this for Labview? We are trying this with our window motor for our claw and I want to open (reverse) for .5 seconds when button 1 is pressed and when 4 is pressed, motor goes forward .5 seconds and stops but still hold the tube securely. Thanks in advance for your help.
__________________
FRC - STARS of Cypress, 2008, 2009, 2010
FTC - SOAR Club - 2011
FLL - DNAbots - 2009, 2010
BEST - STARS of Cypress - 2008, 2009, 2010
MATE - STARS of Cypress - 2008
MATE - SOAR Club - 2011
VEX - Discobots - 2010
Robofest - 2008
Houston: Energy City of the Future - RNKL Engineering - 2009
  #8   Spotlight this post!  
Unread 13-02-2011, 19:41
lucoytoa's Avatar
lucoytoa lucoytoa is offline
Programmer
AKA: Nicolas Xiong
FRC #2276 (STARS of Cypress)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Spring, TX
Posts: 20
lucoytoa is an unknown quantity at this point
Re: Programming an Arm?!?

Quote:
Originally Posted by lucoytoa View Post
Do you have an example of this for Labview? We are trying this with our window motor for our claw and I want to open (reverse) for .5 seconds when button 1 is pressed and when 4 is pressed, motor goes forward .5 seconds and stops but still hold the tube securely. Thanks in advance for your help.
I got it to work! Thanks, anyway.
__________________
FRC - STARS of Cypress, 2008, 2009, 2010
FTC - SOAR Club - 2011
FLL - DNAbots - 2009, 2010
BEST - STARS of Cypress - 2008, 2009, 2010
MATE - STARS of Cypress - 2008
MATE - SOAR Club - 2011
VEX - Discobots - 2010
Robofest - 2008
Houston: Energy City of the Future - RNKL Engineering - 2009
  #9   Spotlight this post!  
Unread 13-02-2011, 22:14
2829ron 2829ron is offline
Registered User
FRC #2829
 
Join Date: Jan 2009
Location: USA
Posts: 92
2829ron will become famous soon enough2829ron will become famous soon enough
Re: Programming an Arm?!?

Quote:
Originally Posted by lucoytoa View Post
I got it to work! Thanks, anyway.
Just looked here and saw your question and answer. lol. Yeah I do have an example I could've shared. Tried to program it myself last year, tried it in the pit at competition. Didn't work. Programmer from another team did it for me. FIRST can be nice like that, all the GP in the air
Closed Thread


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 23:42.

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