I am a bit lost with what is meant by PSG as it means many different things depending on the sound chip of the target and on weather you are using the classic lib or the new lib.
I wonder what I can use on the sms and gg in classic lib and if I can reuse the same code I use for other PSG chips.
I see in the doc I see that 1-bit is listed as implemented "PSG (+ 1 bit)" for sms and gg in the table but not in the specific page. If I try to use 1-bit sound I hear nothing. So I guess it is either not implemented or broken.
PSG and 1-bit on sms and gamegear
Re: PSG and 1-bit on sms and gamegear
I've just tried compiling examples/sound/fx.c for +sms. I ran it with emulicious and sound was emitted.
For machines with a SN76489 (see features.h and that spreadsheet I created: https://github.com/z88dk/z88dk/blob/mas ... atures.csv) Stefano implemented some code that emulates 1 bit flipping using channel 1 of the SN chip.
For machines with a SN76489 (see features.h and that spreadsheet I created: https://github.com/z88dk/z88dk/blob/mas ... atures.csv) Stefano implemented some code that emulates 1 bit flipping using channel 1 of the SN chip.
Re: PSG and 1-bit on sms and gamegear
@dom What do you mean by emulates 1 bit flipping? If I use the 1 bit API on the sms I hear nothing.
Should I open an issue?
Should I open an issue?
Re: PSG and 1-bit on sms and gamegear
By emulate, I mean it sets up a tone on channel one and then adjusts the volume.
I've additionally tested examples/sound/synthdemo and it's also making sound. So it looks like the core library is working as it should, so it may well be an emulator issue or whatever code you're using to create sounds.
I've additionally tested examples/sound/synthdemo and it's also making sound. So it looks like the core library is working as it should, so it may well be an emulator issue or whatever code you're using to create sounds.
Re: PSG and 1-bit on sms and gamegear
How is the user supposed to use the emulated 1-bit sounds on targets with the SN76489 chip?
I am using the 1-bit sound functions bit_fx...(...).
I will try to write a simple example.
I am using the 1-bit sound functions bit_fx...(...).
I will try to write a simple example.
Re: PSG and 1-bit on sms and gamegear
That’s great. They are working in examples/sound/fx.c - can you try compiling and running that example first of all so we have a known good starting point?
Re: PSG and 1-bit on sms and gamegear
@dom, yes, I am try fx.c, which is what I am trying to use.
Re: PSG and 1-bit on sms and gamegear
If I compile fx.c for the zx target I can here sounds.
I hear (and see) nothing if I compile fx.c it for the sms target.
Tested on both Emulicious and Kega Fusion.
I compile fx.c (bit_bang.c is a copy) with:
zx_bit_bang:
$(Z88DK_PATH)$(MYZ88DK) +zx -clib=default -lndos $(SOURCE_PATH)/../../test/bit_bang.c -create-app
sms_bit_bang:
$(Z88DK_PATH)$(MYZ88DK) +sms -clib=default -lndos $(SOURCE_PATH)/../../test/bit_bang.c -create-app
I hear (and see) nothing if I compile fx.c it for the sms target.
Tested on both Emulicious and Kega Fusion.
I compile fx.c (bit_bang.c is a copy) with:
zx_bit_bang:
$(Z88DK_PATH)$(MYZ88DK) +zx -clib=default -lndos $(SOURCE_PATH)/../../test/bit_bang.c -create-app
sms_bit_bang:
$(Z88DK_PATH)$(MYZ88DK) +sms -clib=default -lndos $(SOURCE_PATH)/../../test/bit_bang.c -create-app
Re: PSG and 1-bit on sms and gamegear
@dom I am opening an issue to better track this.