VOGONS

Common searches


DB60XG / XR385 repair and modification

Topic actions

Reply 20 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

Oh, and something else:

On Atrend ATC-6631 cards (with YMF71x) there are two 220 ohm resistors labeled CB12 and CB13. Now why these are labeled CB (Bypass Capacitor), or why there has to be be a cap or resistor here in the first place is beyond me, but when combined with the output impedance of the XR385 (about 1K), these will attenuate the signal by about 15dB. It's probably a good idea to remove them, especially when using the output mod I described in my last post.

Picture: http://img842.imageshack.us/img842/2396/3xxp.jpg

edit: Labway cards actually have capacitors here.

Last edited by jwt27 on 2013-11-28, 18:02. Edited 1 time in total.

Reply 21 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

I can hardly believe my eyes here...

I was just browsing through Cloudschatze's 3DXG manual (thanks for that! 😉) when I noticed something interesting... The manual claims that the DB60XG uses 18-bit audio, just like the more professional XG synths. Now, that must be a typo there, right? Well I just checked, to be sure...

Here you see the SDATA (top) and SYNC (bottom) signals. SDATA is the actual audio data, and SYNC specifies the audio channel (left or right). The signal is right-justified, that means the end of the SYNC pulse denotes the least significant bit (LSB).

i3ta.jpg

Notice anything unusual yet? Let's zoom in a bit...

qpsr.jpg

Yes, you see that right. Two more bits follow after the end of the SYNC pulse. This means that, all this time, we've been missing out on TWO WHOLE BITS of audio data! (or actually much more, considering the noisy analog outputs...)

So, to actually get 18-bit sound out of it, all you have to do is delay the SYNC pulse by two SCLKs, and switch the DIT4096 into 18-bit mode. This requires a microcontroller.

Next is the question... why did they ever do this!?

Last edited by jwt27 on 2013-11-27, 16:37. Edited 1 time in total.

Reply 24 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
bristlehog wrote:

Is that a damn MANOMETER sticking out of your PC?!

That's my ghetto-modded steampunk Voodoo3 temperature monitor! 🤣

iy73.jpg

It's just a thermometer from an old steam boiler.

tincup wrote:

I have NO IDEA what I'm looking at but God help me, I love reading this #h*t!

Hey, thanks 😀

Just thought of another, more simple, way to get 18-bit sound: shift the SYNC pulse using discrete logic and use a high-quality 18-bit DAC with 108dB minimum SNR. For the logic stuff, something like this should do.

Reply 25 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

No one else interested in this stuff? I thought there would be more people here looking to get better sound from their midi cards...

Anyway I ordered some 18-bit DACs to experiment with, again from utsource, once they arrive I'll let you guys know. In the meantime I can continue with my DB60XG-in-a-box project.

Reply 27 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
d1stortion wrote:

What you need to do is get an 18-bit Sound Canvas and check for its, well, 18-bit-ness 😀

You mean an SC-88 or 55-mk2? Do you suspect these aren't really 18-bit?

Reply 28 of 71, by d1stortion

User metadata
Rank Oldbie
Rank
Oldbie

No, unlike the DB60XG they have an excellent signal with no noise at all even on maximum volume level. Can't imagine any of the claimed specs for those units being wrong. My "suggestion" was a bit ironical, given the fact that you put an impressive amount of technical expertise (to me, that is) into fixing this daughterboard and even using an oscilloscope to determine that it's not actually 18-bit 😀

Reply 29 of 71, by Cloudschatze

User metadata
Rank Oldbie
Rank
Oldbie
jwt27 wrote:

Next is the question... why did they ever do this!?

I wonder if there just wasn't a cost-effective 16/18-bit CODEC available?

Anyone who doesn't want to bother with swapping out the CODEC chip on their DB60XG card can always switch to the DB50XG, which does use an 18-bit DAC. 😀

Reply 30 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
d1stortion wrote:

No, unlike the DB60XG they have an excellent signal with no noise at all even on maximum volume level. Can't imagine any of the claimed specs for those units being wrong. My "suggestion" was a bit ironical, given the fact that you put an impressive amount of technical expertise (to me, that is) into fixing this daughterboard and even using an oscilloscope to determine that it's not actually 18-bit 😀

