Here you have the original pack:
http://www.geocities.com/dioniso072/PT3_asMSX.zipreplace code.rob.txt with:
.START Comienzo_Programa
PT3_Stop .equ $c014
PT3_Init .equ $c020
PT3_Play .equ $c472
SCCSLOT EQU $E840 ;DB SLOT DEL SCC
SCC_REG EQU $9880 ;SCC ADDRESS FUNCTION
AYREGS EQU $C663
Comienzo_fichero:
.incbin "pt3play.bin" ;PLAYER PT3 PARA MSX
PT3_Song:
.incbin "ijones.pt3" ;INCLUYE AQUI TU PT3
WAVESSCC:
.INCBIN "WAVES.SCC" ;ARCHIVO DE ONDAS LONGITUD 4X$20
Comienzo_Programa:
DI
CALL DETECTSCC ;DETECTA EL SCC **** PROVISIONAL
LD DE,$9800 ;COPIA ONDAS A LA TABLA
LD HL,WAVESSCC
LD BC,$20*4
LDIR
LD HL,Comienzo_fichero ;SITUA EL PLAYER $C000
LD DE,$C000
LD BC,WAVESSCC-Comienzo_fichero
LDIR
;PARCHEA EL PLAYER
LD A,$CD ;OPCODE CALL
LD [$C566],A
LD HL,ROUT
LD [$C567],HL
LD A,$C9 ;OPCODE RET
LD [$C569],A
EI
halt
ld hl,PT3_Song
call PT3_Init ;Inicializamos
Main_Loop:
halt
call PT3_Play
xor a
call $00d8 ;Espacio pulsado?
or a
jp z,Main_Loop ;No=Volvemos a Main_Loop
call PT3_Stop ;Apagamos los 3 canales del PSG.
ret ;Y salimos.
Fin_Fichero:
;VIENE DE PT3PLAY
ROUT: LD HL,AYREGS ;REPRODUCE SONIDO EN PSG
LOUT: OUT [C],A
INC C
OUTI
DEC C
INC A
CP 13
JR NZ,LOUT
OUT [C],A
LD A,[HL]
AND A
JP M,SCCOUT
INC C
OUT [C],A
;CLONA SONIDO AL SCC
;CANALES PSG SCC
; A 1+4
; B 2+5
; C 3
SCCOUT: ;FRECUENCIA
LD HL,[AYREGS+0] ;REPRODUCE SONIDO EN SCC
LD [SCC_REG+0],HL
DEC HL ;CHORUS EN CANAL 4 OPCIONAL
LD [SCC_REG+6],HL ;*
LD HL,[AYREGS+2]
LD [SCC_REG+2],HL
DEC HL ;CHORUS EN CANAL 5 OPCIONAL
DEC HL
LD [SCC_REG+8],HL ;*
LD HL,[AYREGS+4]
LD [SCC_REG+4],HL
;VOLUMEN
LD A,[AYREGS+8]
LD [SCC_REG+$0A],A
LD [SCC_REG+$0D],A
LD A,[AYREGS+9]
LD [SCC_REG+$0B],A
LD [SCC_REG+$0E],A
LD A,[AYREGS+10]
LD [SCC_REG+$0C],A
RET
;DETECTA SCC **** PROVISIONAL
DETECTSCC: LD BC,$0400
LD HL,$FCC1
JC3B8: PUSH BC
PUSH HL
LD A,[HL]
BIT 7,A
JR NZ,JC3C5
LD A,C
CALL JC3E5
JR JC3C8
JC3C5: CALL JC3D5
JC3C8: POP HL
POP BC
RET C
INC HL
INC C
DJNZ JC3B8
LD A,$FF
LD [SCCSLOT],A
RET
JC3D5: AND $80
OR C
LD B,04
JC3DA: PUSH BC
CALL JC3E5
POP BC
RET C
ADD A,$04
DJNZ JC3DA
RET
JC3E5: LD [SCCSLOT],A
CALL JC401
;PUSH AF ;SOLO SI HAY DISCO
;LD A,[$F342]
;LD H,$80
;CALL $0024
;POP AF
JR NC,JC3FC
LD A,[SCCSLOT]
SCF
RET
JC3FC: LD A,[SCCSLOT]
AND A
RET
JC401: LD H,$80
CALL $0024
LD A,02
LD [$9000],A
CALL JC415
JR C,JC420
LD A,$3F
LD [$9000],A
JC415: LD HL,$9800
LD A,[HL]
CPL
LD [HL],A
CP [HL]
JR NZ,JC420
SCF
RET
JC420: OR A
RET
You will find attached an example WAVE.SCC file, any way you can create/rip your own one.
This code needs no improve the SCC searching rutine.