|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools |
Rating:
|
Display Modes |
|
#31
|
||||
|
||||
|
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? |
|
#32
|
||||
|
||||
|
Re: Mecanum - use of gyro
Quote:
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. |
|
#33
|
|||
|
|||
|
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 |
|
#34
|
||||
|
||||
|
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? |
|
#35
|
||||
|
||||
|
Re: Mecanum - use of gyro
Quote:
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
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 |