diff options
| author | Michal Idziorek <m.i@gmx.at> | 2015-06-10 13:47:16 +0200 |
|---|---|---|
| committer | Michal Idziorek <m.i@gmx.at> | 2015-06-10 13:47:16 +0200 |
| commit | 559eea53ecdd1e3e45f24d15e8739419b0cd647a (patch) | |
| tree | 59cc8310bc910ed2bfc338d45f66c2a25dcaca92 | |
| parent | 8a665b53229ce8f563b88bb33aa1ab3db4c1c096 (diff) | |
experimenting with ncurses
| -rw-r--r-- | terminal/terminal.c | 6 | ||||
| -rw-r--r-- | userspace/Makefile | 3 | ||||
| -rw-r--r-- | userspace/sys/sgtty.h | 10 |
3 files changed, 16 insertions, 3 deletions
diff --git a/terminal/terminal.c b/terminal/terminal.c index 3dbe5c8..6dca075 100644 --- a/terminal/terminal.c +++ b/terminal/terminal.c @@ -218,8 +218,14 @@ terminal_tty terminal_init(term_out *screen,term_in *input) tty.data=kballoc(2); tty.set_buff=true; + tty.set_buff=false; + tty.set_lfnl=true; +// tty.set_lfnl=false; + + tty.set_echo=true; + tty.set_echo=false; tty.command=kballoc(1); tty.command_l=0; diff --git a/userspace/Makefile b/userspace/Makefile index dfe9ec3..49d93a0 100644 --- a/userspace/Makefile +++ b/userspace/Makefile @@ -33,6 +33,9 @@ ext2.img: $(PROGS) ../mp/mp.bin cp ~/opt/foolos/usr/bin/worm mnt/bin/ cp ~/opt/foolos/usr/bin/dots mnt/bin/ cp ~/opt/foolos/usr/bin/background mnt/bin/ + cp ~/opt/foolos/usr/bin/view mnt/bin/ + cp ~/opt/foolos/usr/bin/ncurses mnt/bin/ + cp ~/opt/foolos/usr/bin/bs mnt/bin/ cp ../mp/mp.bin mnt/boot/ mkdir -p mnt/etc echo "127.0.0.1 localhost" > mnt/etc/hosts diff --git a/userspace/sys/sgtty.h b/userspace/sys/sgtty.h index 9e91b44..24d0218 100644 --- a/userspace/sys/sgtty.h +++ b/userspace/sys/sgtty.h @@ -5,11 +5,15 @@ #define CRMOD 0x10 #define ECHO 0x20 +// TODO: same struct should be used for /terminal/terminal.h ? struct sgttyb{ + int sg_ospeed; - int sg_erase; - int sg_kill; + int sg_ispeed; + + char sg_erase; + char sg_kill; + int sg_flags; - // TODO: same struct should be used for /terminal/terminal.h ? }; |
