]> 4ch.mooo.com Git - 16.git/commitdiff
I fixed the keyboard bug~ ^^
authorsparky4 <sparky4@cock.li>
Tue, 9 Sep 2014 02:35:50 +0000 (21:35 -0500)
committersparky4 <sparky4@cock.li>
Tue, 9 Sep 2014 02:35:50 +0000 (21:35 -0500)
new file:   16/DOS_KB.EXE
modified:   16/Project 16.bfproject
modified:   16/dos_kb.c
modified:   16/modex16/dos_kb.c
modified:   16/modex16/pcxtest.exe
modified:   16/modex16/scroll.c
modified:   16/modex16/scroll.exe
modified:   16/modex16/test.exe
modified:   16/modex16/test2.exe

16/DOS_KB.EXE [new file with mode: 0644]
16/Project 16.bfproject
16/dos_kb.c
16/modex16/dos_kb.c
16/modex16/pcxtest.exe
16/modex16/scroll.c
16/modex16/scroll.exe
16/modex16/test.exe
16/modex16/test2.exe

diff --git a/16/DOS_KB.EXE b/16/DOS_KB.EXE
new file mode 100644 (file)
index 0000000..3527174
Binary files /dev/null and b/16/DOS_KB.EXE differ
index 43a1f5ad262a4bb480497dfa3d48a2f3baa6527c..217dd1c1bbaa2ccc1806ce2f99f1785daedb20fe 100644 (file)
@@ -11,10 +11,9 @@ openfiles: /dos/z/16/16/project16.txt:8063:6091:0:
 openfiles: /dos/z/16/16/16.txt:0:0:0:
 openfiles: /dos/z/16/16/lib/x/MODEX.H:5511:2798:0:
 openfiles: /dos/z/16/16/TEST.C:430:6112:0:
-openfiles: /dos/z/16/16/modex16/scroll.c:1537:1152:1:
-openfiles: /dos/z/16/16/modex16/modex16.h:156:0:0:
+openfiles: /dos/z/16/16/modex16/scroll.c:1744:1341:0:
 openfiles: /dos/z/16/16/modex16/makefile:106:0:0:
-openfiles: /dos/z/16/16/modex16/dos_kb.c:3565:2934:0:
+openfiles: /dos/z/16/16/modex16/dos_kb.c:1017:217:1:
 openfiles: /dos/z/16/16/modex16/dos_kb.h:0:0:0:
 snr_recursion_level: 0
 convertcolumn_horizontally: 0
@@ -80,28 +79,28 @@ recent_files: file:///dos/z/16/16/modex16/PCXTEST.C
 recent_files: file:///dos/z/16/16/lib/MODEX16.C
 recent_files: file:///dos/z/16/16/lib/MODEX16.H
 recent_files: file:///dos/z/16/16/modex16/SCROLL.C
-recent_files: file:///dos/z/16/16/modex16/scroll.c
-recent_files: file:///dos/z/16/16/dos_gfx.h
-recent_files: file:///dos/z/16/16/dos_kb.h
-recent_files: file:///dos/z/16/16/lib/lib_com.cpp
-recent_files: file:///dos/z/16/16/lib/lib_com.h
-recent_files: file:///dos/z/16/16/16.txt
-recent_files: file:///dos/z/16/16/dos_gfx.cpp
-recent_files: file:///dos/z/16/16/project16.txt
-recent_files: file:///dos/z/16/16/scroll.txt
-recent_files: file:///dos/z/16/16/TEST.C
-recent_files: file:///dos/z/16/16/lib/x/MODEX.H
 recent_files: file:///dos/z/16/src/lib/dos_comm.c
 recent_files: file:///dos/z/16/src/eng_comm.cpp
 recent_files: file:///dos/z/16/src/eng_comm.h
 recent_files: file:///dos/z/16/src/lib/dos_comm.h
 recent_files: file:///dos/z/16/16/modex16/lib/lib_com.h
 recent_files: file:///dos/z/16/16/modex16/lib/lib_com.cpp
+recent_files: file:///dos/z/16/16/dos_gfx.h
+recent_files: file:///dos/z/16/16/dos_gfx.cpp
 recent_files: file:///dos/z/16/16/dos_kb.c
+recent_files: file:///dos/z/16/16/dos_kb.h
+recent_files: file:///dos/z/16/16/lib/lib_com.cpp
+recent_files: file:///dos/z/16/16/lib/lib_com.h
+recent_files: file:///dos/z/16/16/scroll.txt
+recent_files: file:///dos/z/16/16/project16.txt
+recent_files: file:///dos/z/16/16/16.txt
+recent_files: file:///dos/z/16/16/TEST.C
+recent_files: file:///dos/z/16/16/modex16/dos_kb.c
 recent_files: file:///dos/z/16/16/modex16/modex16.h
 recent_files: file:///dos/z/16/16/modex16/makefile
 recent_files: file:///dos/z/16/16/modex16/dos_kb.h
-recent_files: file:///dos/z/16/16/modex16/dos_kb.c
+recent_files: file:///dos/z/16/16/lib/x/MODEX.H
+recent_files: file:///dos/z/16/16/modex16/scroll.c
 snr_replacetype: 0
 savedir: file:///dos/z/16/16/modex16
 spell_check_default: 1
