multi-tasking & serial I/O 
Author Message
 multi-tasking & serial I/O

I am working on a Vesta 68332 board using FORTH.  In my implementation,
I would like to use multitasking, with one task dedicated to handling
RS232 communications to a PC.  I've run into a few problems with
not detecting incoming characters from the PC (using KEY and KEY?) when
my serial comm task is not running.  Shouldn't KEY? "remember" that a
character has arrived, even if it arrived when another unrelated task
was executing?  It appears that when my serial comm task gets its turn
to run, the incoming character has been lost.  

Anyone have experience with this problem, or perhaps does anyone know
of a code sample that I could examine to see how I might alter my
design?

Steve Bygren



Mon, 18 Jan 1999 03:00:00 GMT  
 multi-tasking & serial I/O

The solution depends on the implementation of KEY and KEY? in the Vesta
Forth. If it is done with polling of the on-board SCI port, then it is
possible to miss characters if the task is not running. If the input is
interrupt-driven with a small input queue, then the keys should be
waiting for you when the task runs.

Because there is no standard implementation or behavior for multitasking
Forth systems, this would be a good question for you to ask directly to
Vesta.

--

Finnigan Corporation            
2215 Grand Avenue Parkway        Tel: (512) 251-1574
Austin, TX  78728-3812           Fax: (512) 251-1547


Quote:

> I am working on a Vesta 68332 board using FORTH.  In my implementation,
> I would like to use multitasking, with one task dedicated to handling
> RS232 communications to a PC.  I've run into a few problems with
> not detecting incoming characters from the PC (using KEY and KEY?) when
> my serial comm task is not running.  Shouldn't KEY? "remember" that a
> character has arrived, even if it arrived when another unrelated task
> was executing?  It appears that when my serial comm task gets its turn
> to run, the incoming character has been lost.

> Anyone have experience with this problem, or perhaps does anyone know
> of a code sample that I could examine to see how I might alter my
> design?

> Steve Bygren



Tue, 19 Jan 1999 03:00:00 GMT  
 multi-tasking & serial I/O

Quote:

> > I am working on a Vesta 68332 board using FORTH.  In my implementation,
> > I would like to use multitasking, with one task dedicated to handling
> > RS232 communications to a PC.  I've run into a few problems with
> > not detecting incoming characters from the PC (using KEY and KEY?) when
> > my serial comm task is not running.  Shouldn't KEY? "remember" that a
> > character has arrived, even if it arrived when another unrelated task
> > was executing?  It appears that when my serial comm task gets its turn
> > to run, the incoming character has been lost.

> The solution depends on the implementation of KEY and KEY? in the Vesta
> Forth. If it is done with polling of the on-board SCI port, then it is
> possible to miss characters if the task is not running. If the input is
> interrupt-driven with a small input queue, then the keys should be
> waiting for you when the task runs.

> Because there is no standard implementation or behavior for multitasking
> Forth systems, this would be a good question for you to ask directly to
> Vesta.
> If you're looking for an interrupt-driven, professional-quality,

well-documented Forth for the Vesta 68332 board, contact us at the
address below.  We use the Background Debugging Mode (BDM) for PC host
communications (connected to printer port), rather than the serial port,
so comms are much faster.  Also, we don't download source to the board,
but compile on the PC & download object only.  This means your serial
port is available for the application.  In any case, our multitasker
is very fast, and serial I/O is interrupt-driven, so you shouldn't have
this problem anyway.

--
===============================================
Elizabeth D. Rather              1-800-55-FORTH
FORTH Inc.                         310-372-8493
111 N. Sepulveda Blvd.        Fax: 310-318-7130
Manhattan Beach, CA 90266
http://www.forth.com
"Forth-based products and Services for real-time
applications since 1973."
===============================================



Wed, 20 Jan 1999 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Help: Spawning multi OS tasks running TCL

2. PPP & multi-tasking/initialising

3. PPP & multi-tasking/initialising

4. Multi-tasking and Multi-user

5. Multi-tasking and Multi-user

6. Multi-tasking and Multi-user

7. Multi-tasking and Multi-user

8. Multi-tasking and Multi-user

9. Multi-tasking and Multi-user

10. Multi-tasking and Multi-user

11. Multi-tasking and Multi-user

12. Multi-tasking and Multi-user

 

 
Powered by phpBB® Forum Software