playing samples on msx (Development Foros MSX)MSX Resource Center PassionMSX MSX2 contest           
                       
English Nederlands Español Português Russian                  
 Noticias
   Página principal
  Almacén de noticias
  Temas de noticias

 Recursos
   Foros MSX
  Artículos
  Analisis
  Informe de ferias/RUs
  Álbum de fotos
  Ferias y encuentros
  Encuestas
  Enlaces
  Buscar

 Software
   Descargas
  Tienda Online

 MRC
   Quiénes somos
  Únete a nuestro equipo
  Donar
  Políticas
  Contacta con nosotros
  Enlázanos
  Estadísticas

 Buscar
 
  

  

 Login
 

Login

Contraseña




¿Aún no tienes una cuenta? ¡Conviértete en miembro del MSX Resource Center! ¡Únete a nosotros!.


 Estadísticas
 

Hay 127 invitados y 1 miembro en línea

Eres un usuario anónimo.
 

Foros MSX


Foros MSX

Development - playing samples on msx

Ir a la página ( Página anterior 1 | 2 | 3 )
Autor

playing samples on msx

NYYRIKKI
msx master
Mensajes: 1509
Publicado: Septiembre 10 2005, 12:38   

> Do the HR bit in the VDP work also during in the Vblank and the border tracing?

Yes

> What is the HR frequency?

I'm not sure, but I think it is 15625Hz

> What is the RTC on the MSX2

RP-5C01.

> , how does it work??

It is connected to I/O ports #B4 (register select) and #B5 (data)
You can also use it trough MSX2 SUB-ROM calls REDCLK (01F5H) and WRTCLK (01F9H)

> What is its resolution?

Normally it is 1Hz (second) , but using test register you can make it run on 16384Hz speed.

ARTRAG
msx master
Mensajes: 1681
Publicado: Septiembre 10 2005, 13:39   
about RP-5C01,
Do you have datails about the register meaning ?
HansO
msx addict
Mensajes: 375
Publicado: Septiembre 10 2005, 15:04   
The datasheet is here: http://www.hansotten.com MSX Hardware Info - MSX Chips
It is not a complicated circuit.
NYYRIKKI
msx master
Mensajes: 1509
Publicado: Septiembre 10 2005, 16:00   
manuel
msx guru
Mensajes: 3447
Publicado: Septiembre 10 2005, 20:34   
NYYRIKKI: please join the #openMSX irc channel, we'd like you to test the fixed SCC emulation
ARTRAG
msx master
Mensajes: 1681
Publicado: Septiembre 10 2005, 21:05   
About RP5C01, the manufacturer had discontinued the product,
The only manual I have found is obout the pin-out.
Does anyone have some examples of code for programming the
RP5C01 in oder to read the 16KHz timing?

kuuno
msx lover
Mensajes: 125
Publicado: Septiembre 10 2005, 23:30   
If you are intrested...
Back in the old days a tallented friend of mine wrote a sample player for the MSX.
He used Amiga samples and converted them to a file format that the MSX could read.
The player loaded the sample into the MSX ram and could be played by using plain basic code.
If you are intrested I could try to find the code on one of the many disc's.

just let me know...
ARTRAG
msx master
Mensajes: 1681
Publicado: Septiembre 11 2005, 01:00   
I am very interested, I did something with files in wav format using the PSG
but I had many problems with external timing and with the simultaneous
use of tree channels and I still am looking for ways to improve the player

NYYRIKKI
msx master
Mensajes: 1509
Publicado: Septiembre 11 2005, 19:38   
I got some new information about SCC. It has this "Deformation register" that can be used to syncronize the sample. This register is not used even by Konami, so documentation about this was pretty hard to find.

Here is example about SCC method1, that can be very usefull when you want to play samples at background. Using this method, you should be able to update the sample memory on VDP lineinterrupts. Timing is anyway very hard to get right.


;------------------------------------

SLOT:	EQU #1

	DEFB #FE
	DEFW BEGIN
	DEFW END
	DEFW BEGIN

	ORG #D000


