TRACKERS MB SRC EN LOADER
From MSX MUSIC WIKI
*q-,u+ db 0feh dw start dw einde dw start org 0e000h sngpag equ 1 edtpag equ 2 dskpag equ 3 em1pag equ 4 em2pag equ 5 vocpag equ 6 smppag equ 7 xpos equ 08000h ;->in song only 200 long! xleng equ xpos+200 ;->last position. xuser1 equ xleng+1 ;->user code # 1. xmmvoc equ xuser1+2 ;->module instruments. xmmsti equ xmmvoc+16*9 ;->instrument module. xpasti equ xmmsti+16 ;->instruments / volumes pac. xstpr equ xpasti+32 ;->stereo settings. xtempo equ xstpr+10 ;->starting pace. xsust equ xtempo+1 ;->modulation depth. xnaam equ xsust+1 ;->song name. xchip equ xnaam+40 ;->preferred chip. xbegvm equ xchip+1 ;->initial instrument module. xbegvp equ xbegvm+9 ;->initial instruments pac. xorgp1 equ xbegvp+9 ;->data from software voices pac. xorgnr equ xorgp1+6*8 ;->numbers of software voices. xsmpkt equ xorgnr+6 ;->sample kit name. xdrblk equ xsmpkt+8 ;->pac drum blocks. xdrvol equ xdrblk+15 ;->volumes drum pac. xdrfrq equ xdrvol+3 ;->frequencies drum pac. xuser2 equ xdrfrq+3*6 ;->user code # 2 (= 1 on with other codes). xrever equ xuser2+2 ;->reverb settings. xloop equ xrever+9 ;->loop position. xbegmd equ 08240h ownvdt equ 0c400h+176*25 smpnr equ 0f975h loaded equ 0f976h notvcm equ 0f977h notvcp equ 0f977h+9 smpadr equ notvcp+9 smknam equ smpadr+56 vcenr equ smknam+8 fkndat equ vcenr+1 keybdt equ fkndat+1 midint equ keybdt+1 ;0=musmod 1=turbo-r 2=vak usrdat equ midint+1 us2dat equ usrdat+2 naudat equ us2dat+2 scandt equ naudat+1 subs equ 0d900h subs2 equ 0d914h subs3 equ 0d928h decdat equ 0c000h dosprog equ 1=0 grpprog equ 1=0 include mybios start: xor a ld (0f3dbh),a ;@ ;key click off ld a,1 ld (smpnr),a ld a,1 ld (midint),a ld (fkndat),a ld (keybdt),a ld hl,0 ;@ ld (0f3eah),hl ;@ ld a,15 ;@ ld (0f3e9h),a ;@ bios 062h ;@ width 80 fkeyoff ld a,011110000b out (099h),a ld a,13+128 out (099h),a ld a,0100011b out (099h),a ld a,12+128 out (099h),a ; vdpreg 13,011110000B ; vdpreg 12,0100011B call wiscol ld a,2 ld de,07006h call change_color ld a,3 ld de,05000h call change_color ld a,edtpag ld hl,fil1 call load2 ld a,vocpag ld hl,fil2 call load2 ld a,dskpag ld hl,fil3 call load2 ld a,smppag ld hl,fil4 call load2 ld a,sngpag ld hl,fil5 call load2 ld hl,fil8 call load ld hl,fil6 call load ld hl,fil7 call load jp 0d93dh load2: out (0feh),a load: ld de,fcbsav+1 ld bc,11 ldir ld de,fcbsav bdos open ;open the file ld hl,1 ld (groot),hl ;blok size = 1 dec hl ld (blok),hl ld (blok+2),hl ;blok number = 0 ld de,0f975h bdos setdma ld hl,7 ld de,fcbsav bdos read ld de,(0f976h) bdos setdma ld hl,(bleng) ld de,-7 add hl,de ld de,fcbsav bdos read ;read file ld de,fcbsav bdos close ret wiscol: ld hl,0800h ld bc,256 xor a bios 016bh ret change_color: out (099h),a ld a,090h out (099h),a ld a,d out (09ah),a ld a,e out (09ah),a ret fcbsav: db 0," " dw 0 groot: dw 0 bleng: dw 0 db 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 blok: dw 0 dw 0 fil1: db "MOONBLASCOM" fil2: db "VOICMENUCOM" fil3: db "DISKMENUCOM" fil4: db "SAMPLER COM" fil5: db "EXAMPDATCOM" fil6: db "VOICES COM" fil7: db "INSTALL COM" fil8: db "DECDAT COM" einde: end