Go to Post Admitted to MIT '14. FIRST is good stuff. - sparrowkc [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 Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
  #31   Spotlight this post!  
Unread 14-12-2010, 12:50
Jon236's Avatar
Jon236 Jon236 is offline
Registered User
AKA: Jon Mittelman
FRC #2648 (Infinite Loop)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2000
Location: Windsor, Maine
Posts: 741
Jon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond repute
Re: Mecanum - use of gyro

Greg,

I'm curious....why does the PID.vi itself use a regular while loop, rather than a timed loop?
__________________
Jon Mittelman

Senior Judge Advisor New England & Israel 2014-2015
Infinite Loop Mentor 2011-2015
TechnoTicks Mentor 2000-2011
Championship Chairman's Award 2009 Team236 TechnoTicks
Judge 2010-2015 Championships
Senior Judge Advisor New England District Championship 2014-2015
Judge Advisor Tel Aviv Regional 2007-2015
Judge Advisor Pine Tree Regional 2013
Maine Regional Planning Committee
New England District Planning Committee
Lead Inspector Microsoft Tel Aviv Regional 2006-2008
Judge & Lead Inspector GM/Technion Tel Aviv Regional 2006
Judge UTC Hartford Regional 2006
Reply With Quote
  #32   Spotlight this post!  
Unread 14-12-2010, 23:03
kamocat's Avatar
kamocat kamocat is offline
Test Engineer
AKA: Marshal Horn
FRC #3213 (Thunder Tech)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 2008
Location: Tacoma
Posts: 894
kamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nicekamocat is just really nice
Send a message via AIM to kamocat Send a message via MSN to kamocat
Re: Mecanum - use of gyro

Quote:
Originally Posted by Jon236 View Post
Greg,

I'm curious....why does the PID.vi itself use a regular while loop, rather than a timed loop?
In this case, the While loop is actually not used to loop the PID function (if it were, the PID function would never get new inputs). It is instead simply for its shift registers. Note that the loop is set to end on the first iteration, and none of the shift registers are initialized (meaning they retain their values between calls).
It is also a reentrant VI, storing the shift register data separately for each instance.

The other way to accomplish this is to use feedback nodes (found in the structures palette). However, shift registers often create cleaner and more readable code, and so are more commonly used.
__________________
-- Marshal Horn
Reply With Quote
  #33   Spotlight this post!  
Unread 15-12-2010, 10:09
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,748
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: Mecanum - use of gyro

Since the PID VI is a subVI, it is intended to be placed after the sensor and before the actuator. Placing this into a user's loop, timed loop, or callback lets the user control the timing and priority. If these are placed into a timed loop set at a higher priority, the PID and other VIs will inherit the higher priority.

If this were flipped and the PID were an object that owned the loop, you could do this by registering the sensor, actuator, timing, priority, and other elements with it. I believe this is how it was done with Java and C++.

I'm assuming this was useful because the PID may need to spin up a new thread and this handles it for the user. Meanwhile in LV, it is easy to draw a parallel loop if that is what you want.

Different strokes.
Greg McKaskle
Reply With Quote
  #34   Spotlight this post!  
Unread 19-12-2010, 23:14
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,034
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: Mecanum - use of gyro

bump.

@mwsmith78: haven't heard from you in almost 2 weeks. could you give us an update on where you're at with this? did you resolve it successfully, or did you move on to other issues?


Reply With Quote
  #35   Spotlight this post!  
Unread 10-01-2011, 15:10
keericks's Avatar
keericks keericks is offline
Registered User
AKA: Kent
FRC #1671 (Buchanan Bird Brains)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1998
Location: Clovis
Posts: 55
keericks is a glorious beacon of lightkeericks is a glorious beacon of lightkeericks is a glorious beacon of lightkeericks is a glorious beacon of lightkeericks is a glorious beacon of light
Re: Mecanum - use of gyro

Quote:
Originally Posted by mwsmith78 View Post
Lots of posts since my last one ... I will try to knock off all the questions.

Using 6" Mecanum wheels with tapered rollers (from AndyMark). Wheels are correctly mounted. The robot drives correctly w/o PID loop - although it does tend to have rotation error. Given that it works well before attempting closed-loop control, I believe that points to the software.

If I understand correctly about the PID post - the I & D gain values are time constants and for tuning purposes should start HIGH and work down. Meanwhile, the proportion gain should start low and work up. That may explain why we were having trouble tuning. When we inserted I and/or D values, we started very small. If we want it to function as a P-only loop, is setting I and D to zero correct?


http://www.youtube.com/watch?v=KL7iZXCRtPw
In the video above, I notice the person pushing the robot and it responds to return back to a specific pointing direction. Is this based on vision camera, gyro, wheel encoders? Thanks!
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Why you WANT to use a Gyro this year JesseK Electrical 10 19-01-2010 15:49
[FTC]: Anyone know how to use the Gyro? ttldomination FIRST Tech Challenge 0 31-01-2009 21:19
Ever use a helicopter heading hold gyro before? seanwitte Electrical 7 16-01-2008 12:59
how can you use a gyro in autonomous mode magical hands Programming 3 02-01-2004 13:31
Gyro Chip: How To Use archiver 1999 3 23-06-2002 21:57


All times are GMT -5. The time now is 04:36.

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