Maker Pro
Maker Pro

USB Sound Cards? Good to adapt for stuff?

L

Lostgallifreyan

Hi.
I just bought this thinger:
http://tinyurl.com/zloek
(USB full duplex audio 'card' probably based on Micronas IC)

Has anyone here played around with one? I was thinking that with a copy of
Sound Forge or similar app, a very very cheap realtime datalogger can be
made. The main sticking point would be DC blocking, which would have to be
removed.

Any thoughts?
 
P

Pooh Bear

Lostgallifreyan said:
Hi.
I just bought this thinger:
http://tinyurl.com/zloek
(USB full duplex audio 'card' probably based on Micronas IC)

Has anyone here played around with one? I was thinking that with a copy of
Sound Forge or similar app, a very very cheap realtime datalogger can be
made. The main sticking point would be DC blocking, which would have to be
removed.

I think most A/Ds have high pass filtering in DSP. It may simply not work.

Graham
 
L

Lostgallifreyan

I think most A/Ds have high pass filtering in DSP. It may simply not
work.

Graham

Which would be annoying. I guess someone might have made a DirectShow
plugin that can full-wave-rectify a signal, that way I could get a unipolar
trace by filtering the rectified input from a 20 KHz oscillator whose
output amplitude is controlled by the signal I want to log. That defeats
the point though, I'm hoping that someone made a sound card that leaves
nothing more than removal of DC blocking caps as the only thing to do to
get a data logging input.

Incidentally, I know that a bit of code in a hardware DSP might come cheap,
but cheaper than providing and mounting two 10 µF caps? Surely not? >:)

I can see why it might be done to save space in a widget like the thing I
linked to, but as a standard practise, I'd have thought it was not done. If
is, I guess it might explain why it's impossible to modify an Echo Layla 20
bit interface to take DC inputs. In that, there certainly is something
blocking DC on the ADC itself.
 
D

Dave Platt

Lostgallifreyan said:
Which would be annoying. I guess someone might have made a DirectShow
plugin that can full-wave-rectify a signal, that way I could get a unipolar
trace by filtering the rectified input from a 20 KHz oscillator whose
output amplitude is controlled by the signal I want to log. That defeats
the point though, I'm hoping that someone made a sound card that leaves
nothing more than removal of DC blocking caps as the only thing to do to
get a data logging input.

Incidentally, I know that a bit of code in a hardware DSP might come cheap,
but cheaper than providing and mounting two 10 µF caps? Surely not? >:)

Another issue is power. If I recall properly, power-over-USB provides
only a single supply. If you want to measure DC voltages which swing
below ground, you're going to either need some way of developing a
secondary, negative-rail voltage supply, or need an external bias
network (possibly with a buffer) to shift the voltage up into the
common-mode range of the single-power-supply USB chip.

Standard USB-for-audio-purposes adapters probably do the latter...
capacitor-couple the signal and then use a resistive ladder to shift
the centerpoint up to .5 Vcc.

That's probably cheaper than having to provide a second power supply
of some sort to the USB chip, so that its common-mode input range
extends well below ground.
 
S

Stef Mientki

Lostgallifreyan said:
Hi.
I just bought this thinger:
http://tinyurl.com/zloek
(USB full duplex audio 'card' probably based on Micronas IC)

Has anyone here played around with one? I was thinking that with a copy of
Sound Forge or similar app, a very very cheap realtime datalogger can be
made. The main sticking point would be DC blocking, which would have to be
removed.

Any thoughts?
isn't this a audio output only device ;-)

Stef Mientki
 
J

Joerg

Lostgallifreyan said:
Hi.
I just bought this thinger:
http://tinyurl.com/zloek
(USB full duplex audio 'card' probably based on Micronas IC)

Has anyone here played around with one? I was thinking that with a copy of
Sound Forge or similar app, a very very cheap realtime datalogger can be
made. The main sticking point would be DC blocking, which would have to be
removed.

Any thoughts?

The DC block for sound cards might be on-chip and then you are pretty
much stuck. A better option could be one of those TI EX430 kits. They
cost $20 and contain an MSP430F2013 which has a 16-bit ADC on board. No
DC blocking plus it's freely programmable.
 
L

Lostgallifreyan

The DC block for sound cards might be on-chip and then you are pretty
much stuck. A better option could be one of those TI EX430 kits. They
cost $20 and contain an MSP430F2013 which has a 16-bit ADC on board.
No DC blocking plus it's freely programmable.

