Open Source DSP XOs

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
It's worth ABX testing between 16 and 24 bit; I started with similar assumptions but, to my surprise, found 24 bit was consistently preferable. Inspection of the filtering showed some phase quantization occuring in 16 bit allpass filtering that was above the threshold I've found to be audible. It's not, however, clear to me if that's the cause of the subjective preference or if something else is going on; proving a negative is difficult to start with and implementing, say, a signal path which is 16 bit in phase but 24 bit in magnitude isn't particularly feasible either.

Of course, if one's using DACs which only accept 16 bit words it's kind of a moot point.
 
There might still be workaround, let's ask Infineon.

An example: The I2S streams are continuous. If you want to sample @48 kHz/24 bits (or even 32 bits) you just tell USIC to work at 96 kHz rate with 16 bit word length and 32-bit frame length. Then just divide the word clock to DAC or CODEC by two: Use a D-type flip-flop with LRCLK to CLK input and /Q output of FF to DATA input so Q output has the frequency divided by two, right? (How about phase?) Now XMC's USIC thinks it's working on different sample rate and word/frame length but does it really matter? No it doesn't. Only thing I'm worried about with this workaround is the propagation delay and the other possible timing problems causing jitter. In this case XMC is master, so steph_tsf's "3 x bidirectional I2S with the XMC4500 as slave connecting to a WM8580 or WM8581 codec" doesn't work as simply because the word clock (from WM8580) frequency should be doubled which isn't as simple (though shouldn't be difficult for anyone experienced, guess you just clock in some counter with SCLK and reset it at LRCLK and take out the new sync from correct output).

Well, I was propably too fast, above doesn't work properly because the left and right channel may be mixed up and swapped and phase delayed :headbash::headbash::headbash:
 
Last edited:
Yeah, proper initialization of the LRCLK flip flop is important to avoid mix ups. It would have be a pretty awful flip flop to introduce enough jitter on the LRCLK to cause data misreads or significant noise injection into most the DACs, though it is something to be careful of in the special case of a DAC with an PLL that's doing clock recovery from LRCLK. In well implemented cases the MCLK would be local to the DAC and a copy routed up to XMC so I wouldn't worry about it too much though. Another option to look into would be bit bang the pin, possibly by programming a USIC to emit 2x16 zeros, then changing it over to 2x16 ones.

All of these solutions seem like reinventing SGPIO the hard way, though. ;)
 
All of these solutions seem like reinventing SGPIO the hard way, though. ;)

Yeah, but SGPIO is in it's own class. Did you know that it can be used also to send SPDIF and ADAT signals? Actually any continuous bit stream sender can do it, so with XMC parts one solution would be to encode that data to SPDIF format for sending to DAC (Differential Manchester encoding - Wikipedia, the free encyclopedia).

Now your idea of bitbanging got me thinking solution for the slave use case. Because of the (large) number of I2S channels one channel could be used to sample the original 64SCLK LRCLK from the master device so we could use these bits to identify which 32SCLK frames are from right and which from left channel.
 
Left message to Infineon forum to clarify data sheet. I though found after some reading that in the SCTR (shift control register) there is also a FLE field which is described "FLE [21:16], rwh, Frame Length: This bit field defines how many bits are transferred within a data frame. A data frame can consist of several concatenated data words". Also earlier it decribed about I2S protocol:
"17.6.1.2 Protocol Overview

An IIS connection supports transfers for two different data frames via the same data line, e.g. a data frames for the left audio channel and a data frame for the right audio channel. The word address signal WA is used to distinguish between the different data frames. Each data frame can consist of several data words."

So it seems that the WLE setting doesn't set total data frame length but just the bits to be transferred to data buffer for single data word. Anyway, the code generated by DAVE must be modified to be able to transfer 24-bit words, but otherwise all looks good (though must wait for what Infineon guys tell).
 
Now if these XMC devices are fine after all I would be really interested in the XMC4400 parts in LQFP64 package for diy boards.

http://www.infineon.com/cms/de/prod...?productType=db3a30443784920501380a41302f6c86

If I did read it correctly this time this part comes with four USIC channels (U0C0,U0C1,U1C0 and U1C1, most of the pins are available in ALT2 pinning, there arent so many alt pinning as in larger packages) which would be just enough, and the part is easier to solder (less pins).
 
Last edited:
Today I came across this guy using a RasPi to do real-time guitar effects :

GuitarExtended - Real-time guitar effects on Raspberry Pi with Pure Data and Arduino - YouTube

Seems he's using a package called 'Pure Data' and getting his audio in and out via a USB soundcard. According to the Pd information a couple of soundcards are supported, one is a $30 Behringer here : Amazon.com: Behringer UCA222 U-Control Ultra-Low Latency 2 In/2 Out USB Audio Interface with Digital Output And Downloadable Software Bundle: Musical Instruments