Ah, well.. when I find some sub-optimal design like this, my improvement-OCD creeps up and I just HAVE to do something about it 🤣

And I wouldn't call myself an expert on this.. I've never done anything with digital audio circuits before, just learning all this stuff as I go.

Cloudschatze wrote:
jwt27 wrote:

Next is the question... why did they ever do this!?

I wonder if there just wasn't a cost-effective 16/18-bit CODEC available?

They could've just used a separate DAC and ADC... At least that's what I would have done, if the other option is a 20-something dB drop in dynamic range.

Cloudschatze wrote:

Anyone who doesn't want to bother with swapping out the CODEC chip on their DB60XG card can always switch to the DB50XG, which does use an 18-bit DAC. 😀

It does? I didn't know that... But then I never checked, either. Looks like I need a DB50XG now to compare 😀
I more or less assumed the DB60XG (and 50) used 16-bit internally, just because these were "consumer" models. So finding two additional bits was quite a surprise for me.

Reply 31 of 71, by Cloudschatze

User metadata
Rank Oldbie
Rank
Oldbie
jwt27 wrote:
Cloudschatze wrote:

Anyone who doesn't want to bother with swapping out the CODEC chip on their DB60XG card can always switch to the DB50XG, which does use an 18-bit DAC. 😀

It does? I didn't know that... But then I never checked, either. Looks like I need a DB50XG now to compare 😀

Yeah, the DB50XG uses the NEC UPD63200, which is 16/18-bit capable, with the selection pin held "high," in the 18-bit state.

I've always ignorantly favored the DB50XG over the DB60XG, sound-wise, but never noticed the difference in DACs until you pointed out your findings. 😀

Reply 32 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

After tracing the DB50XG picture on Wikipedia, and some more probing around with the 'scope, I found the unaltered (18-bit) SDATA signal on pin 26 of the XQ036A0 chip. This leads to XR371A0 pin 42. Here, the 18-bit signal is shifted to 16-bit, and comes out from pin 3, going to pin 11 of the AK4510.

5zwi.jpg

So that means, we can just connect this straight to an 18-bit DAC, no additional logic required 😀

18-bit S/PDIF won't be as easy... but it's not impossible. Using the DIT4096 in software mode to select 18-bit operation seems like the "easiest" way. But I don't know how my X-fi (or any consumer audio gear, for that matter) will respond to an 18-bit signal.

Another option is using a microcontroller to convert the 18-bit signal to 24-bit. That would be as simple as duplicating MSB (the sign bit) six times. Timings will be pretty tight, however, since SCLK frequency is 48*fs (that means exactly 24 bits will fit in a SYNC pulse). And on the receiving side, the signal must be amplified by +36dB to normalize it to 0dBFS.

Visual explanation:

          _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _
SCLK _| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_|
_______________________________________________________________________________________________
SYNC _______| |___________
___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___
SDATA ___|___|___|___|_______________________|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___
16-bit LSB MSB LSB

___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___
SDATA ___|___|_______________________|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___________
18-bit LSB MSB LSB

___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___
SDATA ___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___|___
24-bit LSB MSB MSB MSB MSB MSB MSB MSB LSB MSB MSB MSB
Last edited by jwt27 on 2013-12-01, 20:05. Edited 1 time in total.

Reply 33 of 71, by Stefan_L

User metadata
Rank Member
Rank
Member

Some XG songs need the extra 2 bits for dynamic range or else they will distort.

Here is the two thread on another forum were i posted about S/PDIF modifications:
http://nfggames.com/forum2/index.php?topic=4063.0

http://nfggames.com/forum2/index.php?topic=4189.0

Thats pure noob stuff i wrote there... it's amazing i even managed to get it working 🤣

Reply 34 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
Stefan_L wrote:
Some XG songs need the extra 2 bits for dynamic range or else they will distort. […]
Show full quote

Some XG songs need the extra 2 bits for dynamic range or else they will distort.

Here is the two thread on another forum were i posted about S/PDIF modifications:
http://nfggames.com/forum2/index.php?topic=4063.0

http://nfggames.com/forum2/index.php?topic=4189.0

Hey, thanks! Those threads look familiar... I've come across those before while looking for clues about why the DIT4096 didn't work at first (turned to be something else, I had to remove the broken DAC first because it distorted the digital signals). Didn't realize that was your thread 🤣