Thankyou. That also answers my unanswered question in another thread, for
suggestions for a specific device with ADC and some space for code. You
wouldn't know one that also has 16 bit DAC in addition to that lot, would
you? I'd want one for making a log convertor for analog voltages, with a
gadget that makes the simplest and cheapest board layout possible.
 
L

Lostgallifreyan

isn't this a audio output only device ;-)

Stef Mientki

Nope :) Definitely input, one of those sockets is a stereo mic input. This
thing might not be suitable, as people have said, but that would be because
it's stuffed full of DSP I don't want and maybe can't bypass (although if
it IS the Micronas chip, it is apparently user controllable by some means I
don't know yet). I just want a cheap way to get 16 bit voltage conversion
in and out, and the USB idea is appealing. If I can get this in something
cheap and mass-produced, I will, there's no point in re-inventing the wheel
at inordinate expense..
 
J

Joerg

Lostgallifreyan wrote:

Thankyou. That also answers my unanswered question in another thread, for
suggestions for a specific device with ADC and some space for code. You
wouldn't know one that also has 16 bit DAC in addition to that lot, would
you? I'd want one for making a log convertor for analog voltages, with a
gadget that makes the simplest and cheapest board layout possible.

Not from the MSP430 series. Atmel or Microchip might have something but
I am not familiar with their devices, except for some 8051 family parts.
 
S

Stef Mientki

Lostgallifreyan said:
Thankyou. That also answers my unanswered question in another thread, for
suggestions for a specific device with ADC and some space for code. You
wouldn't know one that also has 16 bit DAC in addition to that lot, would
you? I'd want one for making a log convertor for analog voltages, with a
gadget that makes the simplest and cheapest board layout possible.
Texas has some of these chips,
if I remember well 24 bit ADC + ucontroler (8051?) + 20 bit dac in 1
device (maybe even a few ADC/DACs),
I just found out after making a log converter with separate components ;-)

Stef
 
J

Joerg

Lostgallifreyan said:
Nope :) Definitely input, one of those sockets is a stereo mic input. This
thing might not be suitable, as people have said, but that would be because
it's stuffed full of DSP I don't want and maybe can't bypass (although if
it IS the Micronas chip, it is apparently user controllable by some means I
don't know yet). I just want a cheap way to get 16 bit voltage conversion
in and out, and the USB idea is appealing. If I can get this in something
cheap and mass-produced, I will, there's no point in re-inventing the wheel
at inordinate expense..

There may be a quick and dirty option: Find out the highest frequency it
can process reliably and with enough dynamic range. Then chop the slow
input signal at that rate. A simple CMOS oscillator and a gate or FET
can do that. You may lose some bits but hey, if it's good enough it
might work.
 
L

Lostgallifreyan

There may be a quick and dirty option: Find out the highest frequency
it can process reliably and with enough dynamic range. Then chop the
slow input signal at that rate. A simple CMOS oscillator and a gate or
FET can do that. You may lose some bits but hey, if it's good enough
it might work.

Nice. :) I think that might just do it.

One other thing I'm thinking is that the HPF on an IC might be disabled, if
the IC designer was generous about this.

The Echo Layla 20 bit audio rack unit is a VERY tempting device for laser
scanner control and other things, monitoring laser power, general lab
monitor and control. Echo Audio kindly sent me the I/O datasheet in PDF.
I've found that the ADC is a Cirrus Logic CS5335-KSEP and with a bit of
fine surgery pin 1 can be made to control DC offset, and a DC blocking cap
can be bypassed. Currently, if I try to bypass the DC block cap, the result
is white noise in that channel, I have NO idea why, it really is odd, that
one..

If I can solve this, the CS5335 pin 1 will be a nice control, when low, it
tracks an onboard op-amp's DC output and cancels it, when high, it makes
the offset compensation freeze, so I can short an input, hold low for a
second, then raise high to eliminate any offset between the short and the
DAC input inside the CS5335, regardless of source, an extremely useful
feature. I hope the Micronas or similar IC in those cheap USB thingers can
be modified for this, but I suspect they might not provide a means to
bypass the HPF, even though they do apparently offer some control.

All this sounds tedious, but it beats having to build from scratch every
time, especially when 8 ins, 10 outs, at 20 bits or better (plus 2-channel
S/PDIF I/O at 24 bit), can frequently be found on eBay for £70 or so.
Beside the prospect of adapting that, all ideas of self-build look as
appetising as a pair of used boots on a plate.