I haven't looked into it, but ISTM that if Pd can do guitar effects it might also be able to do XOs. Anyone interested in investigating this? Also I'm seeing a window of opportunity here for NOS ADCs and DACs because for these kinds of real-time applications, low latency is highly desirable :p
 
The RPi SoC uses a 700MHz ARM11 core so should be entirely capable of running an XO. The ATmega32 in the Arudino's just monitoring the stompboxen---you can find details in the details link of the video. ;) One might try Filterview or MMQ as starting points for an implementation.

My electric guitar rig goes through two ADC+DAC stages. I'm not sure what one of them is as I haven't gotten around to taking the pedal apart yet but the other's a CS4272 running anywhere from 44.1 to 96. 44.1 is a little loose but 96 is fine. NOS would be overkill from a latency standpoint, though electric guitar is NOS friendly in that the amps usually roll off in the 4-5kHz range so the rig won't be too sensitive to the NOS sync envelope.

Did you know that it can be used also to send SPDIF and ADAT signals?
Given an appropriate PHY all serial interfaces pretty much look alike and aren't at all hard to handle in SGPIO up to its clock rate limit. Implementations using NRZI encodings (all speeds of USB, for example) can be a little fussy as the data rate on the wire is data dependent and the bit stuffing is most conveniently implemented in the PHY. But NRZI and other common enodings like 8b/10b (1394, SATA) can be done in software if one really has to. Manchester (SPDIF, 10MHz Ethernet) is easy as are unencoded links like I2S but for SPDIF you'll likely end up with a PHY down---I'd be surprised if the XMCs or LPC4300s have PLLs that can acquire an incoming stream at sufficient speed. So one might as well just ship I2S back to a Wolfson transciever and let it handle the encoding, driving the output, and getting levels right. Cirrus does make SPDIF transmitters but Wolfson's transceivers are cheaper and use the same amount of board space.

part is easier to solder (less pins).
I wouldn't sweat it; drag solder difficulty is a weak function of the number of pins on the package.
 
Today I came across this guy using a RasPi to do real-time guitar effects :

GuitarExtended - Real-time guitar effects on Raspberry Pi with Pure Data and Arduino - YouTube

Noticed the same vid earlier, too.

I would rather use FAUST to generate C++ code and then optimize it for own use:

FAUST (programming language) - Wikipedia, the free encyclopedia
https://ccrma.stanford.edu/~jos/spf/aspf.pdf

Seem FAUST can also generate PD plugins so it may be the FX is originally coded in FAUST.

RPi, well is not a nice environment. It is using Broadcom closed source SoC where the GPU actually implements many system functions. There is no proper documentation, for an example when people have tried implementing simple PCM/I2S IRQ handler it doesn't respond to documented IRQ but to another one found by hacking (IRQ 55 is the documented one, IRQ 81 the one raised when I2S FIFO is empty/full). USB on RPi has got the only (allowed) FIQ level (non-maskable) IRQ, so USB devices seems to work if supported, but I2S audio for an example is difficult to get working at all or with latencies low enough for realtime use. Got to try the Behringer on because I've got such on my desk waiting for some use. Now if RPi just supported 24-bit 8-channel audio on HDMI (which is doesn't do as far as I know, but haven't tried either) it would make nice crossover system. Just get an inexpensive AV receiver with enough power and use it as multichannel power amp with RPi connected to it's HDMI input.

I've got the NGX LPC4330 Xplorer board (came with Keil ULINK-ME JTAG adapter), got to find out next how to build a proper power supply for the Asus H6 DAC board so I can start doing something with them (using breadboard and jumper wires to connect different modules). Guess LM1117-5.0/3.3 LDO's a fine for regulating the DAC voltages, aren't there any reasons for not using them? Seems there are zillions LDO to choose from, but don't know which are kind of standard like LM317/LM337 ones for op amp supplies.
 
hows your QFN soldering? the TPS7A4700/TPS7A3301 are unbeaten at the moment. +/-1.4-36Vout for the pair at up to 1A and as low as 4µVRMS. next down would be the little brothers TPS7A4901/TPS7A3001, which have the same voltage specs, while being a bit more diy friendly. They still have powerpad to solder under the part for heatsinking, but you can make a modified PCB pattern to allow hand soldering pretty easy by punching a couple vias through the powerpad to solder from underneath. they are 150 and 200ma respectively and not quite as low noise (but still 15.4µVRMS, 72dB PSRR).

its been a while since an actual +/- low noise regulator pair has been made as a pair and in the same package with similar specs, now theres 2! not breadboard friendly at all though
 
