No need to search the SRAM because it is in the same slot of the MSX-Music ROM.
The standard detection is describe in the wiki:
https://www.msx.org/wiki/MSX-MUSIC_programming#Detecting
As for the simplified clones without ROM, they use the I/O ports only for sound so no need to know the slot. There is no SRAM either.
As for the simplified clones without ROM, they use the I/O ports only for sound so no need to know the slot. There is no SRAM either.
All MSX-MUSIC clones and internal MSX-MUSIC do have a ROM, and you need detection to know whether to send data to the I/O ports.
For software there’s no point in ignoring good practice and writing blindly, since they need detection anyway in order to enable the FM-PAC I/O.
Pac doesn't have a rom, so in order to keep whatever game compatible with both pac and fm-pac, the detection of s-ram can't rely on where the fm-pac rom is? (Then there's the other issue about some msx's internal fm rom but that's a different issue).
All MSX-MUSIC clones and internal MSX-MUSIC do have a ROM
The circuit diagrams I saw had no ROM but if there was one, what would it be used for without SRAM and register access via addresses?
you need detection to know whether to send data to the I/O ports.
No, except instrument data in ROM if there is any.
Edit: Anyway SRAM is not part of MSX-Music. Only FM-PAC & PAC cartridges.
Well the real question here is how to detect where PAC S-RAM is. It has nothing to do with MSX-Music or FM part of the FM-PAC. Probably only way to find out is by reverse engineering from the old games. My guess would be to look at how Ashguine 2 and 3 did it. They support SRAM and were published by Panasoft so hopefully they have a sort of reference implementation that Panasoft supplied to T&E Soft and MicroCabin.
All MSX-MUSIC clones and internal MSX-MUSIC do have a ROM
The circuit diagrams I saw had no ROM but if there was one, what would it be used for without SRAM and register access via addresses?
FM-BASIC, FM-BIOS and firmware. I assure you every MSX-MUSIC clone has a ROM. The clones do not have memory-mapped I/O though. Though I do think a real FM-PAC clone including that would be nice.
you need detection to know whether to send data to the I/O ports.
No, except instrument data in ROM if there is any.
If you do not detect then you won’t be able to enable the FM-PAC I/O and your program won’t work on FM-PAC. Also you won’t be able to access the FM-BIOS which a lot of commercial games do. And lastly you won’t be able to execute the proper procedure to prefer internal MSX-MUSIC over FM-PAC (as described on the wiki page), keeping the latter disabled to avoid both playing at the same time.
FM-BASIC, FM-BIOS and firmware. I assure you every MSX-MUSIC clone has a ROM.
I have looked at a few photos and the majority appear to have a ROM indeed. It must have been the early versions that didn't have one. I'm sure I saw some a long time ago. FM-Basic did not work, but all other FM games did.
If you do not detect then you won’t be able to enable the FM-PAC I/O and your program won’t work on FM-PAC.
I know this is not a good idea and yet I have seen it.
FM-BASIC, FM-BIOS and firmware. I assure you every MSX-MUSIC clone has a ROM.
I have looked at a few photos and the majority appear to have a ROM indeed. It must have been the early versions that didn't have one. I'm sure I saw some a long time ago. FM-Basic did not work, but all other FM games did.
At least my old Checkmark FM Stereo PAK and Zemmix Music Box both had a ROM as well. Curious what types did not. I’m also pretty sure many FM games (Japanese commercial releases) used the FM-BIOS, so I don’t know how they would work without.
It's not possible to build a functional MSX-Music cartridge without the ROM. The YM2413 chip is write-only, and this is why the procedure to detect an MSX-Music cartridge is based on looking for the ROM signature on the slots.
A theoretical YM2413 cartridge without ROM just wouldn't be detected by any existing MSX software and would be useless.
If you have a ym2413 cartridge without ROM, it probably will still work if you insert a fm pac (or the machine has a fm), the io will still drive the ym. I did have ym2413 on a breadboard hanging off the cartridge port and it made sounds but the machine had fm too.
There is also one cartridge without the ym2413 but with fm-pac rom, it is the PAC-V cartridge by sharksym. It uses the sram utility program from fm-pac for pac-v sram.