First steps with MSX-Music

ページ 2/3
1 | | 3


Enlighted (5880)


11-08-2020, 10:02

Briqunullus wrote:

Just wondering. Because of that detection routine, even clones wouldn't work in an I/O only slot, would they?

Yes, technically clones work just fine on I/O slots as they don't need to be activated first, but usually detection routines search "PAC2OPLL" / "APRLOPLL" ID-string from ROM and if they can't find it they likely switch to PSG music instead.

By Metalion

Paragon (1446)

Metalion さんの画像

11-08-2020, 10:32

Grauw wrote:

If you detect an FM-PAC, you need to set bit 0 of address #7FF6 to enable the I/O ports (disabled by default to allow multiple FM-PACs). Further explanation here here. Example code including detection following the MSX Datapack advice here.

Yes, I am aware about that procedure to enable the I/O ports after detection. At the moment, I'm just happy (for my tests) that the FM-PAC cartridge works directly out of the box with I/O ports, without any need for initialization.

I ran into another problem : I assumed, reading the YM2413 application manual, that to produce any note, you just could enter the F-number of a given octave (for example the 4th octave), and then change the octave in the Block bits (in registers 20h-28h). So for example, I could do this :

note    F-number    Block
C4      171         4
C5      171         5
C6      171         6

And if you check with this formula, it seems to confirm that :
Fnumber = Fmus . 2^18/ Fsam / 2^(Block-1)

But it doesn't seem to work entirely like that. I get some notes in 4th octave, some in 3rd, but some notes are missing. So I guess I got it wrong. Could someone correct me on that ?

PS : I think this hobby needs a fuller and clearer MSX-Music application manual. Yamaha can be so obfuscated sometimes in their explanations ...

By Grauw

Ascended (10074)

Grauw さんの画像

11-08-2020, 10:32

No, your assumption is correct. Something else must be wrong if it doesn’t work for you. Maybe to do with key on, or you’re using the wrong bits?

By Metalion

Paragon (1446)

Metalion さんの画像

11-08-2020, 11:46

I found the problem : my F-number table was incorrect, and the E note was missing. I had this :

F_number	; A,A#,B,-,C,C#,D,D#,E,-,F,F#,G,G#
	word	288,306,324,0,171,182,192,204,0,216,229,242,257,272

where I should have had this :

F_number	; A,A#,B,-,C,C#,D,D#,E,-,F,F#,G,G#
	word	288,306,324,0,171,182,192,204,216,0,229,242,257,272

By Metalion

Paragon (1446)

Metalion さんの画像

03-10-2020, 10:36

OK, now trying to play a user instrument.
My first try is with MSX-MUSIC built-in user instruments.
I've done this program:

20 _VOICE(@58,,)
30 _AUDREG (16,216)
40 _AUDREG (48,&h20)
50 _AUDREG (32,&b00011000)

But it gives me 'Syntax error in 20'
I used this page as reference :
What am I doing wrong ?

By Manuel

Ascended (18162)

Manuel さんの画像

03-10-2020, 12:42

Just leave out the extra commas there. They are only needed if you want to 'skip' channels in the voice specification.

By Metalion

Paragon (1446)

Metalion さんの画像

03-10-2020, 13:18

OK, thanks, it works now.

By Giangiacomo Zaffini 2

Master (252)

Giangiacomo Zaffini 2 さんの画像

24-10-2020, 00:46

In K.H.'s Tweet - with powerful MSXPen that's always on our side - some insight on BASIC CALL TEMPER.

By snake

Resident (51)

snake さんの画像

11-03-2021, 13:49

anyone managed to use drums?

According to ym2413 manual, register 0E enables drums and sets the tone, and registers 36-38 set volume.
So, i attempted to write the value 00100100 on register 0E and 11111111 to registers 36-38 but nothing happens...

By Metalion

Paragon (1446)

Metalion さんの画像

11-03-2021, 14:32

Do you do a Key ON/Key OFF (on registers 20h-28h) ?

ページ 2/3
1 | | 3