|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#2
|
|||
|
|||
|
Re: Autonomous (Iterative)
The name of the forum makes it sound like you want to do this using the Iterative callback style of autonomous. Unless you really know what you are doing, I'd actually suggest doing it in the Independent VI.
I've made some suggestions below marked with **s. Greg McKaskle Heres what I want the robot to do (we're coding using the holonomic vi) (we need it to read 3 true false switches (1 for each section of the field) (the only difference is the time for steps 3&7) 1.Drive robot forward (for a short time) (0 degrees) ** Call the Drive VI to set the motor speeds. Wire the error I/O to a Wait and Feed VI with the seconds that you want the motors at that speed. If you have encoders or other, more reliable method, you can wire the error I/O to a loop that sleeps for a millisecond or two at a time and polls the encoder. 2.Release a solenoid. ** Wire the error I/O from the Wait and Feed to the Set Solenoid. It seems like you also want to set the Drive motors to 0 here. Again, use the error I/O for sequencing. 3.Run 2 motors (separate from the holonomic drive and hooked up to spike relays for a short time) (+1 value) ** Use the error I/O to sequence and Motor Set Speed to rearm. 4.Drive robot left (for a short time) (270 degrees) ** Repeat the pattern of setting Drive speeds, then Wait and Feed. 5.Drive robot forward (for a short time) (0 degrees) 6.Release a solenoid. 7.Run 2 motors (separate from the holonomic drive and hooked up to spike relays for a short time) (+1 value) 8.Drive robot left (for a short time) (270 degrees) 9.Drive robot forward (for a short time) (0 degrees) 10.Release a solenoid 11.Stop all motors and end autonomous mode Questions 1.Ideas on if it can be done in the required 15 sec. ** My recommendation is to try and drive it with a joystick. If a decent driver can't do it, then I doubt the computer can. The computer may ultimately be more consistent, but it is unlikely to be faster, more adaptive, or better at driving. This also helps to figure out the speeds and times that make sense. In fact, you may wish to plot or record the joystick values as the driver does the task. You may choose to simplify the values, but in fact ramping up the speed or other subtleties may turn out to be quite important for consistent driving. Better to mimic those in the SW after you know what they are than try to code them in blindly. 2.If someone can post an example picture (in labview) or talk me through making it ** I've attached a picture of the first few steps. I'd also also highly recommend making some of these tasks into higher level subVIs -- things like ramping up speed or going in a particular direction for time could easily be parameterized into reusable blocks. Good luck with Auto. Greg McKaskle |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Iterative Robot Template? | jalburty | C/C++ | 4 | 08-04-2011 13:57 |
| Iterative Robot demo | mandrews281 | C/C++ | 0 | 21-03-2009 15:45 |
| Continuous vs. Autonomous in Iterative Robot | Shira | C/C++ | 4 | 06-02-2009 04:20 |
| C++ Robot: Simple or Iterative? | Abrakadabra | Programming | 3 | 14-01-2009 22:01 |
| Iterative Scoring Program | TimA | Rules/Strategy | 1 | 18-01-2007 21:43 |