index 74f5a48a91d3565610afe0970abeac8aa2cd4938..baffad9e17d8b608a445039e6a622ed93127019f 100644 (file)
@@ -19,6 +19,7 @@ static void interrupt (far *oldkb)(void) = NULL; /* BIOS keyboard handler */
  * to be included.
  */
 #define TESTING
+#define TESTING2
 
 /*****************NEW KEYBOARD 09h ISR***********************/
 void interrupt newkb(void){
@@ -35,8 +36,9 @@ void interrupt newkb(void){
        outp(0x61, qx);    /* Toggle acknowledge bit low */
 
        /* Interpret the scan code and set our flags */
-       #ifdef TESTING
-       printf("%d[%d]\n",kee,key[kee]);
+       #ifdef TESTING2
+       //printf("%d[%d]\n",kee,key[kee]);
+       printf("\0"); // bug
        #endif
        if(kee & 0x80)
                key[kee & 0x7F] = 0; // a key is released
index 7c6030ae4078b40787d88b3a2833b9878d36222f..dd92418994e703db2ad6acdc45bfc270b4a6aa08 100644 (file)
@@ -37,7 +37,8 @@ void interrupt newkb(void){
 
        /* Interpret the scan code and set our flags */
        #ifdef TESTING2
-       printf("%d[%d]\n",kee,key[kee]);
+       //printf("%d[%d]\n",kee,key[kee]);
+       printf("\0"); // bug
        #endif
        if(kee & 0x80)
                key[kee & 0x7F] = 0; // a key is released
@@ -60,7 +61,7 @@ void setkb(int vq){
                _dos_setvect(9, oldkb);
                /* Reset our function pointer to contain no valid address */
                oldkb = NULL;
-               #ifdef TESTING2
+               #ifdef TESTING
                /* Print the key heap */
                printf("\n");
                for(i=0; i<NUM_SCANCODES; i++){
index 4ab5474eda921991e739342a6e978af201ef95d2..6e8c5d12f913163b6adaeb70ce4821e275401815 100644 (file)
Binary files a/16/modex16/pcxtest.exe and b/16/modex16/pcxtest.exe differ
index d3cb8eea0e771d603efeb015807fc8826f8633ca..da42a8ee5bb977fdc73ed1e2bfb8f4d4fa9871c5 100644 (file)
@@ -69,7 +69,7 @@ void main() {
 \r
        /* draw the tiles */\r
        ptr = map.data;\r
-       //modexEnter();\r
+       modexEnter();\r
        screen = modexDefaultPage();\r
        screen.width = 352;\r
        mv.page = &screen;\r
@@ -84,21 +84,21 @@ void main() {
        draw = &mv2;\r
 \r
        while(!keyp(1)) {\r
-       /*if(keyp(77)){\r
+       if(keyp(77)){\r
                for(q=0; q<16; q++) {\r
                mapScrollRight(draw, 1);\r
                modexShowPage(draw->page);\r
-               //mapScrollRight(draw, 1);\r
-               //SWAP(draw, show);\r
+//             mapScrollRight(draw, 1);\r
+//             SWAP(draw, show);\r
                }\r
-       }\r
+       }else\r
 \r
        if(keyp(75)){\r
                for(q=0; q<16; q++) {\r
                mapScrollLeft(draw, 1);\r
                modexShowPage(draw->page);\r
-               //mapScrollLeft(show, 1);\r
-               //SWAP(draw, show);\r
+//             mapScrollLeft(show, 1);\r
+//             SWAP(draw, show);\r
                }\r
        }\r
 \r
@@ -106,26 +106,25 @@ void main() {
                for(q=0; q<16; q++) {\r
                mapScrollDown(draw, 1);\r
                modexShowPage(draw->page);\r
-               //mapScrollDown(show, 1);\r
-               //SWAP(draw, show);\r
+//             mapScrollDown(show, 1);\r
+//             SWAP(draw, show);\r
                }\r
-       }\r
-\r
+       }else\r
 \r
        if(keyp(72)){\r
                for(q=0; q<16; q++) {\r
                mapScrollUp(draw, 1);\r
                modexShowPage(draw->page);\r
-               //mapScrollUp(show, 1);\r
-               //SWAP(draw, show);\r
+//             mapScrollUp(show, 1);\r
+//             SWAP(draw, show);\r
                }\r
-       }*/\r
+       }\r
 \r
-       keyp(ch);\r
+       //keyp(ch);\r
 \r
        }\r
 \r
-       //modexLeave();\r
+       modexLeave();\r
        setkb(0);\r
 }\r
 \r
index 40f86bd05b830ff18eb44a0eb54d6949a0bd7efa..83b0bfc1e0976ad983b3266a12894719edea953a 100755 (executable)
Binary files a/16/modex16/scroll.exe and b/16/modex16/scroll.exe differ
index b0247b18e9ecb1cc9481de996b4b5eeabf440af8..e32a4751b3faf2bd8a8ed001ac4cdea2e28000f9 100644 (file)
Binary files a/16/modex16/test.exe and b/16/modex16/test.exe differ
index 23ca0df0b881ee1fbc2fe085faeb6600d6899847..6476ebc1663e5b5fc4287069e2bcbcc9781f5af4 100644 (file)
Binary files a/16/modex16/test2.exe and b/16/modex16/test2.exe differ