Browse Source

patching again the terminal

phyto 5 months ago
parent
commit
8bb519fe17
2 changed files with 5 additions and 4 deletions
  1. 2
    2
      ui/Makefile
  2. 3
    2
      ui/terminal.c

+ 2
- 2
ui/Makefile View File

@@ -1,7 +1,7 @@
1 1
 
2 2
 CC	= gcc
3 3
 CCOPT	= -Wall -g -DDEBUG_LEVEL=1
4
-CLIB	= core/libdd2m-core.a viz/libdd2m-viz.a
4
+CLIB	= ../core/libdd2m-core.a ../viz/libdd2m-viz.a
5 5
 
6 6
 OSERIAL = ../serial/serial.o ../serial/funcs.o
7 7
 
@@ -9,4 +9,4 @@ terminal.o:	terminal.c Makefile terminal.h
9 9
 	$(CC) ${CCOPT} $< -c 
10 10
 
11 11
 t:		t.c terminal.o
12
-	${CC} ${CCOPT} $< terminal.o ${OSERIAL} -lncurses -o $@
12
+	${CC} ${CCOPT} $< terminal.o ${OSERIAL} ${CLIB} -lncurses -o $@

+ 3
- 2
ui/terminal.c View File

@@ -92,8 +92,9 @@ do	{
92 92
 		received = wgetch(glass);
93 93
 		echo();
94 94
 
95
-#if DEBUG_LEVEL > 1
96
-		sprintf(ligne, " got $%X\n", received); 
95
+#if DEBUG_LEVEL 
96
+		sprintf(ligne, " got $%X '%c'\n", received,
97
+			isprint(received) ? received : '?'); 
97 98
 		waddstr(glass, ligne); wrefresh(glass);
98 99
 #endif
99 100
 

Loading…
Cancel
Save