----------------------------------------
> From: mtr...@web.de
> To: amforth-devel@lists.sourceforge.net
> Date: Fri, 24 Oct 2014 20:56:12 +0200
> Subject: Re: [Amforth] Amfort 5.5 template.asm comments
>
>> I know this isn't the easiest makefile magic, but if someone has time to 
>> play with the build process.
>
> Sounds like a web page. Enter some configuration data and get
> the compiled hex files and with all stuff included. Its possible,
> yes. May need a week or two to do it. I'd love to see it come true.
> Really.
I'm not catching that ball. However I have one other trick how I have used 
makefile

I have this target for one board which has Lantronix telnet <-> serial port 
converter
shell:
        socat pty,link=./com1,echo=0,crnl EXEC:"telnet xport 10001" & sleep 3 
&& echo -e "xport\n">com1&&sleep 1&&python2 ../../tools/amforth-shell.py -p 
./com1 -s 9600;pkill socat

The socat connects to board (hostname xport) and converter asks password which 
is xport
and then shell takes over and when shell exits, socat cleans itself up.

make shell invokes amforth-shell and connects to it. However this could be
less specific and connect to serial port. But I show the more specific way to 
give a hint if someone
needs it.

shell:
       python2 ../../tools/amforth-shell.py -p ./dev/ttyUSB0 -s 9600

would be more generic and adding shell to .PHONY section.

Also makefile should set path for AMFORTH_LIB to ../../lib/ . Or Amforth-shell 
could have also -I switch for includedir.

And being able to find right python version for shell could be one of those 
things which would make user experience better.
If I remember right it, needed some thinking before I got amfort-shell running 
as error messages weren't that informative when
running under python 3.

Best regards,
Hannu Vuolasaho

                                          
------------------------------------------------------------------------------
_______________________________________________
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