BEGIN:

	LD HL,PLAY
	LD (#F39A),HL

INIT:
	LD A,SLOT
	LD H,#80
	CALL #24

	XOR A
	LD (#BFFF),A	; Select SCC emulation in case of SCC+

	LD A,#3F
	LD (#9000),A	; Select SCC page from mapper

	LD HL,0
	LD (#9880),HL	; Set frequency to 0

	LD A,15
	LD (#988A),A	; Set volume to 15

	LD A,1
	LD (#988F),A	; Enable first channel.

	LD HL,#98E0	; Search Deformation register
	LD A,#A5	; Dummy data
	LD (#9860),A
	LD BC,(#98A0)
	CP C
	JR NZ,NORMALSCC
	DEC L		; SCC+
NORMALSCC:
	LD (HL),32	; Set sample to start from beginning
	RET


PLAY:
	DI

	LD	HL,#C000
	LD	DE,#9800
	LD	B,#20
CONVLOOP1:
	LD	A,(HL)
	XOR	128		;Convert to signed
	LD	(DE),A
	INC	HL
	INC	DE
	DJNZ CONVLOOP1

	LD	BC,#382 	;Frequency
	LD	(#9880),BC

PLAYLOOP:

	LD BC,#3C6
WAIT:	DEC BC
	LD A,B
	OR C
	JP NZ,WAIT

	LD DE,#9800
	LD B,#20

CONVLOOP2:
	LD A,(HL)
	XOR 128 	    ;Convert to signed
	LD (DE),A
	INC HL
	INC DE
	DJNZ CONVLOOP2

	LD A,H
	CP #D0
	JP NZ,PLAYLOOP

	LD HL,0
	LD (#9880),HL
	RET

END:

;------------------------------------------------------------------------


Here is variation about method3. Now it uses sample restart feature and is much faster to use.


;------------------------------------

SLOT:	EQU #1

	DEFB #FE
	DEFW BEGIN
	DEFW END
	DEFW BEGIN

	ORG #D000

BEGIN:

	LD HL,PLAY
	LD (#F39A),HL
INIT:
	LD A,SLOT
	LD H,#80
	CALL #24

	XOR A
	LD (#BFFF),A	; Select SCC emulation in case of SCC+

	LD A,#3F
	LD (#9000),A	; Select SCC page from mapper

	LD HL,0
	LD (#9880),HL	; Set frequency to 0

	LD A,15
	LD (#988A),A	; Set volume to 15

	LD A,1
	LD (#988F),A	; Enable first channel.

	LD HL,#98E0	; Search Deformation register
	LD A,#A5	; Dummy data
	LD (#9800),A
	LD BC,(#98A0)
	CP C
	JR NZ,NORMALSCC
	DEC L		; SCC+
NORMALSCC:
	LD (HL),32	; Set sample to start from beginning
	RET


PLAY:
	DI
	LD	HL,#9881
	LD	DE,0C000H
	LD	BC,1000H
PLAYLOOP:
	LD	A,(DE)
	XOR	128	 ; Convert to signed data
	INC	DE
	LD 	(#9800),A
	LD	(HL),#FF ; Output sample data from #9800
	LD	(HL),0	 ; Stop sample playing

	EXX
	LD B,58
WAIT:	DJNZ WAIT

	EXX

	DEC	BC
	LD	A,B
	OR	C
	JP	NZ,PLAYLOOP
	RET

END:

;------------------------------------------------------------------------

NYYRIKKI
msx master
Mensajes: 1509
Publicado: Septiembre 11 2005, 21:47   

There is bug in first routine:
	LD A,#A5	; Dummy data
	LD (#9800),A

should be...
	LD A,#A5	; Dummy data
	LD (#9860),A

[D-Tail]

msx guru
Mensajes: 3015
Publicado: Septiembre 11 2005, 23:42   
It's fixed, as a special service to the non-reading copy&pasters ;-)
 
Ir a la página ( Página anterior 1 | 2 | 3 )
 







(c) 1994 - 2008 Fundación MSX Resource Center. MSX es una marca registrada de MSX Licensing Corporation