; Size: 4096 bytes ; Checksum: 5F90 ; CPU: Intel 8048 (MCS-48 family) ; ; ; ; type2 kb (Cherry) scancodes ; ; ; 8>------------------------ 1 --- 2 --- 3 ------ 4 -------- 5 -------- 6 ----- 7 ----- 8 --------------+ ; center bold italics underline superscript subscript larger defaults | ; 5 6 7 8 9 10 4 3 | ; | ; 9>-------------------------------------------------------------+ | ; 7>--- 9 --- 10 --------- 11 - 12 - 13 - 14 - 15 - 16 - 17 - 18 +-19 - 20 - 21 - 22 - 23 - 24 +-25 --- 26 ----27 ; again delete -> 1 2 3 4 5 6 7 | 8 9 0 - = bs skip help undo ; 1 2 3 4 5 6 7 8 9 10 | 10 9 8 7 6 1 11 2 1 ; | ; 6>--- 28 -- 29 --------- 30 - 31 - 32 - 33 - 34 - 35 - 36 - 37 +-38 - 39 - 40 - 41 - 42 43 --------------- 44 ; find copy tab q w e r t y u i o p [ ] ret margins ; 1 2 3 4 5 6 7 8 9 10 5 4 3 2 11 10 7 ; 10>-------------------------------------------------------------+ | ; 5>--- 45 -- 46 --------- 47 - 48 - 49 - 50 - 51 - 52 - 53 - 54 +55 - 56 - 57 - 58 - 59 --------------+ 61 ; same move lock a s d f g h j k l ; f' b' | font ; 1 2 3 4 5 6 7 8 9 10 5 4 3 2 11 | 8 ; 3>-------------------------------------------------------------------+ | | ; 4>--------- 64 --------- 65j- 65a- 66 - 67 - 68 - 69 - 70 - 71 - 72 +-73 - 74 - 75 - 76j- 76a - 83 +--60----77-----62 ; props nc shft z x c v b n m | , . / nc shft nc defn kbd stop ; 2 3 3 4 5 6 7 8 9 10 | 9 8 6 3 3 4 6 9 1 ; | ; 63 ----------------------------------78 - 79j - 79a - 80 - 81--+ ; open nc nc space nc nc ; 1 5 7 7 10 2 ; ; ; P1 3-6 74159 col adr to key matrix ; P1 0-2 4512 row adr from key matrix ; ; t0 kb matrix sense ; ; t1 kbreq state FF ; ; int kbbiag ; ; ; kbreq' and kbsel' are connected to a pair of differential drivers on the IOP. ; ; When kbreq' goes low, an interrupt is signaled (this is actually a soft interrupt; the 8085 just polls it periodically) ; the 8085 will read data (see below) from the Keyboard Data register (this is gated in an ls374 flip-flop from the keyboard's ; parallel data output). ; ; ksel' goes low when the IOP wants to read the keyboard data, and tells the keyboard to place data onto its output lines ; so this can be accomplished. ; ; org 00000H ; 0000 : 04 10 jmp L0010 ; reset ; 0002 : 00 nop 0003 : 04 96 jmp L0096 ; interrupt ; 0005 : 00 nop 0006 : 00 nop 0007 : 00 nop ; ctr/timer interrupt 0008 : 00 nop 0009 : 00 nop 000A : 00 nop 000B : 00 nop 000C : 00 nop 000D : 00 nop 000E : 00 nop 000F : 00 nop 0010 L0010: 0010 : 23 78 mov a,#078H 0012 : 39 outl p1,a 0013 : 23 7F mov a,#07FH 0015 : 3A outl p2,a 0016 : B8 7F mov r0,#07FH 0018 L0018: 0018 : B0 80 mov @r0,#080H 001A : E8 18 djnz r0,L0018 001C : B8 1F mov r0,#01FH 001E L001E: 001E : B0 00 mov @r0,#000H 0020 : E8 1E djnz r0,L001E 0022 : 05 en i 0023 : 04 30 jmp L0030 ; 0025 : 00 nop 0026 : 00 nop 0027 : 00 nop 0028 : 00 nop 0029 : 00 nop 002A : 00 nop 002B : 00 nop 002C : 00 nop 002D : 00 nop 002E : 00 nop 002F : 00 nop 0030 L0030: 0030 : BA 00 mov r2,#000H 0032 : B8 20 mov r0,#020H 0034 L0034: 0034 : 14 53 call L0053 0036 : B6 41 jf0 L0041 0038 L0038: 0038 : 1A inc r2 0039 : 18 inc r0 003A : FA mov a,r2 003B : D3 53 xrl a,#053H 003D : 96 34 jnz L0034 003F : 04 30 jmp L0030 ; 0041 L0041: 0041 : 23 05 mov a,#005H 0043 : 14 67 call L0067 0045 : 14 53 call L0053 0047 : B6 4B jf0 L004B 0049 : 04 38 jmp L0038 ; 004B L004B: 004B : FC mov a,r4 004C : A0 mov @r0,a 004D : 14 71 call L0071 004F : 14 76 call L0076 0051 : 04 38 jmp L0038 ; 0053 L0053: 0053 : 85 clr f0 0054 : FA mov a,r2 0055 : 39 outl p1,a 0056 : 00 nop 0057 : 26 63 jnt0 L0063 0059 : 23 80 mov a,#080H 005B L005B: 005B : AC mov r4,a 005C : 89 78 orl p1,#078H 005E : D0 xrl a,@r0 005F : C6 62 jz L0062 0061 : 95 cpl f0 0062 L0062: 0062 : 83 ret ; 0063 L0063: 0063 : 23 00 mov a,#000H 0065 : 04 5B jmp L005B ; 0067 L0067: 0067 : AE mov r6,a 0068 L0068: 0068 : BF 63 mov r7,#063H 006A L006A: 006A : 00 nop 006B : 00 nop 006C : EF 6A djnz r7,L006A 006E : EE 68 djnz r6,L0068 0070 : 83 ret ; 0071 L0071: ; keycode lookup 0071 : FA mov a,r2 0072 : E3 movp3 a,@a 0073 : 40 orl a,@r0 0074 : AB mov r3,a 0075 : 83 ret ; 0076 L0076: ; kbd output 0076 : FB mov a,r3 0077 : 90 movx @r0,a 0078 : 00 nop 0079 : 56 80 jt1 L0080 007B L007B: 007B : 8A 80 orl p2,#080H 007D : 9A 7F anl p2,#07FH 007F : 83 ret ; 0080 L0080: 0080 : BD 0A mov r5,#00AH 0082 L0082: 0082 : BE 63 mov r6,#063H 0084 L0084: 0084 : BF 64 mov r7,#064H 0086 L0086: 0086 : 46 7B jnt1 L007B 0088 : EF 86 djnz r7,L0086 008A : EE 84 djnz r6,L0084 008C : ED 82 djnz r5,L0082 008E : 46 7B jnt1 L007B 0090 : 8A 80 orl p2,#080H 0092 : 9A 7F anl p2,#07FH 0094 : 04 76 jmp L0076 ; ; once Domino starts up, it raises the KBdiag flag (this is a write to port 0xef with bit 0x08 set) ; based on the comments in the code, this will cause the keyboard to send a sequence of scancodes ; one for every key on the keyboard, with the "pressed" bit (0x80) set, followed by scancodes D2 and D1 (0x10, 0x6f). ; The comment is "Return sequence of events should be all characters held down followed by D2, D1. 0096 L0096: ; kbdiag 0096 : 23 78 mov a,#078H 0098 : 39 outl p1,a 0099 : 8A FF orl p2,#0FFH 009B : 9A 7F anl p2,#07FH 009D : B8 7F mov r0,#07FH 009F L009F: 009F : B0 80 mov @r0,#080H 00A1 : E8 9F djnz r0,L009F 00A3 : B8 1F mov r0,#01FH 00A5 L00A5: 00A5 : B0 00 mov @r0,#000H 00A7 : E8 A5 djnz r0,L00A5 00A9 : B8 08 mov r0,#008H 00AB : B0 30 mov @r0,#030H 00AD : 23 09 mov a,#009H 00AF : D7 mov psw,a 00B0 L00B0: 00B0 : 86 B0 jni L00B0 00B2 : BB 10 mov r3,#010H 00B4 : 14 76 call L0076 ; send 10H 00B6 : BB 6F mov r3,#06FH 00B8 : 14 76 call L0076 ; send 6FH 00BA : 93 retr ; 0232 L0232: 0232 : 00 nop 0264 L0264: 0300 : 35 70 15 3A 39 38 4E 37 52 62 23 3B 19 18 17 2D ; 0310 : 53 63 12 7D 6D 5E 5F 42 54 64 13 7C 6C 5C 4C 41 0320 : 55 65 1D 7B 6B 5B 4B 3C 30 71 1C 7A 6A 5A 4A 43 0330 : 24 72 14 79 69 59 49 36 33 73 1B 78 68 58 48 44 0340 : 32 74 1A 77 67 57 47 45 50 75 16 76 66 56 46 3D 0350 : 51 61 22 ; 0362 L0362: 0362 : 00 " " nop 0376 L0376: 0376 : 00 " " nop 037D L037D: 037D : 00 " " nop ;-------------------------------------------------------------- Symbol table ============ Value Type Name ----- ---- ---- 0010 Code L0010 0018 Code L0018 001E Code L001E 0030 Code L0030 0034 Code L0034 0038 Code L0038 0041 Code L0041 004B Code L004B 0053 Code L0053 005B Code L005B 0062 Code L0062 0063 Code L0063 0067 Code L0067 0068 Code L0068 006A Code L006A 0071 Code L0071 0076 Code L0076 007B Code L007B 0080 Code L0080 0082 Code L0082 0084 Code L0084 0086 Code L0086 0096 Code L0096 009F Code L009F 00A5 Code L00A5 00B0 Code L00B0 0232 Code L0232 0264 Code L0264 0314 Code L0314 031A Code L031A 0333 Code L0333 0346 Code L0346 0362 Code L0362 0376 Code L0376 037D Code L037D Number of symbols: 35 ;--------------------------------------------------------------