On Mon, Mar 27, 2000 at 02:41:01PM +0200, Olaf Petzold wrote:
> Hallo,
>
> I'm using here RTL-2.2 and the rtf to talk via the rtf-handler with a
> thread code. I have a global variable
>
> unsigned int volatile rt_func_no;
>
> which is changed inside the rtf-handler:
>
> switch(rtf_msg.cmd) {
> ...
> case CMD_SET_FUNCTION:
> rt_func_no = (unsigned int)rtf_msg.data1;
> break;
> ...
> }
>
Do you then do a wakeup?
> and the thread code:
>
> void (*rt_func[RT_FUNC_MAX])(void);
>
> void *thread_code(void *param)
> {
> while(1) {
> pthread_wait_np();
if( rt_func[rt_func_no]())
rt_func[rt_func_no]();
> }
>
> If I switch between the different functions the system is frozen. I guess
> the thread dosn't know about the different functions (pointers) at
> run-time, or what is the reason? How to do in the correct manner ? I
> don't want the create a big thread pool.
>
> Thanks olaf
>
>
>
> Olaf Petzold [EMAIL PROTECTED]
> http://www-hppool.cs.uni-magdeburg.de/~petzold/petzold.html
>
> Otto-von-Guericke-Universitaet zu Magdeburg
>
> -- [rtl] ---
> To unsubscribe:
> echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
> echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
> ---
> For more information on Real-Time Linux see:
> http://www.rtlinux.org/rtlinux/
--
---------------------------------------------------------
Victor Yodaiken
FSMLabs: www.fsmlabs.com www.rtlinux.com
FSMLabs is a servicemark and a service of
VJY Associates L.L.C, New Mexico.
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
---
For more information on Real-Time Linux see:
http://www.rtlinux.org/rtlinux/