nokturnal wrote: 29 May 2024 18:07
If you could provide opl port write routs / detection I could make Raven Sound Blaster driver easily and incorporate it in my player/opl driver lib (,which is not public yet).
That, I can (soon) do ! :)
I have a bit of interface cleaning to do but assuming isa_bios.prg is in the auto folder it
should be as simple as:
Code: Select all
isa_t* isa;
Getcookie('_ISA', &isa);
isa->outp(0x388, somedata)
or a bit cleaner yet, get the device details from the pnp map:
(non-pnp devices can be manually added to the map too, through the cfg file)
Code: Select all
// get first installed device with id <pnp_id>
isa_dev_t* dev = isa->GetDevice(pnp_id, 0);
// write <somedata> to register <reg> in the devices first io-range
isa->outp(dev->ports[0] + reg, somedata)
Untested on anything but my computer, but should/may autodetect and work on Hades and Milan too if I understood their memorymaps correctly.
Panther/2 or those VME adapters are a bit tricker to autodetect since they change memorymap depending on which graphicscard you use - but since you can override bus details manually in the config file you could probably make it work on anything sensible.
If you rather write directly instead of calling the API you can too. It requires a bit more care and checking the flags on how the bus is wired up though. and possibly have different codepaths for different machines. same as pci_bios.
(though in reality, all machines can do "little endian lane swapped" access as far as I can tell)