Date: Fri, 4 Apr 1997 14:48:25 +0200 (MET DST) From: Zahemszky Gabor <zgabor@CoDe.hu> To: freebsd-questions@freebsd.org (FreeBSD questions) Cc: bmcgover@cisco.com Subject: Re: line disc. tutorial/info on struct tty? Message-ID: <199704041248.OAA01217@CoDe.hu> In-Reply-To: <199704031529.KAA00242@bmcgover-pc.cisco.com> from Brian McGovern at "Apr 3, 97 10:29:34 am"
next in thread | previous in thread | raw e-mail | index | archive | help
> Does anybody know of a tutorial or a good book concerning handling > setup, initialization, and use of line disciplines? I'm trying to descern > as much as I can from the sio driver, but I'd like to see something > in print... > -Brian > Maybe APUE from Stevens? (Advanced Programming in the UNIX Environment) Addison-Wesley. Gabor --- #!/bin/ksh trap 'rm -f /tmp/$$.$$' EXIT HUP INT QUIT TERM&&print '21N16I25C25E30, 40M30E33E25T15U!'>/tmp/$$.$$&&IFS=' ABCDEFGHIJKLMNOPQRSTUVWXYZ '&&set -A X $(</tmp/$$.$$)&&IFS=' 0123456789 '&&set -A Y $(</tmp/$$.$$);IFS=' '&&set -- "${X[@]}"&&for i do [[ $i = ? ]]&&print $i&&continue;[[ $i = ??? ]]&&j=$i&&i=${i%?};typeset -i40 i=8#$i&&print -n ${i#???}&&[[ "$j" = ??? ]]&&print -n "${j#??} "&&unset j;typeset +i i;done;set -- "${Y[@]}"&&set -A X&&for i do [[ $i = , ]]&&i=2;[[ $i = ?? ]]||typeset -l i;set -A X "${X[@]}" $i&&typeset +l i;done&&set -- ${X[@]}&&print $*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199704041248.OAA01217>