And yes, if you use the 18-bit signal for 16-bit S/PDIF, I'd imagine you'll get some serious clipping (since two MSBs are discarded)... That's why they shifted the signal by two bits on the DB60XG (which discards two LSBs, and "only" increases the noise level)

Stefan_L wrote:

Thats pure noob stuff i wrote there... it's amazing i even managed to get it working 🤣

Well, it looks like you've done more with the DIT4096 than me so far! And you got a nice frequency counter (I have to count bits manually...)

Reply 35 of 71, by Jepael

User metadata
Rank Oldbie
Rank
Oldbie

Surely the normal way is to keep MSB at MSB, no matter how many LSBs follow. SPDIF always transmits up to 24 audio bits per sample, you just have to configure the SPDIF transmitter to use matching bus format what is transmitted, so that unused bits are zero.

And not a single SPDIF transmitter I have encountered has a matching format for native OPL3 (YMF262) audio bus. It sends LSB first, MSB last, with two latch signals that are high for eight MSBs for each channel, and there are 36 bits in a frame. And it would most likely need a sampling rate converter as it uses a non-standard sampling rate (approx. 49716 Hz). Nothing a small CPLD would solve though..

Reply 36 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
Jepael wrote:

Surely the normal way is to keep MSB at MSB, no matter how many LSBs follow. SPDIF always transmits up to 24 audio bits per sample, you just have to configure the SPDIF transmitter to use matching bus format what is transmitted, so that unused bits are zero.

I was thinking of a way to convert the 18-bit signal to 24-bit by means of a sign extension (I think that's what it's called). The other way around might also work, when the audio data is left-shifted by 8 bits.. not sure about that.

18-bit signal used as 24-bit:
___________18-bit__________ ________________24-bit_______________
/ \ / \
+128 = 00 0000 0000 1000 0000 = 0000 0000 0000 0000 1000 0000 = +128
-128 = 11 1111 1111 1000 0000 = 0000 0011 1111 1111 1000 0000 = +262016

sign extension:
___________18-bit__________ ______________24-bit______________
/ \ / \
+128 = 00 0000 0000 1000 0000 = 0000 0000 0000 0000 1000 0000 = +128
-128 = 11 1111 1111 1000 0000 = 1111 1111 1111 1111 1000 0000 = -128

Of course, if you use the transmitter in 18-bit mode this is not necessary. But I don't know if my X-fi card will take an 18-bit signal. If what you say is true, then it should have no problems with it. But then how would you go about making a bit-perfect recording?

Anyway, I might just drop the whole SPDIF idea if the 18-bit DAC I ordered lives up to it's specifications (120dB minimum SNR...)
But in order to even measure that I'd have to fix my X-fi first, the line-in is busted. Or I could just buy a real sound card instead...

Jepael wrote:

And not a single SPDIF transmitter I have encountered has a matching format for native OPL3 (YMF262) audio bus. It sends LSB first, MSB last, with two latch signals that are high for eight MSBs for each channel, and there are 36 bits in a frame. And it would most likely need a sampling rate converter as it uses a non-standard sampling rate (approx. 49716 Hz). Nothing a small CPLD would solve though..

Ah well, that just popped into my mind while I was writing that post... But you're right, it won't be as easy to get S/PDIF out of the YMF262. If I were to try that, though, I'd rather not use any sample rate conversion, after all the whole point of having an S/PDIF connection would be (to me) to make bit-perfect recordings.

Reply 37 of 71, by Jepael

User metadata
Rank Oldbie
Rank
Oldbie
jwt27 wrote:

I was thinking of a way to convert the 18-bit signal to 24-bit by means of a sign extension (I think that's what it's called). The other way around might also work, when the audio data is left-shifted by 8 bits.. not sure about that.

If you shift bits, you change the full-scale amplitude. CDs contain 16-bit signal full scale. 16-bit amplifier takes in 16-bit signal full-scale.
SPDIF can transport 24-bit full scale. Least significant bits are just zero when less bits are used. You don't need to sign extend or shift bits.
This way, no matter how many actual bits are in a transmitted 24-bit sample and how many bits the receiver can use, it always just works.

jwt27 wrote:

