Browse Source

Minor Fix in SPK Driver and Tick Counter Space Reservation

- Fix ensures that the speaker control bit is set the same as it was initially after playing a tone.
- Reserve 2 bytes in the proxy for a platform dependent tick counter value.  Currently for HEATH platform.
patch
Wayne Warthen 2 years ago
parent
commit
9a1c3f7929
  1. 3
      Source/HBIOS/hbios.asm
  2. 8
      Source/HBIOS/spk.asm

3
Source/HBIOS/hbios.asm

@ -993,7 +993,8 @@ HBX_BUF_END .EQU $
.DW 0 ; HB_DSTADR: BNKCPY DESTINATION ADDRESS
.DB BID_USR ; HB_DSTBNK: BNKCPY DESTINATION BANK ID
.DW 0 ; HB_CPYLEN: BNKCPY LENGTH
.FILL 4,0 ; FILLER, RESERVED FOR FUTURE HBIOS USE
.DW 0 ; RESERVED FOR OPTIONAL TICK CTR, PLATFORM DEPENDENT
.DW 0 ; RESERVED FOR FUTURE HBIOS USE
.DB 0 ; SHADOW VALUE FOR RTC LATCH PORT
.DB $FE ; HB_LOCK: HBIOS MUTEX LOCK
JP HBX_INVOKE ; HB_INVOKE: FIXED ADR ENTRY FOR HBX_INVOKE (ALT FOR RST 08)

8
Source/HBIOS/spk.asm

@ -303,6 +303,14 @@ BE_AGAIN:
BE_END:
HB_EI
POP IX
;
; Above flow flips the speaker bit an odd number of times which
; leaves the bit set to the opposite value it started at. This
; ensures that the bit is properly reset to its original value.
;
LD A,(HB_RTCVAL) ; Get the current RTC latch value
OUT (RTCIO),A ; Set it
;
RET ; ALWAYS EXITS WITH SUCCESS STATUS (A=0)
;
;======================================================================

Loading…
Cancel
Save