Skip to content

Commit

Permalink
DSKY Tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
wwarthen committed Sep 27, 2024
1 parent 70a961a commit 5239eed
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 35 deletions.
4 changes: 0 additions & 4 deletions Source/HBIOS/gm7303.asm
Original file line number Diff line number Diff line change
Expand Up @@ -340,10 +340,6 @@ GM7303_EVT_CPUSPD:
; 0123456789012345
;
GM7303_EVT_DSKACT:
;
LD A,(GM7303_PRESENT) ; GET PRESENCE FLAG
OR A ; SET FLAGS
JR Z,GM7303_DSKACT_Z ; HANDLE NOT PRESENT
;
PUSH HL
LD HL,$0100 ; ROW 1, COL 0
Expand Down
7 changes: 4 additions & 3 deletions Source/HBIOS/icm.asm
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ ICM_COLS .EQU 8 ; DISPLAY COLUMNS
;__________________________________________________________________________________________________
;
ICM_PREINIT:
LD A,(DSKY_DISPACT) ; DSKY DISPATCHER ALREADY SET?
OR A ; SET FLAGS
RET NZ ; IF ALREADY ACTIVE, ABORT
;
; RESET PRESENCE FLAG
XOR A ; ASSUME NOT PRESENT
LD (ICM_PRESENT),A ; SAVE IT
;
OR $FF ; SIGNAL TO WAIT FOR KEY RELEASE
LD (ICM_KEYBUF),A ; SET IT
Expand Down
4 changes: 0 additions & 4 deletions Source/HBIOS/lcd.asm
Original file line number Diff line number Diff line change
Expand Up @@ -232,10 +232,6 @@ LCD_EVT_CPUSPD:
; 01234567890123456789
;
LCD_EVT_DSKACT:
;
LD A,(LCD_PRESENT) ; GET PRESENCE FLAG
OR A ; SET FLAGS
RET Z ; HANDLE NOT PRESENT
;
LD HL,$0300 ; ROW 3, COL 0
CALL LCD_GOTORC ; SET DISPLAY ADDRESS
Expand Down
14 changes: 4 additions & 10 deletions Source/HBIOS/pkd.asm
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,10 @@ PKD_PRESCL .EQU PKDOSC/100000 ; PRESCALER
; HARDWARE RESET 8279 BY PULSING RESET LINE
;
PKD_PREINIT:
LD A,(DSKY_DISPACT) ; DSKY DISPATCHER ALREADY SET?
OR A ; SET FLAGS
RET NZ ; IF ALREADY ACTIVE, ABORT
;
; RESET PRESENCE FLAG
XOR A ; ASSUME NOT PRESENT
LD (PKD_PRESENT),A ; SAVE IT
;
; CHECK FOR PPI
CALL PKD_PPIDETECT ; TEST FOR PPI HARDWARE
Expand Down Expand Up @@ -247,19 +248,13 @@ PKD_RESET2:
; CHECK FOR KEY PRESS, SAVE RAW VALUE, RETURN STATUS
;
PKD_STAT:
LD A,(PKD_PRESENT) ; DOES IT EXIST?
OR A ; SET FLAGS
RET Z ; ABORT WITH A=0 IF NOT THERE
CALL PKD_ST
AND $0F ; ISOLATE THE CUR FIFO LEN
RET
;
; WAIT FOR A DSKY KEYPRESS AND RETURN
;
PKD_GETKEY:
LD A,(PKD_PRESENT) ; DOES IT EXIST?
OR A ; SET FLAGS
JR Z,PKD_GETKEY1A ; ABORT IF NOT PRESENT
CALL PKD_STAT
JR Z,PKD_GETKEY ; LOOP IF NOTHING THERE
LD A,PKD_CMD_FIFO
Expand All @@ -278,7 +273,6 @@ PKD_GETKEY1:
INC C ; BUMP INDEX
DJNZ PKD_GETKEY1 ; LOOP UNTIL EOT
POP AF ; FIX STACK
PKD_GETKEY1A:
LD A,$FF ; NOT FOUND ERR, RETURN $FF
RET
PKD_GETKEY2:
Expand Down
29 changes: 17 additions & 12 deletions Source/HBIOS/ppide.asm
Original file line number Diff line number Diff line change
Expand Up @@ -1357,16 +1357,17 @@ PPIDE_RESET:
; THERE IS NO CHECK FOR THE SPECIFIC PPI PORT SINCE IT DOES NO HARM
; IF THE DSKYNG IS SAVED AND RESTORED.
;
; THIS DOES NOT TEST THAT A DSKYNG IS ACTUALLY PRESENT
; AND OPERATING -- COULD CAUSE PROBLEMS
;
;;;#IF (DSKYENABLE)
#IF (PKDENABLE)
; SAVE CONTENTS OF DSKYNG DISPLAY ACROSS RESET
LD B,8
LD C,0
LD HL,PKD_BUF
CALL PKD_GETSTR
LD A,(PKD_PRESENT) ; GET PKD PRESENCE FLAG
OR A ; TEST FOR ZERO
JR Z,PPIDE_RESET_PKD1 ; IF ZERO, NOT THERE, BYPASS
LD B,8 ; LENGTH
LD C,0 ; START
LD HL,PKD_BUF ; BUFFER
CALL PKD_GETSTR ; GET CURRENT DISPLAY TO BUF
PPIDE_RESET_PKD1:
#ENDIF
;;;#ENDIF
;
Expand All @@ -1391,11 +1392,15 @@ PPIDE_RESET:
;;;#IF (DSKYENABLE)
#IF (PKDENABLE)
; REININT DSKYNG AND RESTORE CONTENTS
CALL PKD_REINIT
LD B,8
LD C,0
LD HL,PKD_BUF
CALL PKD_PUTSTR
LD A,(PKD_PRESENT) ; GET PKD PRESENCE FLAG
OR A ; TEST FOR ZERO
JR Z,PPIDE_RESET_PKD2 ; IF ZERO, NOT THERE, BYPASS
CALL PKD_REINIT ; REINIT PKD
LD B,8 ; LENGTH
LD C,0 ; START
LD HL,PKD_BUF ; BUFFER
CALL PKD_PUTSTR ; RESTORE DISPLAY CONTENTS
PPIDE_RESET_PKD2:
#ENDIF
;;;#ENDIF
;
Expand Down
2 changes: 1 addition & 1 deletion Source/ver.inc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#DEFINE RMN 5
#DEFINE RUP 0
#DEFINE RTP 0
#DEFINE BIOSVER "3.5.0-dev.85"
#DEFINE BIOSVER "3.5.0-dev.86"
#define rmj RMJ
#define rmn RMN
#define rup RUP
Expand Down
2 changes: 1 addition & 1 deletion Source/ver.lib
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ rmn equ 5
rup equ 0
rtp equ 0
biosver macro
db "3.5.0-dev.85"
db "3.5.0-dev.86"
endm

0 comments on commit 5239eed

Please sign in to comment.