;---------------------------------------------------------------------- ; HFIRQ - Hard Disk Format Index/Time-out Interrupt Routine (15_Aug_84) ;---------------------------------------------------------------------- ; HFirq1: inc sp inc sp ;Pull the return address off of the stack in a,(clrint) ;Clear the Interrupts in a,(cstat) ;If (the motor has timed out) and $MTR ld a,Eto ; load motor-time-out failure jr z,HFsk1 HFsk1: dec b ;Else Revs_Count:= Revs_Count - 1 jr z,HFsk3 ; If (the revs count is NOT zero) push hl ld hl,HFirq2 ld (HDIvct),hl ; Index_Irq_Vect:= Format entry 2 pop hl ei ; Re:enable the interrupts jp prebuf ; Wait for Second Interrupt HFsk2: ld (error),a ;Update the error code Hfsk3: jp Hdone ;Goto return location HFirq2: in a,(clrint) ;Clear the Interrupts ei ;Enable Interrupts jp nz,PreBuf+7 ;If (1st Entry Here) Begin Formatting pop de ;Pull 1st Irq Return from stack pop de ; " 2nd " " " " jp Hdone ;Return to calling routine page