Of course, if you use the transmitter in 18-bit mode this is not necessary. But I don't know if my X-fi card will take an 18-bit signal. If what you say is true, then it should have no problems with it. But then how would you go about making a bit-perfect recording?

For one thing the SPDIF transmitter should transmit information how many bits are valid - in hardware mode this metadata might say 16 bits, even though all the 18-bit data is transmitted. So the receiver will see the metadata it knows how many bits it should use. Also many soundcards want to resample everything so that it does not use the SPDIF as clock master, but everything is reclocked by the internal clock on sound card.

Personally I take OPL3 captures with a USB logic analyzer and convert them to wav files, so it is bit-perfect 😀

jwt27 wrote:

But you're right, it won't be as easy to get S/PDIF out of the YMF262. If I were to try that, though, I'd rather not use any sample rate conversion, after all the whole point of having an S/PDIF connection would be (to me) to make bit-perfect recordings.

Yes, SPDIF won't work for that, albeit there are some professional sound cards that will capture the SPDIF input as-is for bit-perfect recordings. The SPDIF could just be used as a way to transport data, but no idea if the non-standard sampling rate is a problem. But it will be difficult to convert the native bus to anything a SPDIF transmitter would eat.

Some GIMIC sound modules have SPDIF output, using some sampling rate converter. At least rising the sampling rate won't throw out any frequencies, but of course it is not bit-perfect. I would also want bit-perfect, but what matters more are the analog things. First of all the OPL3 DAC has only 10 bits of resolution even if it has 16 bits of range, and different OPL3 sound cards have different analog subsystems anyway. Playing the bit-perfect digital audio through modern sound cards will sound different. Later OPL3 models also resample their output to mix it with standard frequencies like 44100 Hz. They also have more compatible audio bus.

Reply 38 of 71, by PARUS

User metadata
Rank Oldbie
Rank
Oldbie

Hi people. I'm no expert in electronics but I'm a big fan of good clear sound on old hardware designed for DOS games and GM-GS-XG music.
Tell me please is it possible to make S/PDIF interface on midi-board Yamaha SW60XG XR394? I mean full alternative to analog connection ie SPDIF OUT and SPDIF IN. SW60XG has very interesting EffectGearII program for external source with many effects. Most of them available only in Windows but a few can work by DOS command prompt. Of course the MIC IN jack is designed for microphone/guitar and must be only analog but LINE IN source can be digital and can receive S/PDIF 44kHz signal from cards as Terratec EWS64, Creative Sound Blaster AWE64Gold, Diamond Monster Sound MX300 (and other Vortex2-based cards), Avance Logic AV310, Guillemot Maxi Sound Pro Studio 64, Turtle Beach Malibu etc. [Sound Blaster Live! maybe no because 48kHz 😀]
So what about SW60XG SPDIF IN/OUT? Is it really possible? Any ideas, solutions? Thank you very much! Sorry for my English.

Reply 39 of 71, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
PARUS wrote:

Hi people. I'm no expert in electronics but I'm a big fan of good clear sound on old hardware designed for DOS games and GM-GS-XG music.
Tell me please is it possible to make S/PDIF interface on midi-board Yamaha SW60XG XR394? I mean full alternative to analog connection ie SPDIF OUT and SPDIF IN. SW60XG has very interesting EffectGearII program for external source with many effects. Most of them available only in Windows but a few can work by DOS command prompt. Of course the MIC IN jack is designed for microphone/guitar and must be only analog but LINE IN source can be digital and can receive S/PDIF 44kHz signal from cards as Terratec EWS64, Creative Sound Blaster AWE64Gold, Diamond Monster Sound MX300 (and other Vortex2-based cards), Avance Logic AV310, Guillemot Maxi Sound Pro Studio 64, Turtle Beach Malibu etc. [Sound Blaster Live! maybe no because 48kHz 😀]
So what about SW60XG SPDIF IN/OUT? Is it really possible? Any ideas, solutions? Thank you very much! Sorry for my English.

Output is identical to DB50XG, meaning you'll have to get an SPDIF transmitter like DIT4xxx and put it into 18-bit mode by means of an external PIC... Or find a stand-alone 18-bit transmitter with the same digital interface.

Not sure about the input, it's probably 16-bit 44kHz and I assume the ADC is located inside the YSS205B chip. We'll first need to figure out the interface between that and the XQ036A0 chip.