Last edited:
LM1117-5.0/3.3 LDO's a fine for regulating the DAC voltages, aren't there any reasons for not using them?
The 1117 family is a good default for a positive LDO and ON's NCP1117 parts are probably the most useful implementation thereof; cheap, readily available, available in TO-252 if you need the thermals, and ceramic stable with sufficient output capacitance. Asus specs the H6 as having three PCB1796 DACs, which I assume is a typo for PCM1796. TI doesn't specify the PCM1796's PSRR or provide eval boards for the Burr-Brown DAC family so it's hard to estimate whether the chip's headline DNR spec is supply limited---given a typical DAC PSRR as a function of frequency -120ish dBA is about where things wind up with any of the many Vrms_noise = 0.003% Vout regulators when used with minimal supply filtering. Also, it's common for manufacturers to market their boards as having the DAC's datasheet performance. So, unless you can find actual measurements, it's reasonable to expect the H6 may deliver performance anywhere from a few to many dB worse than the PCM1796's 123dBA DNR datasheet spec. Also, note that a DAC's headline figures are typ and min values aren't usually specified. So if you get unlucky with the DAC you end up with performance may be several dB worse as well.

So, while the TI parts qusp mentioned are nice, they may or may not result in wringing a better THD+N or DNR out of the H6 than a 1117. It's most likely performance will be limited by Asus's PCB but there's no harm in throwing extra regulator at it if you don't mind the additional cost and soldering complexity (though, depending on the gain structure and noise reduction downstream of the DAC board, there may not be any point---it's worth making sure that's capable of handling sub-uV levels before bothering with fancy regulators). Most low noise regulators don't support 5V outputs and therefore don't work with most DACs so TI's updates of the 317, 337, 317L, and 337L end up being the go to choice if one wants something better than a 1117. The ADP7102/7104 are also potential choices for this application and TI has a few other parts which might be of interest---you can go to TI's part selector and filter for low noise but probably the most interesting one in this case is the TPS71701.
 
Last edited:
sure I agree you have to make sure the board is up for it and there are lots of choices (the ubiquitous lt1763A is not a bad one either), but if building an external reg board as a sort of test fixture and with the availability of soldering technique, a suitable PCB and equipment, the cost is still pretty low to build something that will warranty that if there are noise issues, its with the dac PCB.

thats just me though and the same parts could be used for an analogue supply upgrade for the dac directly. a DIY 2 layer PCB is still a possibility at these sizes if you are organized and prototype quantities from board houses are so cheap now.

its just nice to know now that unless chasing really high specs, the ability to use a pretty simple LDO based supply for both digital and analogue is doable, vs having to do something like a flea type buffered reference (for the space and complexity constrained)

the flexibility of the 1A models is excellent, enabling you to power anything from a clock or 3v3 logic, right up to a pretty serious class A discrete fet or bipolar based trans-impedance amp at +/-20-30v.
 
Last edited:
Well, they can be flexible, but the lack of TO-263 or TO-220 availability imposes thermal limits on what one can do with them---~40 C/W is kind of a painful package for a 1A regulator. Ripple rejection is another significant concern; for example, if one really wants to realize the 7A4700's 4.7uV RMS noise floor the audio band ripple on the regulator's input needs to be under 5mV or so. As a result, a preregulator is pretty much required, both to manage the ripple and provide sufficient line regulation. Similarly, all loads the regulator supplies have to be class A or really close to it, otherwise the rail stability limits on load regulation.

So it's been my finding it's often more effective to make the general purpose supply a 317+337 pair (or similar) in TO-220 or 263 with the option of adding heat sinks and then use the fancy parts for point of load regulation. Point of load tends to make ground loops more manageable too, which can be useful when one's trying to minimize crosstalk between digital +2.5/3.3/5V supplies, a DAC's +3.3 or 5V analog supply, and +-5V or whatever for the output buffers.
 
yeah well I always use preregulation anyway, anything shooting that low with noise should really be using it, or at least a good stiff filter. the package is both blessing and curse I agree, but i'll give Ti the benefit that its doable. I get the feeling that with some of the crazy parts packaging i'm seeing coming online lately, PCB heatsinking is more effective than you/we think, if the design is good.

I guess i'm assuming as much overkill as I have a tendency for and decent onboard regulation and decoupling. transient response actually seems pretty good so far, not sure about the neg part yet, only just got samples and working on a PCB now. to lower my own anxiety about the heatsinking i'm allowing for a BGA heatsink to be mounted to copper pour underneath with plenty of vias and then flipping the whole board upside-down
 