Your fast-chopping idea is nice though, if it works, it won't matter what
the input processes are, at 20 bits I might still get to keep an accurate
16 bit log. These digital multi-channel things put out sync signals too, so
I guess if I can derive something from that I can reduce bit-loss by making
the chopper sample-accurate.
 
L

Lostgallifreyan

Texas has some of these chips,
if I remember well 24 bit ADC + ucontroler (8051?) + 20 bit dac in 1
device (maybe even a few ADC/DACs),
I just found out after making a log converter with separate components
;-)

Stef

That one sounds cool. Anything that takes the pain away... :) As I
mentioned in the big post a few minutes ago, it's usually far more
attractive to adapt existing commercial devices, given that there are so
many cheap ones, and surely some might be spectacularly useful if this
works.

I've looked at log convertors with analog parts, and decided not to try it
that way, though one analog log amp still IC interests me, the AD8307. An
8-pin DIL. The datasheet talks high, wide and plentiful about RF though, I
don't know enough to know if it could do DC for 3 octaves or so of accurate
freq-pitch scale conversion, and no-one's been able to tell me yet so this
one is still a mystery to me.
 
J

Joerg

Lostgallifreyan wrote:


My ISP's news server is dropping posts, some of which later pop up (like
yours right now). Would have answered sooner but couldn't see it.
Nice. :) I think that might just do it.

Basically this is modulating your input signal onto a carrier, the
chopping frequency being the carrier.

One other thing I'm thinking is that the HPF on an IC might be disabled, if
the IC designer was generous about this.

They usually aren't. They are after that one big market of audio capture
and anything else is peanuts to them from a business point of view.

The Echo Layla 20 bit audio rack unit is a VERY tempting device for laser
scanner control and other things, monitoring laser power, general lab
monitor and control. Echo Audio kindly sent me the I/O datasheet in PDF.
I've found that the ADC is a Cirrus Logic CS5335-KSEP and with a bit of
fine surgery pin 1 can be made to control DC offset, and a DC blocking cap
can be bypassed. Currently, if I try to bypass the DC block cap, the result
is white noise in that channel, I have NO idea why, it really is odd, that
one..

Look at the DC level on the other side of the cap with a scope. If it
isn't zero at all times (doubt that it is) then a bypass would force it
down and one or more bias levels could go out of whack. Once they are it
can take a longer time than expected to return to normal.

If I can solve this, the CS5335 pin 1 will be a nice control, when low, it
tracks an onboard op-amp's DC output and cancels it, when high, it makes
the offset compensation freeze, so I can short an input, hold low for a
second, then raise high to eliminate any offset between the short and the
DAC input inside the CS5335, regardless of source, an extremely useful
feature. I hope the Micronas or similar IC in those cheap USB thingers can
be modified for this, but I suspect they might not provide a means to
bypass the HPF, even though they do apparently offer some control.

All this sounds tedious, but it beats having to build from scratch every
time, especially when 8 ins, 10 outs, at 20 bits or better (plus 2-channel
S/PDIF I/O at 24 bit), can frequently be found on eBay for £70 or so.
Beside the prospect of adapting that, all ideas of self-build look as
appetising as a pair of used boots on a plate.

True. If you want to cheat and can spring about $400 then this one might
be a nice option:

http://www.labjack.com/labjack_ue9.html

Your fast-chopping idea is nice though, if it works, it won't matter what
the input processes are, at 20 bits I might still get to keep an accurate
16 bit log. These digital multi-channel things put out sync signals too, so
I guess if I can derive something from that I can reduce bit-loss by making
the chopper sample-accurate.

You can also synchronize with a nifty software PLL that "learns" when to
expect the sample. But that can run astray if the signal is too low for
a long time. As with building your own hardware that'll be a hassle you
just might not need right now.
 
L

Lostgallifreyan

Sorry about delay. :) That was a good post, so I wanted to return some effort.
http://tinyurl.com/mt97e is a direct link to a PNG file where I made a
diagram of the part of the circuit I need to change, including the simplest
modification I could make. It removes just one DC blocking capacitor in each
channel and uses three wires to connect 4 resistors and one op-amp stage to
mix the 2.2V reference to the incoming DC-coupled signal, feeding the mix
directly to the 2.2VDC side of the now-absent capacitor.

I might also try the chopper idea, as the 'word clock' output is regular
and always present. I wouldn't try to decode it in software if it's regular
enough, I'd just filter it to get a simple regular pattern and lock an analog
PLL to it if possible.

Please let me know if the proposed modification in the PNG file looks ok, or
might be bettered (bearing in mind the need to minimise to extreme any mods
made on the original board).

