sound.asm
list p=18f452
#include p18f452.inc
#define TMR0_RELOAD 0xDA
#define TMR1_RELOAD_H 0xAE
#define TMR1_RELOAD_L 0x9F
#define VBIT0 Flags,0
#define F60HZ Flags,1
var_g UDATA_ACS
Flags res 1 hCount res 1
gType res 1
gVol res 1
temp0 res 1
temp1 res 1
var_1 UDATA 0x100
hWaveSel res 1 hVol res 1
hFreq res 2
hAcc res 3
Vol res 1 Freq res 2
Effect res 1 EffInit res 1 EffD res 1 EffBaseFreq res 1 EffTable res 8 EffDuration res 1 EffType res 1
Wave res 1
WaveInit res 1
WaveD res 1
WaveBaseFreq res 1
WaveVol res 1
WaveRom res 2
WaveType res 1
Wave9 res 1
Wave4 res 1
WaveDuration res 1
WaveWSel res 1
WaveScale res 1
var_2 UDATA 0x200
Effect2 res 17
extern prom_waveform_0
extern effect_table_0
extern wave_table_0
ORG 0x0000
nop
goto main
ORG 0x0008
goto int_handler
ORG 0x0100
int_code CODE
int_handler
btfss INTCON, TMR0IF
bra int_test_1
call int_timer0
bcf INTCON, TMR0IF
int_test_1
btfss PIR1, TMR1IF
bra int_test_2
call int_timer1
bcf PIR1, TMR1IF
int_test_2
retfie FAST
int_timer0
movlw TMR0_RELOAD
movwf TMR0L
btfsc VBIT0
bra voice2 voice1
bsf VBIT0 movlb .1
movlw TMR0_RELOAD
movwf TMR0L
movf hFreq, w addwf hAcc, f
movf hFreq+1, w
addwfc hAcc+1, f
btfsc STATUS, C
incf hAcc+2, f
swapf hAcc+2, w andlw 0xF0 btfsc hAcc+1, 7 bsf WREG, 3
iorwf hWaveSel, w movwf FSR2L
movf INDF2, w
iorwf hVol, w movwf LATD
return
voice2
bcf VBIT0 movlb .2
hw_update
movf hFreq, w addwf hAcc, f
movf hFreq+1, w
addwfc hAcc+1, f
movf hAcc+1, w
andlw 0xF8 iorwf hWaveSel, w movwf FSR2L
movf INDF2, w
iorwf hVol, w movwf LATD
return
int_timer1
movlw TMR1_RELOAD_H
movwf TMR1H
movlw TMR1_RELOAD_L
movwf TMR1L
incf hCount, f bsf F60HZ
return
main_code CODE
main
clrf TRISD
clrf LATD
movlw b'11001000' movwf T0CON
movlw b'10110001' movwf T1CON
movlw TMR1_RELOAD_H
movwf TMR1H
movlw TMR1_RELOAD_L
movwf TMR1L
clrf INTCON
bsf INTCON, TMR0IE bsf INTCON, IPEN bsf PIE1, TMR1IE
clrf Flags
call copy_waveform_table lfsr FSR0, 0x100
call clear_bank
lfsr FSR0, 0x200
call clear_bank
call debug_setup
bra main_loop
debug_setup
btfss PORTC, 7
bra set_wave
set_effect
movf PORTC, w
andlw 0x1F
movwf temp1
movlb .1
movlw .3
cpfslt temp1 movlb .2
movf temp1, w
movwf Effect
bra set_done
set_wave
movf PORTC, w
andlw 0x1F
incf WREG, w
rlncf WREG, w
movlb .1
decf WREG, w
movwf Wave
movlb .2
incf WREG, w
movwf Wave
set_done
return
bsf INTCON, GIE
main_loop
btfsc F60HZ call timer_60hz
nop
goto main_loop
timer_60hz
call sound_refresh
btfsc PORTC,6
call debug_setup
bcf F60HZ
return
copy_waveform_table
clrf TBLPTRU
movlw high(prom_waveform_0)
movwf TBLPTRH
movlw low(prom_waveform_0)
movwf TBLPTRL
lfsr FSR0, 0x400 clrf temp0
cwt tblrd*+
movf TABLAT, w
movwf POSTINC0
decfsz temp0
bra cwt
lfsr FSR2, 0x400 return
clear_bank
clrf temp0
cb_1 clrf POSTINC0
decfsz temp0
bra cb_1
return
sound_refresh
movlb 0x1 call process_voice
movlb 0x2 call process_voice
return
process_voice
call process_effect movwf gVol
call process_wave tstfsz Wave movwf gVol
movf Freq, w movwf hFreq
movf Freq+1, w
movwf hFreq+1
movf EffTable, w tstfsz Wave movf WaveWSel, w andlw 0x7
movwf hWaveSel
movf gVol, w
andlw 0xf
movwf hVol
return
process_effect
tstfsz Effect bra init_effect
tstfsz EffInit bra clear_effect
retlw .0 clear_effect clrf EffInit clrf EffD
clrf EffBaseFreq
clrf Vol
clrf Freq
clrf Freq+1
retlw .0
init_effect
tstfsz EffInit bra play_effect
incf EffInit, f
movlw high(effect_table_0)
movwf TBLPTRH
movlw low(effect_table_0)
movwf TBLPTRL
decf Effect, w
rlncf WREG, w
rlncf WREG, w
rlncf WREG, w
addwf TBLPTRL, f
btfsc STATUS, C
incf TBLPTRH, f
tblrd*+
movf TABLAT, w
movwf EffTable
tblrd*+
movf TABLAT, w
movwf EffTable+1
tblrd*+
movf TABLAT, w
movwf EffTable+2
tblrd*+
movf TABLAT, w
movwf EffTable+3
tblrd*+
movf TABLAT, w
movwf EffTable+4
tblrd*+
movf TABLAT, w
movwf EffTable+5
tblrd*+
movf TABLAT, w
movwf EffTable+6
tblrd*+
movf TABLAT, w
movwf EffTable+7
movf EffTable+3, w andlw 0x7f
movwf EffDuration
movf EffTable+1, w movwf EffBaseFreq
swapf EffTable+6, w andlw 0x0F
movwf EffType
btfsc EffType, 3 bra play_effect movf EffTable+6, w
movwf Vol clrf EffD
play_effect
decfsz EffDuration bra update_freq
tstfsz EffTable+5
bra pe_1
bra pe_2
pe_1 decfsz EffTable+5 bra pe_2 clrf Effect
retlw .0
pe_2 movf EffTable+3, w andlw 0x7f
movwf EffDuration
btfss EffTable+3, 7 bra pe_4
negf EffTable+2 btfsc EffD, 0 bra pe_3
bsf EffD, 0 bra update_freq
pe_3
bcf EffD, 0
pe_4
movf EffTable+4, w
addwf EffTable+1, f
movf EffTable+1, w
movwf EffBaseFreq
movf EffTable+7, w
addwf EffTable+6, f
btfsc EffType, 3 bra update_freq
movf EffTable+6, w movwf Vol
update_freq
movf EffTable+2, w
addwf EffBaseFreq, f
movf EffTable, w
andlw 0x70
swapf WREG, w
movwf temp0
movf EffBaseFreq, w
movwf Freq
clrf Freq+1
tstfsz temp0 bra uf_1 bra uf_2 uf_1
movf Freq, w
addwf Freq, f
movf Freq+1, w
addwfc Freq+1, f decfsz temp0
bra uf_1
uf_2
movf EffType, w
movwf gType
movf Vol, w
movwf gVol
call update_volume movwf Vol
return
update_volume
movf gVol, w
tstfsz gType bra uv_1
return
uv_1 movlw .1
cpfseq gType
bra uv_2
movf gVol, w
bra uv_dec
uv_2 movlw .2
cpfseq gType
bra uv_3
movf hCount, w
andlw 0x01
uv_skip
movf gVol, w
btfss STATUS, Z
return
uv_dec
andlw 0x0f
btfsc STATUS, Z
return
decf WREG, w
return
uv_3 movlw .3
cpfseq gType
bra uv_4
movf hCount, w
andlw 0x03
bra uv_skip
uv_4 movlw .4
cpfseq gType
bra uv_other
movf hCount, w
andlw 0x07
bra uv_skip
uv_other
retlw .0
#if 0
movlw .1
cpfseq gType bra uv_3
uv_dec
movf gVol, w
andlw 0x0f btfsc STATUS, Z return
uv_2 decf WREG, w return
uv_3 movlw .2
cpfseq gType bra uv_4
movf hCount, w
andlw 0x1
btfsc STATUS,Z
bra uv_dec
movf gVol, w
return
uv_4 movlw .3
cpfseq gType bra uv_5
movf hCount, w
andlw 0x3
btfsc STATUS,Z
bra uv_dec
movf gVol, w
return
uv_5 movlw .4
cpfseq gType bra uv_6
movf hCount, w
andlw 0x7
btfsc STATUS,Z
bra uv_dec
movf gVol, w
return
uv_6 retlw .0
#endif
process_wave
tstfsz Wave bra init_wave pw_1
tstfsz WaveInit bra clear_wave
retlw .0
clear_wave
clrf WaveInit
clrf WaveD
clrf WaveBaseFreq
clrf WaveVol
clrf Freq
clrf Freq+1
retlw .0
init_wave
tstfsz WaveInit bra play_wave
incf WaveInit, f
movlw high(wave_table_0)
movwf TBLPTRH
movlw low(wave_table_0)
movwf TBLPTRL
decf Wave, w addwf WREG, w
addwf TBLPTRL, f
btfsc STATUS, C
incf TBLPTRH, f
tblrd*+
movf TABLAT, w
movwf WaveRom
tblrd*+
movf TABLAT, w
movwf WaveRom+1
pw_2
call wave_next_byte
btfss STATUS, C
bra wave_update_freq
bra pw_1
play_wave
decfsz WaveDuration bra wave_update_freq bra pw_2
wave_update_freq
movf WaveD, w
andlw 0x10
movwf WaveScale btfsc STATUS,Z bra wuf_1
movlw .1
movwf WaveScale wuf_1
addwf Wave4, w
movwf WaveScale movwf temp0
movf WaveBaseFreq, w
movwf Freq
clrf Freq+1
tstfsz temp0
bra wuf_2
bra wuf_3
wuf_2
movf Freq, w
addwf Freq, f
movf Freq+1, w
addwfc Freq+1, f
decfsz temp0
bra wuf_2
wuf_3
movf WaveType, w
movwf gType
movf WaveVol, w
movwf gVol
call update_volume
movwf WaveVol
return
wave_next_byte
movf WaveRom, w movwf TBLPTRH
movf WaveRom+1, w
movwf TBLPTRL
tblrd*+ movf TBLPTRH, w
movwf WaveRom
movf TBLPTRL, w
movwf WaveRom+1
movlw 0xf0
cpfslt TABLAT bra special_byte
movf TABLAT, w
andlw 0x1f
btfsc STATUS, Z bra wnb_1
movf TABLAT, w movwf WaveD
wnb_1
btfss WaveType, 3 bra wnb_2
clrf WaveVol bra wnb_3
wnb_2
movf Wave9, w movwf WaveVol
wnb_3
movf TABLAT, w
andlw 0xE0
rrncf WREG, w
rrncf WREG, w
rrncf WREG, w
rrncf WREG, w
rrncf WREG, w call power
movwf WaveDuration
movf TABLAT, w
andlw 0x1f
btfss STATUS, Z bra wnb_4
bcf STATUS, C return
wnb_4
movf TABLAT, w
andlw 0x0f
call get_freq_table
movwf WaveBaseFreq bcf STATUS, C
return
special_byte
movlw 0xf0
cpfseq TABLAT bra sb_1
tblrd*+
movf TABLAT, w
movwf WaveRom
tblrd*
movf TABLAT, w
movwf WaveRom+1 bra wave_next_byte
sb_1
movlw 0xf1 cpfseq TABLAT
bra sb_2
call next_byte
movwf WaveWSel bra wave_next_byte
sb_2
movlw 0xf2 cpfseq TABLAT
bra sb_3
call next_byte
movwf Wave4 bra wave_next_byte
sb_3
movlw 0xf3 cpfseq TABLAT
bra sb_4
call next_byte
movwf Wave9 bra wave_next_byte
sb_4
movlw 0xf4 cpfseq TABLAT
bra sb_5
call next_byte
movwf WaveType bra wave_next_byte
sb_5
movlw 0xff cpfseq TABLAT
bra sb_6
clrf Wave bsf STATUS, C return
sb_6
bra wave_next_byte
next_byte
tblrd*+ movf TABLAT, w
movwf temp0 movf TBLPTRH, w
movwf WaveRom
movf TBLPTRL, w
movwf WaveRom+1 movf temp0, w return
power
movwf temp0
incf temp0
movlw .1
bra pow2
pow1 rlncf WREG, w
pow2 decfsz temp0
bra pow1
return
get_freq_table
movwf temp0 bcf STATUS, C
rlcf temp0 movlw high(freq_table)
btfsc STATUS, C
incf WREG, w
movwf PCLATH
movlw low(freq_table)
addwf temp0, w
btfsc STATUS, C
incf PCLATH, f
movwf PCL
freq_table
retlw 0x00 retlw 0x57
retlw 0x5c
retlw 0x61
retlw 0x67
retlw 0x6d
retlw 0x74
retlw 0x7b
retlw 0x82
retlw 0x8a
retlw 0x92
retlw 0x9a
retlw 0xa3
retlw 0xad
retlw 0xb8
retlw 0xc3
END
waveform_code CODE 0x1000
prom_waveform_0
GLOBAL prom_waveform_0
db 0x70, 0x70, 0x70, 0x70, 0x00, 0x70, 0x00, 0x00
db 0x90, 0xc0, 0xa0, 0xd0, 0x80, 0x80, 0x10, 0x10
db 0xa0, 0xe0, 0xc0, 0xb0, 0xf0, 0x60, 0x20, 0x20
db 0xb0, 0xe0, 0xd0, 0x80, 0x70, 0x90, 0x30, 0x30
db 0xc0, 0xd0, 0xe0, 0xb0, 0x10, 0x50, 0x40, 0x40
db 0xd0, 0xb0, 0xd0, 0xd0, 0x80, 0xa0, 0x50, 0x50
db 0xd0, 0x90, 0xc0, 0x90, 0xe0, 0x40, 0x60, 0x60
db 0xe0, 0xa0, 0xa0, 0x60, 0x70, 0xb0, 0x70, 0x70
db 0xe0, 0xb0, 0x70, 0xb0, 0x20, 0x30, 0x80, 0x80
db 0xe0, 0xb0, 0x40, 0xe0, 0x80, 0xc0, 0x90, 0x90
db 0xd0, 0xa0, 0x20, 0xc0, 0xd0, 0x20, 0xa0, 0xa0
db 0xd0, 0x90, 0x10, 0x70, 0x70, 0xd0, 0xb0, 0xb0
db 0xc0, 0x60, 0x00, 0x90, 0x30, 0x10, 0xc0, 0xc0
db 0xb0, 0x40, 0x10, 0xa0, 0x80, 0xe0, 0xd0, 0xd0
db 0xa0, 0x30, 0x20, 0x60, 0xc0, 0x00, 0xe0, 0xe0
db 0x90, 0x50, 0x40, 0x20, 0x70, 0xf0, 0xf0, 0xf0
db 0x70, 0x70, 0x70, 0x70, 0x40, 0x00, 0xf0, 0x00
db 0x50, 0x90, 0xb0, 0xc0, 0x80, 0xf0, 0xe0, 0x10
db 0x40, 0xb0, 0xd0, 0x80, 0xb0, 0x10, 0xd0, 0x20
db 0x30, 0xa0, 0xe0, 0x40, 0x70, 0xe0, 0xc0, 0x30
db 0x20, 0x80, 0xd0, 0x50, 0x50, 0x20, 0xb0, 0x40
db 0x10, 0x50, 0xb0, 0x70, 0x80, 0xd0, 0xa0, 0x50
db 0x10, 0x40, 0x70, 0x20, 0xa0, 0x30, 0x90, 0x60
db 0x00, 0x30, 0x30, 0x00, 0x70, 0xc0, 0x80, 0x70
db 0x00, 0x30, 0x10, 0x30, 0x60, 0x40, 0x70, 0x80
db 0x00, 0x40, 0x00, 0x80, 0x80, 0xb0, 0x60, 0x90
db 0x10, 0x50, 0x10, 0x50, 0x90, 0x50, 0x50, 0xa0
db 0x10, 0x30, 0x30, 0x10, 0x70, 0xa0, 0x40, 0xb0
db 0x20, 0x10, 0x70, 0x30, 0x70, 0x60, 0x30, 0xc0
db 0x30, 0x00, 0xe0, 0x60, 0x80, 0x90, 0x20, 0xd0
db 0x40, 0x00, 0x70, 0x30, 0x80, 0x70, 0x10, 0xe0
db 0x50, 0x20, 0x00, 0x10, 0x70, 0x80, 0x00, 0xf0
effect_table_0
GLOBAL effect_table_0
db 0x73, 0x20, 0x00, 0x0C, 0x00, 0x0A, 0x1f, 0x00
db 0x72, 0x20, 0xfb, 0x87, 0x00, 0x02, 0x0f, 0x00
db 0x1c, 0x70, 0x8b, 0x08, 0x00, 0x01, 0x06, 0x00
db 0x56, 0x0c, 0xff, 0x8c, 0x00, 0x02, 0x08, 0x00
db 0x56, 0x00, 0x02, 0x0a, 0x07, 0x03, 0x0c, 0x00
db 0x36, 0x38, 0xfe, 0x12, 0xf8, 0x04, 0x0f, 0xfc
db 0x22, 0x01, 0x01, 0x06, 0x00, 0x01, 0x07, 0x00
db 0x59, 0x01, 0x06, 0x08, 0x00, 0x00, 0x02, 0x00
db 0x59, 0x01, 0x06, 0x09, 0x00, 0x00, 0x02, 0x00
db 0x59, 0x02, 0x06, 0x0a, 0x00, 0x00, 0x02, 0x00
db 0x59, 0x03, 0x06, 0x0b, 0x00, 0x00, 0x02, 0x00
db 0x59, 0x04, 0x06, 0x0c, 0x00, 0x06, 0x02, 0x00
db 0x24, 0x00, 0x06, 0x08, 0x02, 0x00, 0x0a, 0x00
db 0x36, 0x07, 0x87, 0x6f, 0x00, 0x00, 0x04, 0x00
db 0x42, 0x18, 0xfd, 0x06, 0x00, 0x01, 0x0c, 0x00
db 0x42, 0x04, 0x03, 0x06, 0x00, 0x01, 0x0c, 0x00
db 0x56, 0x0c, 0xff, 0x8c, 0x00, 0x02, 0x0f, 0x00
db 0x05, 0x00, 0x02, 0x20, 0x00, 0x01, 0x0c, 0x00
db 0x41, 0x20, 0xff, 0x86, 0xfe, 0x1c, 0x0f, 0xff
db 0x70, 0x00, 0x01, 0x0c, 0x00, 0x01, 0x08, 0x00
wave_table_0
GLOBAL wave_table_0
db high(pac_start_1), low(pac_start_1)
db high(pac_start_2), low(pac_start_2)
db high(mspac_start_1), low(mspac_start_1)
db high(mspac_start_2), low(mspac_start_2)
db high(pac_act_1), low(pac_act_1)
db high(pac_act_2), low(pac_act_2)
db high(mspac_act1_1), low(mspac_act1_1)
db high(mspac_act1_2), low(mspac_act1_2)
db high(mspac_act2_1), low(mspac_act2_1)
db high(mspac_act2_2), low(mspac_act2_2)
db high(mspac_act3_1), low(mspac_act3_1)
db high(mspac_act3_2), low(mspac_act3_2)
pac_start_1
db 0xf1, 0x02, 0xf2, 0x03, 0xf3, 0x0f, 0xf4, 0x01
db 0x82, 0x70, 0x69, 0x82, 0x70, 0x69, 0x83, 0x70
db 0x6a, 0x83, 0x70, 0x6a, 0x82, 0x70, 0x69, 0x82
db 0x70, 0x69, 0x89, 0x8b, 0x8d, 0x8e, 0xff
pac_start_2
db 0xf1, 0x00, 0xf2, 0x02, 0xf3, 0x0f, 0xf4, 0x00
db 0x42, 0x50, 0x4e, 0x50, 0x49, 0x50, 0x46, 0x50
db 0x4e, 0x49, 0x70, 0x66, 0x70, 0x43, 0x50, 0x4f
db 0x50, 0x4a, 0x50, 0x47, 0x50, 0x4f, 0x4a, 0x70
db 0x67, 0x70, 0x42, 0x50, 0x4e, 0x50, 0x49, 0x50
db 0x46, 0x50, 0x4e, 0x49, 0x70, 0x66, 0x70, 0x45
db 0x46, 0x47, 0x50, 0x47, 0x48, 0x49, 0x50, 0x49
db 0x4a, 0x4b, 0x50, 0x6e, 0xff
pac_act_1
db 0xf1, 0x02, 0xf2, 0x03, 0xf3, 0x0f, 0xf4, 0x01
pac_act_1_loop
db 0x67, 0x50, 0x30, 0x47, 0x30, 0x67, 0x50, 0x30
db 0x47, 0x30, 0x67, 0x50, 0x30, 0x47, 0x30, 0x4b
db 0x10, 0x4c, 0x10, 0x4d, 0x10, 0x4e, 0x10, 0x67
db 0x50, 0x30, 0x47, 0x30, 0x67, 0x50, 0x30, 0x47
db 0x30, 0x67, 0x50, 0x30, 0x47, 0x30, 0x4b, 0x10
db 0x4c, 0x10, 0x4d, 0x10, 0x4e, 0x10, 0x67, 0x50
db 0x30, 0x47, 0x30, 0x67, 0x50, 0x30, 0x47, 0x30
db 0x67, 0x50, 0x30, 0x47, 0x30, 0x4b, 0x10, 0x4c
db 0x10, 0x4d, 0x10, 0x4e, 0x10, 0x77, 0x20, 0x4e
db 0x10, 0x4d, 0x10, 0x4c, 0x10, 0x4a, 0x10, 0x47
db 0x10, 0x46, 0x10, 0x65, 0x30, 0x66, 0x30, 0x67
db 0x40, 0x70, 0xf0, high(pac_act_1_loop)
db low(pac_act_1_loop)
pac_act_2
db 0xf1, 0x01, 0xf2, 0x01, 0xf3, 0x0f, 0xf4, 0x00
pac_act_2_loop
db 0x26, 0x67, 0x26, 0x67, 0x26, 0x67, 0x23, 0x44
db 0x42, 0x47, 0x30, 0x67, 0x2a, 0x8b, 0x70, 0x26
db 0x67, 0x26, 0x67, 0x26, 0x67, 0x23, 0x44, 0x42
db 0x47, 0x30, 0x67, 0x23, 0x84, 0x70, 0x26, 0x67
db 0x26, 0x67, 0x26, 0x67, 0x23, 0x44, 0x42, 0x47
db 0x30, 0x67, 0x29, 0x6a, 0x2b, 0x6c, 0x30, 0x2c
db 0x6d, 0x40, 0x2b, 0x6c, 0x29, 0x6a, 0x67, 0x20
db 0x29, 0x6a, 0x40, 0x26, 0x87, 0x70
db 0xf0, high(pac_act_2_loop), low(pac_act_2_loop)
mspac_start_1
db 0xf1, 0x02, 0xf2, 0x03, 0xf3, 0x0a, 0xf4, 0x00
db 0x50, 0x70, 0x86, 0x90, 0x81, 0x90, 0x86, 0x90
db 0x68, 0x6a, 0x6b, 0x68, 0x6a, 0x68, 0x66, 0x6a
db 0x68, 0x66, 0x65, 0x68, 0x86, 0x81, 0x86, 0xff
mspac_start_2
db 0xf1, 0x00, 0xf2, 0x02, 0xf3, 0x0a, 0xf4, 0x00
db 0x41, 0x43, 0x45, 0x86, 0x8a, 0x88, 0x8b, 0x6a
db 0x6b, 0x71, 0x6a, 0x88, 0x8b, 0x6a, 0x6b, 0x71
db 0x6a, 0x6b, 0x71, 0x73, 0x75, 0x96, 0x95, 0x96
db 0xff
mspac_act1_1
db 0xf1, 0x03, 0xf2, 0x03, 0xf3, 0x0a, 0xf4, 0x02
db 0x70, 0x66, 0x70, 0x46, 0x50, 0x86, 0x90, 0x70
db 0x66, 0x70, 0x46, 0x50, 0x86, 0x90, 0x70, 0x66
db 0x70, 0x46, 0x50, 0x86, 0x90, 0x70, 0x61, 0x70
db 0x41, 0x50, 0x81, 0x90, 0xf4, 0x00, 0xa6, 0xa4
db 0xa2, 0xa1, 0xf4, 0x01, 0x86, 0x89, 0x8b, 0x81
db 0x74, 0x71, 0x6b, 0x69, 0xa6, 0xff
mspac_act1_2
db 0xf1, 0x00, 0xf2, 0x02, 0xf3, 0x0a, 0xf4, 0x00
db 0x69, 0x6b, 0x69, 0x86, 0x61, 0x64, 0x65, 0x86
db 0x86, 0x64, 0x66, 0x64, 0x61, 0x69, 0x6b, 0x69
db 0x86, 0x61, 0x64, 0x64, 0xa1, 0x70, 0x71, 0x74
db 0x75, 0x35, 0x76, 0x30, 0x50, 0x35, 0x76, 0x30
db 0x50, 0x54, 0x56, 0x54, 0x51, 0x6b, 0x69, 0x6b
db 0x69, 0x6b, 0x91, 0x6b, 0x69, 0x66, 0xf2, 0x01
db 0x74, 0x76, 0x74, 0x71, 0x74, 0x71, 0x6b, 0x69
db 0xa6, 0xa6, 0xff
mspac_act2_1
db 0xf1, 0x03, 0xf2, 0x03, 0xf3, 0x0a, 0xf4, 0x02
db 0x90, 0x7c, 0x7b, 0x7a, 0x79, 0x79, 0x78, 0x97
db 0x76, 0x75, 0x74, 0x73, 0x73, 0x72, 0x91, 0xa8
db 0x88, 0x60, 0x4a, 0x4c, 0x91, 0x95, 0x88, 0x95
db 0x91, 0x95, 0x88, 0x95, 0x91, 0x95, 0x88, 0x95
db 0x95, 0x98, 0x94, 0x97, 0x93, 0x96, 0x88, 0x96
db 0x93, 0x96, 0x88, 0x96, 0x93, 0x96, 0x88, 0x96
db 0xb6, 0xb3, 0x75, 0x76, 0x77, 0x78, 0x78, 0x75
db 0x73, 0x68, 0x91, 0x95, 0x88, 0x95, 0x91, 0x95
db 0x88, 0x95, 0x86, 0x96, 0x95, 0x92, 0x93, 0x8c
db 0x8a, 0x88, 0x86, 0x90, 0x90, 0x96, 0x95, 0x90
db 0x90, 0x86, 0x90, 0x96, 0x90, 0x96, 0x91, 0x88
db 0x81, 0xff
mspac_act2_2
db 0xf1, 0x00, 0xf2, 0x02, 0xf3, 0x0a, 0xf4, 0x00
db 0x88, 0x6c, 0x71, 0x72, 0x73, 0x73, 0x71, 0x93
db 0x6c, 0x73, 0x75, 0x76, 0x76, 0x75, 0x96, 0x7c
db 0x7a, 0x78, 0x76, 0x75, 0x96, 0x6c, 0x91, 0xa0
db 0x88, 0x75, 0x76, 0x77, 0x78, 0x71, 0x73, 0x74
db 0x75, 0x71, 0x75, 0x71, 0x68, 0x68, 0x65, 0x66
db 0x67, 0xa8, 0xab, 0xac, 0x8c, 0x86, 0x76, 0x75
db 0x6c, 0x71, 0x75, 0x73, 0x6b, 0x6c, 0x73, 0x76
db 0x7a, 0x78, 0x78, 0x76, 0x73, 0x6c, 0xaa, 0xa8
db 0x71, 0x73, 0x74, 0x75, 0x6a, 0x6b, 0x6c, 0x73
db 0x75, 0x76, 0x77, 0x78, 0x71, 0x73, 0x74, 0x75
db 0x71, 0x75, 0x71, 0x68, 0x48, 0x40, 0x68, 0x67
db 0x68, 0xaa, 0xa9, 0xaa, 0x6a, 0x60, 0x8a, 0x76
db 0x75, 0x73, 0x71, 0x71, 0x73, 0x95, 0x75, 0x73
db 0x71, 0x68, 0x68, 0x61, 0x63, 0x6a, 0xa8, 0x6c
db 0x76, 0x6a, 0x6c, 0x91, 0x90, 0x91, 0xff
mspac_act3_1
db 0xf1, 0x02, 0xf2, 0x03, 0xf3, 0x0a, 0xf4, 0x02
db 0x65, 0x90, 0x68, 0x70, 0x68, 0x67, 0x66, 0x65
db 0x90, 0x61, 0x70, 0x61, 0x65, 0x68, 0x66, 0x90
db 0x63, 0x90, 0x86, 0x90, 0x85, 0x90, 0x85, 0x70
db 0x86, 0x68, 0x65, 0xff
mspac_act3_2
db 0xf1, 0x00, 0xf2, 0x02, 0xf3, 0x0a, 0xf4, 0x00
db 0x65, 0x64, 0x65, 0x88, 0x67, 0x88, 0x61, 0x63
db 0x64, 0x85, 0x64, 0x85, 0x6a, 0x69, 0x6a, 0x8c
db 0x75, 0x93, 0x90, 0x91, 0x90, 0x91, 0x70, 0x8a
db 0x68, 0x71, 0xff
END