home *** CD-ROM | disk | FTP | other *** search
- ; How to customize the keyboard codes on WM 1.06
- ;
- ; by Trevor Marshall
- ; 26 Mirrelia Way,
- ; Ferndale, West Australia 6155
- ; phone (619)4576059
- ;
- SUMMARY║áá Modification≤áá t∩á customizσá WordMaste≥á 1.0╢áá arσ ì
- described«á Thσá RESOURCE.CO═ file≤ createΣ durinτ thi≤á proces≤ ì
- arσá presen⌠á oεá thσ disk¼á anΣ ma∙ bσ useΣ b∙á ßá licenceσá oµ ì
- WordMaster 1.06 to patch his WordMaster similarly.
-
-
- A≤ ß use≥ oµ WordStar(R⌐ ╔ wa≤ no⌠ completel∙ satisfieΣ witΦ thσ ì
- SCREE╬ edito≥ provideΣ witΦ m∙ owε CROMEMC╧ baseΣ system.
-
- AlthougΦá WordMaste≥ (R⌐ seemeΣ t∩ offe≥ thσ feature≤ ╔á fel⌠á ╔ ì
- needeΣá fo≥ non- wordprocessinτ applications¼á versioε 1.0╢á diΣ ì
- no⌠á offe≥ ß se⌠ oµ keyboarΣ command≤ 'compatibleº witΦ WordSta≥ ì
- anΣá wheneve≥ ╔ trieΣ t∩ usσ thσ vide∩ command≤ ╔ founΣá tha⌠á ╔ ì
- wa≤ deletinτ word≤ whilst tryinτ t∩ shif⌠ thσ cursor!
-
- MicroPr∩á d∩á no⌠ offe≥ 'customizinτ notesº fo≥á WordMaste≥á anΣ ì
- severa∞á attempt≤á t∩ dis-assemblσ i⌠ baseΣ oε m∙á knowledgσá oµ ì
- WordStar'≤á structurσá werσá unsuccessful«á Wheεá thσá codσá wa≤ ì
- finally broken the reason for the difficulty was obvious.
- WordMaste≥á ha≤á ßá decodinτá structurσ whicΦá i≤á nothinτá likσ ì
- WordStar's.
-
- Wheεá ß Contro∞ Characte≥ i≤ typeΣ oε thσ keyboarΣ it≤ valuσá (░ ì
- t∩ 1FH⌐ i≤ useΣ a≤ thσ offse⌠ int∩ ß tablσ whicΦ contain≤á jump≤ ì
- t∩á eacΦ oµ thσ operatinτ routines«á Thσ addresse≤ iε thi≤ tablσ ì
- caε bσ easil∙ changeΣ no⌠ onl∙ t∩ re-assigε change≤ t∩á keyboarΣ ì
- functions but also to enhance the editor's features.
-
- ╔á likσá t∩ observσ thσ effec⌠ oµ globa∞ substitution≤á usinτá ß ì
- command such as
- B 999 < ROLD STRING$NEWSTRING$ V >
- Wheε eacΦ replacemen⌠ i≤ madσ thσ vide∩ modσ i≤ entereΣ t∩ checδ ì
- tha⌠á aεá erro≥ iε typinτ thσ string≤ diΣ no⌠á occur«á Wheεá thσ ì
- ESCAP┼á ke∙ i≤ useΣ t∩ exi⌠ thσ vide∩ modσ thσ nex⌠ substitutioε ì
- occurs, and so on.
- Unfortunatel∙á thσ CONTROL-├ interrup⌠ commanΣ doe≤ no⌠ worδá iε ì
- thσá vide∩ mode¼á s∩ iµ yo⌡ havσ madσ ß mistakσ yo⌡ ma∙á no⌠á bσ ì
- able to interrupt the macro.
- WordSta≥ use≤ CONTROL-╒ t∩ interrup⌠ an∙ routine«
- WordMaste≥á ha≤ it≤ CONTROL-├ interrup⌠ routinσ a⌠ 23EB¼á anΣ aε ì
- entr∙á iεá thσ keyboarΣ decodinτ tablσ t∩ jum≡ t∩á thi≤á addres≤ ì
- effectivel∙á allow≤ interruptioε t∩ thσ vide∩ baseΣ modσ (iεá m∙ ì
- case¼ wheε CTL-╒ i≤ pressed)«
-
- WitΦá WordMaste≥ no≈ doinτ wha⌠ ╔ wanteΣ i⌠ t∩ d∩ ╔ nex⌠á tackleΣ ì
- thσ probleφ oµ thσ disδ drivσ motors.
- Cromemc∩ CDO╙ ha≤ ß featurσ whicΦ switche≤ ofµ you≥ drivσ motor≤ ì
- wheεá thσ disk≤ arσ no⌠ beinτá accessed¼á considerabl∙á reducinτ ìèdisk and head wear.
- Thσá motor≤ arσ turneΣ ofµ b∙ ß 'Turε ofµ Drivσ Motorsº cal∞á t∩ ì
- BDO╙á (96H⌐á o≥ b∙ an∙ prograφ askinτ BDO╙ fo≥á bufferreΣá linσ ì
- input.
- WordMaste≥á accesse≤á thσ BIO╙á jum≡á tablσá directly¼á (withou⌠ ì
- callinτá vißá BDOS)¼á s∩ tha⌠ thσ drivσ motor≤ continuσá t∩á ruε ì
- during an edit.
-
- Thσá tasδ then¼á wa≤ t∩ modif∙ WordSta≥ s∩ tha⌠ thσ drivσ motor≤ ì
- coulΣ bσ turned off during edits.
-
- The BIOS jump table is entered via a routine at 0D4A.
- ╔á havσá intercepteΣá call≤ t∩ thσá CONI╬á routinσá b∙á checkinτ ì
- whethe≥á thσ accumulato≥ (whicΦ contain≤ aε inde° int∩ thσá BIO╙ ì
- jum≡á tables⌐á contain≤á ╢ (CONIN)«á Iµ i⌠ i≤ ß CONI╬á cal∞á thσ ì
- motors are turned off via a call to BDOS.
- Therσá i≤ enougΦ rooφ iε thσ use≥ patcΦ area≤ t∩á implemen⌠á thσ ì
- code needed.
- A≤á WordSta≥ change≤ thσ addres≤ a⌠ 0005╚ whicΦ point≤ t∩á BDOS¼ ì
- thi≤ addres≤ mus⌠ bσ saveΣ prio≥ t∩ enterinτ Wordstar«á Thσ codσ ì
- to effect this is listed below.
-
-
- CUSTOMIZING YOUR WORDMASTER
-
- Invoke Ward Christensen's RESOURCE.COM by typing RESOURCE
- it will prompt with .....
-
- Memory open to XXXX
- *
-
- type O5000 <RETURN>
- U7700 <RETURN>
- RWM.SYM <RETURN> to read in the symbol file
- RWM.CTL <RETURN> " " control "
- RWM.DOC <RETURN> " " comments "
- RWM.COM <RETURN> " " program "
- ? <RETURN>
-
- resource will reply
-
- SYMTBL=1E00 3A70
- PC =0100
- OFFSET=5000
- COMNTS=7700 7B46
- CTLTBL=1800 1935
- *
-
- Then try
- L11C5 1202
-
- And the jump table, fully commented, should be listed.
- From then on, happy patching! (and Merry Christmas)
-
- Trevor Marshall, 13 Dec '80.è
- .paè
- ; The following code was 'fudged' to look like
- ; the display when you use 'Resource'
- ; All lowercase comments are added by hand,
- ; all other labels,etc, come from RESOURCE files
- ;-----------------------------------------------------
- ; The Jump Table at 11C5 is patched to effect
- ; keyboard function changes
- ;
- ; This was the original jump table in WM 1.06
- CTLTABLE: ;11C5
- 11C5 DW DORET ;1345H
- 11C7 DW CURSOR-LEFT-WORD ;126DH
- 11C9 DW CURSOR-R-L-LINE ;1289H
- 11CB DW UP-SCREEN ;142CH
- 11CD DW CURSOR-RIGHT-WORD ;123FH
- 11CF DW SCROLL-DOWN ;1409H
- 11D1 DW INSERT-ON-OFF ;150BH
- 11D3 DW DEL-CHAR-RIGHT ;14ECH
- 11D5 DW CURSOR-LEFT-CHAR ;122AH
- 11D7 DW INSERT-TAB ;153AH
- 11D9 DW CURSOR-DOWN-LINE ;12C1H
- 11DB DW CURSOR-UP-LINE ;1303H
- 11DD DW CURSOR-RIGHT-CHAR ;1216H
- 11DF DW DO-CR ;15ABH
- 11E1 DW INSERT-CR ;1594H
- 11E3 DW DEL-WORD-RIGHT ;1476H
- 11E5 DW DEL-LINE-RIGHT ;14DDH
- 11E7 DW HELP ;1954H
- 11E9 DW SCREEN-UP ;1414H
- 11EB DW DORET ;1345H
- 11ED DW DOTOPORBOTTOM ;1346H
- 11EF DW DEL-LINE-LEFT ;14BFH
- 11F1 DW DORET ;1345H
- 11F3 DW DORET ;1345H
- 11F5 DW SCROLL-UP ;137CH
- 11F7 DW DEL-LINE ;14CEH
- 11F9 DW CUR-RIGHT-TAB ;12B6H
- 11FB DW DOESCAPE ;1205H
- 11FD DW DEL-WORD-LEFT ;1460H
- 11FF DW PUT-CHAR-IN-FILE ;151AH
- 1201 DW DOTOPORBOTTOM ;1346H
- end of table
- ;
- ; My table was patched to the following functions
- CTLTABLE: ;11C5
- 11C5 DW DORET ;1345H
- DW CURSOR-LEFT-WORD ;126DH
- DW CURSOR-R-L-LINE ;1289H
- DW UP-SCREEN ;142CH
- DW CURSOR-RIGHT-CHAR ;1216H
- DW CURSOR-UP-LINE ;1303H
- DW CURSOR-RIGHT-WORD ;123FH
- DW DEL-CHAR-RIGHT ;14ECH
- DW CURSOR-LEFT-CHAR ;122AHè DW INSERT-TAB ;153AH
- DW DORET ;1345H
- DW DORET ;1345H
- DW DORET ;1345H
- DW DO-CR ;15ABH
- DW INSERT-CR ;1594H
- DW DORET ;1345H
- DW PUT-CHAR-IN-FILE ;151AH
- DW HELP ;1954H
- DW SCREEN-UP ;1414H
- DW DORET ;1345H
- DW DEL-WORD-RIGHT ;1476H
- DW INTERRUPTED ;23EBH
- DW INSERT-ON-OFF ;150BH
- DW SCROLL-DOWN ;1409H
- DW CURSOR-DOWN-LINE ;12C1H
- DW DEL-LINE ;14CEH
- DW SCROLL-UP ;137CH
- DW DOESCAPE ;1205H
- DW DORET ;1345H
- DW PUT-CHAR-IN-FILE ;151AH
- 1201 DW DOTOPORBOTTOM ;1346H
- .paè;
- ; To allow a CDOS 'motors off' call, or any other call
- ; to your BDOS you may effect the following changes:
- ;---------------------------------------------------------
- ; Original code at 0100
- 0100 JMP INIT ;0269H
- ; This jump to WMs initialization should be
- ; patched to cause a call to our routine at 01AD
- ;
- ; The jump at 0100 is changed to
- JMP 01ADH
- ;
- ; where this routine has neen patched
- ;NOW SAVE CDOS BASE ADDR BEFORE WM CLOBBERS IT
- 01AD LHLD CDOS-BASE-ADDR ;at 6
- 01B0 SHLD SAVE-CDOS-BASE ;01B6H
- 01B3 JMP INIT ;0269H
- ;
- ;
- ; Original code calling BIOS table jump routine
- 23CE LHLD L0001 ;1
- ;NOW CHANGE CALL TO 0D4A TO CALL OUR PATCH
- 23D1 CALL TBLJUMP ;0D4AH
- 23D4 MOV A,C
- 23D5 PCHL
- etc
- ;
- ; The CALL 0D4A at 23D1 is changed to CALL 01C4 where
- ; we have put this code:
- ; When a call to BIOS occurs this routine intercepts it
- ;
- ;NOW CALL BDOS VIA OUR PATCH
- 01C4 CPI 6
- 01C6 JNZ TBLJUMP ;0D4AH
- ;IF IT WAS A 'CONIN' CALL, INTERCEPT IT
- 01C9 PUSH H
- ;PUT THE RETURN ADDR ONTO STACK, AND PREPARE INDIRECT CALL
- 01CA LXI H,01D4H
- 01CD PUSH H
- 01CE LHLD SAVE-CDOS-BASE ;01B6H
- ;96H CALL TO CDOS TURNS OFF MOTORS
- 01D1 MVI C,96H
- ;NOW 'CALL' BDOS
- 01D3 PCHL
- 01D4 POP H
- 01D5 JMP TBLJUMP ;0D4AH
- ;