On Tue, 2013-11-05 at 20:05 +0100, Matthias Trute wrote:
> Hi Craig,
> 
> > It doesn't matter if I execute key interactively or put it into a
> > new word definition. It always hangs.
> 
> Pressing Ctrl-C and restarting the shell works for me. But nothing
> else..
> 
> > 
> > What am I doing wrong?
> 
> Nothing. The shell has a bug that prevents KEY from working.
> I'm afraid a bugfix is not that simple.

Am I right in assuming that the problem here is that words that expect
interactive input over the terminal hang the shell because the shell is
looking for the next amforth prompt to verify the current line was
correctly received and processed?

My suggestion to handle this situation would be to do too things:

     1. Add a #terminal directive that starts a terminal connected to
        the target over the serial line.  If this terminal can be
        extremely simplistic and included in amforth-shell itself that
        would be ideal.  When the user exits the terminal they get back
        to the shell.
     2. Add a customizable list of words which should automatically
        trigger the terminal when they are sent to the target.  The user
        could then interact with the target as appropriate and manually
        exit the terminal to get back to the shell when appropriate.

--- Keith


------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
Amforth-devel mailing list for http://amforth.sf.net/
Amforth-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amforth-devel

Reply via email to