Page 1 of 1
Change Tandy Sound to JT89
Posted: Tue Oct 25, 2022 8:11 am
by spark2k06
I have created a new branch (
prerelease-jt89) and below I show the changes made for the migration:
https://github.com/MiSTer-devel/PCXT_Mi ... ff65c6b8b7
After this initial change, the sound is very bad, I attach the synthesised
RBF. I am starting this thread in case someone knows how to fix it.
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 7:05 am
by spark2k06
First attempt at fix taking into account the sign, as suggested by jotego, but probably poorly executed:
https://github.com/MiSTer-devel/PCXT_Mi ... 4017553c41
The fact is that the other module, also created by him, of
OPL2 is also signed but 16 bits instead of 11 bits, and it works correctly:
- Audio Mixer.png (14.07 KiB) Viewed 2351 times
However, this still sounds bad for the
Tandy sound part.
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 10:51 am
by kitune-san
If you are accounting for the sign, I don't think these bits are fixed at 0.
---
tandy_snd <= {2'b00, {3'b000, {oldt_1[10], oldt_1}} << status[35:34]};
---
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 10:57 am
by kitune-san
Maybe like this.
Code: Select all
tandy_snd <= {2{oldt_1[10]}, {4{oldt_1[10]}, oldt_1}} << status[35:34]};
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 1:48 pm
by spark2k06
kitune-san wrote: ↑Wed Oct 26, 2022 10:57 am
Maybe like this.
Code: Select all
tandy_snd <= {2{oldt_1[10]}, {4{oldt_1[10]}, oldt_1}} << status[35:34]};
Thank you very much! that was it
Finally it stays like this:
Code: Select all
tandy_snd <= {{{2{oldt_1[10]}}, {4{oldt_1[10]}}, oldt_1} << status[35:34], 2'b00};
I update the
prerelease branch, it will be available soon but I also attach a binary so that users can compare the previous
Tandy sound with the current one.
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 4:52 pm
by jordi
kitune-san wrote: ↑Wed Oct 26, 2022 10:57 am
Maybe like this.
Code: Select all
tandy_snd <= {2{oldt_1[10]}, {4{oldt_1[10]}, oldt_1}} << status[35:34]};
I'm wondered that you always have a nice solution
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 8:11 pm
by sofakng
Can you also take a look at something else while you are looking into the sound?
The sound from the current PCXT core is inverted from a real SN76489 chip.
Here is a picture of my recordings: [volumes have been normalized]
- PCXT.png (73.13 KiB) Viewed 2130 times
Top is TNDLPT adapter (by Serdashop) and bottom is PCXT.
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 8:22 pm
by sofakng
Here is the waveform using your JT89 core (on the bottom) [volumes have been normalized]
EDIT: I've added 86Box and ScummVM captures too:
- PQ1.png (128.35 KiB) Viewed 2101 times
Here are the Audacity files if anybody wants to take a look:
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 8:53 pm
by cursedverses
From a strictly analogue hi-fi soundpoint, does this just mean you have a negative when you require a positive, and vice versa? A soundwave is representative of a speaker's movement over time after all (one polarity pushes the speaker and the other pulls).
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 10:53 pm
by dmckean
cursedverses wrote: ↑Wed Oct 26, 2022 8:53 pm
From a strictly analogue hi-fi soundpoint, does this just mean you have a negative when you require a positive, and vice versa? A soundwave is representative of a speaker's movement over time after all (one polarity pushes the speaker and the other pulls).
Yes and almost anything in the audio signal path can invert the sound.
Re: Change Tandy Sound to JT89
Posted: Wed Oct 26, 2022 11:09 pm
by sofakng
Yeah, I don't know what it means but I just wanted to show what I found. If it's not an issue than that's great!
Re: Change Tandy Sound to JT89
Posted: Thu Oct 27, 2022 4:56 am
by spark2k06
sofakng wrote: ↑Wed Oct 26, 2022 11:09 pm
Yeah, I don't know what it means but I just wanted to show what I found. If it's not an issue than that's great!
You will notice absolutely no physical audio change, but there is no problem in inverting the waveform to be more faithful to the original, I attached binary again with this change:
On the other hand, I share a couple of recordings provided by @Mills regarding Arnim Laeuger's previous
Tandy sound with respect to José Tejada's new
jt89 by the time I bring the update to all users:
SN76489AN Compatible Implementation by Arnim Laeuger
JT89 by jotego
Re: Change Tandy Sound to JT89
Posted: Thu Oct 27, 2022 2:11 pm
by sofakng
Thanks so much! I'm not sure if the JT89 audio was inverted though? I was referring to the original sound core but I can't tell based on the waveform if JT89 is inverted.
Also, I'm just curious but why did you switch from the Arnim Laeuger core to the JT89 version? The Arnim Laeuger core waveform matched the actual SN76589 nearly perfectly (except for the inversion).
The JT89 audio core doesn't seem to match the original waveform but I do trust Jotego and would assume his is most accurate but it's odd the waveform is different?
Thanks again for all your work on the core! I never realized how important the Tandy 1000 was especially relating to early Sierra games, etc.
Re: Change Tandy Sound to JT89
Posted: Thu Oct 27, 2022 2:22 pm
by spark2k06
sofakng wrote: ↑Thu Oct 27, 2022 2:11 pm
Thanks so much! I'm not sure if the JT89 audio was inverted though? I was referring to the original sound core but I can't tell based on the waveform if JT89 is inverted.
Well, as it doesn't really affect how it sounds, I'll just put it back uninverted for future updates, that's not a problem.
sofakng wrote:
Also, I'm just curious but why did you switch from the Arnim Laeuger core to the JT89 version? The Arnim Laeuger core waveform matched the actual SN76589 nearly perfectly (except for the inversion).
The JT89 audio core doesn't seem to match the original waveform but I do trust Jotego and would assume his is most accurate but it's odd the waveform is different?
I don't know if
JT89 wave is accurate or not, but listen to the differences with the audios I've shared and judge for yourself, I certainly prefer the sound of Jotego's
sofakng wrote:
Thanks again for all your work on the core! I never realized how important the Tandy 1000 was especially relating to early Sierra games, etc.
To you for appreciating the work done with the core.