As mentioned in the PNG file's text, the ADC does allow direct coupling by
bypassing the DSP HPF it uses to block DC. Actually it either monitors it
and perpetually readjusts the output to compensate, or it freezes the offset
at the last known value. I mentioned that in some more detail in my previous
post in this subthread:
 
J

Joerg

Lostgallifreyan wrote:

Sorry about delay. :)


Well, it's my news server that does that sometimes.

... That was a good post, so I wanted to return some effort.
http://tinyurl.com/mt97e is a direct link to a PNG file where I made a
diagram of the part of the circuit I need to change, including the simplest
modification I could make. It removes just one DC blocking capacitor in each
channel and uses three wires to connect 4 resistors and one op-amp stage to
mix the 2.2V reference to the incoming DC-coupled signal, feeding the mix
directly to the 2.2VDC side of the now-absent capacitor.

I might also try the chopper idea, as the 'word clock' output is regular
and always present. I wouldn't try to decode it in software if it's regular
enough, I'd just filter it to get a simple regular pattern and lock an analog
PLL to it if possible.

Please let me know if the proposed modification in the PNG file looks ok, or
might be bettered (bearing in mind the need to minimise to extreme any mods
made on the original board).

It was a bit hard to see, maybe next time you could post a zoomed out
schematic (browsers are often bad at zooming). And add designators (R1,
R2...). :)

I'd drop the 10M input dividers to 1M, still shouldn't mess up your
bias. A concern: This opamp may not like it if you feed it just 5V
single supply. Also, IIRC it's input common mode range must stay about
1V away from its negative rail and if you grounded the neg supply this
is cutting it really close. You might want to make that new input
divider asymmetrical to push this a little higher.
 
L

Lostgallifreyan

Joerg said:
Lostgallifreyan wrote:




Well, it's my news server that does that sometimes.



It was a bit hard to see, maybe next time you could post a zoomed out
schematic (browsers are often bad at zooming). And add designators (R1,
R2...). :)

I'd drop the 10M input dividers to 1M, still shouldn't mess up your
bias. A concern: This opamp may not like it if you feed it just 5V
single supply. Also, IIRC it's input common mode range must stay about
1V away from its negative rail and if you grounded the neg supply this
is cutting it really close. You might want to make that new input
divider asymmetrical to push this a little higher.


I should have mentioned, the main circuit's op-amps are on a dual rail 15V
supply.
Sorry, that was definitely a gross oversight of mine, not showing that. About
the
resistors, I agree, I'd considered that too. I often reduce to 1M in situations
where
it first occurs to try the highest I have, things are usually more resilient to
induced
noise that way, and any error is more predictable. I did try shrinking the
image but
it made a pig's ear of the text, probably another dodgy decision to put it
there, but nm..
My main concern is whether there might be some horrible gotcha to look out for
when
using the non-inverting summing amp in this way. Also, the possiblity that some
vastly
superior answer might be staring me in the face while I can't see it. :)
 
J

Joerg

Lostgallifreyan wrote:

My main concern is whether there might be some horrible gotcha to look out for
when
using the non-inverting summing amp in this way. ...


Watch out for power sequencing. If your 15V supplies come on before that
of the CS5335 or if your opamp bias points aren't immediately stable
when those 15V rails come up the top right 150ohm resistor might source
up to 100mA into the AINL+ input. This could cause it to latch up or
fry. I don't know how much it could stomach, might be worth to think
about raising that resistors value.
 
L

Lostgallifreyan

Joerg said:
Lostgallifreyan wrote:




Watch out for power sequencing. If your 15V supplies come on before that
of the CS5335 or if your opamp bias points aren't immediately stable
when those 15V rails come up the top right 150ohm resistor might source
up to 100mA into the AINL+ input. This could cause it to latch up or
fry. I don't know how much it could stomach, might be worth to think
about raising that resistors value.

I'll trust that one :) That's a network the unit's maker applied right from the
IC maker's datasheet, two 150R resistors and a 2n2 cap. I'll tap the same
supply the main op-amp's getting, for my addition (though I'll maybe modify the
PSU slightly to carry the extra power, as some bits already get hot). I think
it will be ok, as the 2.2 V won't be doing anything it didn't already do
before, as the CS5335 sees it. I'm more cautious about that reference itself, I
think the CSS5335 sources it at a very low current, hence my initial choice of
10M for resistances on the adder input. I'm thinking of using the LF412, one
for each pair of channels, four IC's in all.
 
Top