mirror of
https://frontier.innolan.net/github/AmigaExamples.git
synced 2026-09-13 20:01:18 +00:00
Refactored slideshow example
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
xdef LoadDiskData
|
||||
|
||||
LoadDiskData:
|
||||
;; a0 - destination address
|
||||
;; a1 - start address
|
||||
;; d0 - size
|
||||
movem.l d0-a6,-(sp)
|
||||
lea $dff002,a6 ; LoadMFMB uses this custom base addr
|
||||
|
||||
move.l d0,d1
|
||||
|
||||
move.l a1,d0
|
||||
move.l #startCode,d2
|
||||
sub.l d2,d0 ; offset from start of this module
|
||||
lsr.l #6,d0 ; bytes -> sectors
|
||||
lsr.l #3,d0
|
||||
add.l #2,d0 ; offset for bootblock
|
||||
|
||||
|
||||
add.l #512,d1
|
||||
lsr.l #6,d1 ; bytes -> sectors
|
||||
lsr.l #3,d1
|
||||
neg.w d1
|
||||
jsr LoadMFMB ; load the data!
|
||||
|
||||
movem.l (sp)+,d0-a6
|
||||
rts
|
||||
Reference in New Issue
Block a user