|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
I am using Windriver Vxworks, C++.
In the previous controller if I wanted something to happen periodically independent of the rest of the code I could use interupts. This year as far as I can tell interupts are no longer usable. Instead, it seems that a better solution would be available. If I could start a second independent thread I could use an infinite loop with a Sleep() in it to achieve the same effect. However, it seems the normal C++ method of starting another thread does not work. It is my understanding that normally you can use "_Fork <functionname>" (without <>) to start a function on another thread. The compiler says that _Fork is undefined, so I'm wondering if anyone has a different solution? |
|
#2
|
||||
|
||||
|
Re: Multiple threads
There has been some discussion on the use of threads/tasks using WPI's wrapper, here are a couple of threads that deal with it.
http://www.chiefdelphi.com/forums/sh...ad.php?t=72371 http://www.chiefdelphi.com/forums/sh...ad.php?t=72607 http://www.chiefdelphi.com/forums/sh...ad.php?t=72439 Although you may still be able to use interrupts. Look into Encoder.h and Encoder.cpp |
|
#3
|
|||
|
|||
|
Re: Multiple threads
Awesome, thanks, I got what I needed from those threads, for some reason my search didn't turn up any of those threads.
Thank you for the help. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [FTC]: Multiple Programs or One Program with Multiple Auto Modes | kevin51292 | FIRST Tech Challenge | 4 | 01-02-2009 08:37 PM |
| Hosting multiple sites in multiple VMs | EHaskins | Website Design/Showcase | 6 | 12-22-2007 01:09 AM |
| threads | Pin Man | CD Forum Support | 1 | 02-23-2003 07:49 PM |