Last edited:
The ~40 C/W number I mentioned is from figure 28 in the 7A4700 datasheet and a generous allowance of PCB area (most of my boards would be in the >60 C/W range). Prolly the highest supply one would use the 7A4700 or 7A3301 would be a 20V trafo, resulting in a typical scenario of dropping around 25V to 15V if the mains are at 100%. The maximum current the regulator can handle in this configuration is something like (150C max junction temperature - 40C ambient temperature inside case) / ((25V unregulated input - 15V regulated output) * 40 C/W theta_ja) ~= 275mA, reducing to 170mA at 110% mains. If one targets a more realistic junction temperature of 100C to allow some margin and improve longevity those numbers reduce to 150 and 94mA. Kind of makes one wonder why the 4700 isn't available in TO-220 like the 3301 or why exactly one's paying for a 1A capacity.

Preregulating to, say, a 1V dropout pretty well solves the thermals, though, and seems to be how TI intends the parts to be used. This makes it a little odd both the positive and negative parts support a 36V input---for a positive regulator this makes sense in a single, preregulated supply application but for negative the only scenario I see for 36V is direct operation from a ~20V trafo. That might explain the 3301's TO-220 availablity but doesn't explain the 4700 being QFN only. Perhaps TI had customers that didn't know how to implement an inverting buck regulator or a dual positive configuration? :confused:

Be interesting to see what theta_ja you get with the BGA sinks.
 
i'm not replacing PCB heatsinking with the BGA, just augmenting it to make myself feel better. to be clear i'm talking about attaching it to the copper with something like sekisui thermal tape, not the part. yeah the to220-7 only in the neg version is a bit annoying, but i'm used to seeing this sort of crap, i'm just happy to see a pair in the same package at all, even a pair at all.

i'm planning to run them higher voltage than 36, about +/-45vdc @ 250-300ma by elevating the ground by 20-25v with a diode and returning everything relating to the reg, voltage dividers etc to that instead of ground, this way emulating 20-25v operation. all very experimental, it may end in a puff of blue smoke.

I did think of doing dual positive, but I prefer not. it is supplying a Class A IV stage, so regulation isnt such a big deal, just lower noise without breaking out the massive heatsinks to power an IV that already runs 50W
 
Last edited:
Good discussion, guess diy folks when compared to professionals totally almost forgot the PSU issues and don't spend enough time for studying thing like regulators instead of looking DAC or ADC part with the lowest SNR.

Now, for prototyping work, or for using in actual 'product' it would be nice to have a general purpose power supply board with dual analog supplies for op amps, and single supplies for various bits on converter board (DAC digital and analog supplies, digital buffers and everything else). The QNF parts are difficult to solder, at least the ones with the exposed thermal pad, so other alternatives are welcome. Noticed though that TI's got EVM's for TPS7A4700 (and the 7A33 neg part), but those are about 20 EUR/pc. There is also the 150mA family of ultralow-noise regulators: TPS7A49/30:
Ultra low noise low dropout ( LDO ) voltage regulator IC for power precision analog and noise sensitive applications - TPS7A30 - TI.com

For DAC like PCM1691 whose max. Icc and Idd are <110 mA these would be ok if you had an extra one for other chips onboard. For PCM1796 the Icc and Idd are less that 20 mA, so these might work for the Asus board as well (but there are other chips using the same supplies so propably not). Well, using regular easily available 317/337 parts is one possibility.

Here in diyaudio there are also other threads regarding regulators:
http://www.diyaudio.com/forums/power-supplies/28978-improving-lm3x7-regulator-circuit-18.html

Hifiduino pages also list several LDOs:
New Breed of Ultra Low Noise Regulators H i F i D U I N O

Anyway if someone could desing a board with enough TPS7A4700 chips plus single TPS7A3301 and could order the board with the QNF parts soldered and organize a group buy for it I would order couple of boards. Then why not include also rectifiers and other components (mostly capacitors) on the same board. On some group buy (I2S FIFO I think) there is already some TPS7A4700 board, but it contains just single chip.
 
Last edited:
erm.... cough =) as I said i'm in the middle of designing that....

mhelin: the lower current ones are the ones I linked as well.

but no I wont be having the rectifiers on the same board, I would prefer to leave the DC input flexible so it can be batteries for low voltages. they need a fair bit of smoothing and for that and at higher voltages, that means through-hole, or it gets rather expensive or downright undoable.

I want to leave the option for just sticking it to the floor with some keratherm or sekisui and even short snipped off leads will foul that connection. so i'll probably do a matching bridge, or people can preregulate it etc. as far as ready-made modules though... that wont be the first thing I do, I need to test these things out, ive already got some of Ians little boards, but they are pretty limited as far as heatsinking because they are so tiny, they werent designed for more than 100-150ma
 
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.