Audio input/output at 0..5v


#1

Id like to transfer audio rate signals in the 0..5v range into/out of Axoloti.
e.g. imagine say an oscillator as output, or feeding a audio signal 0..5v into to drive a env follower.
( 2 channels in and out is fine for now, I'm after a simple solution :wink:)

and wondered if anyone can point me in the right direction:

I see 2 options:
A) GPIO, this is 0. 3.3v, ive got a fair idea how to scale this to 0..5v.
has the advantage i can take as many channels as there are analog gpio. (and could multiplex for more, albeit reducing SR)
BUT, I see 2 issues
i) i think currently we can only drive gpio at k-rate, so I'm guessing id need to modify firmware? ive not looked yet, so this is just a 'feasible' or not question... will it have significant cpu impact due to extra io.
ii) i write an audio rate gpio in/out which i use instead of audio out, then use this in my patches,
pain to differentiate patches, but its ok.
will there be aliasing issues? as I don't have the codec which I suspect has anti aliasing filters?

B) take audio in/out RTS and scale the -1.3.. +1.3v to 0..5v, centred around 2.5v
no idea how to do this, i assume i need opamps, but cant find an obvious reference.
output is just adding +2.5, and amplifying by ~ 2xm no idea how to do this :slight_smile:
input, reduce by 2.5v, and scale by half, again no idea :slight_smile:

I'm assuming the codec wont allow me to just input/output 0...1.3v ? ie. do it in software?
also id be a bit concerned id send in a bit too much voltage, can cause damage.
(though I'd assume the audio input is protected to a higher peak to peak voltage, and will just clip?)

thoughts/suggestions?
thanks for any pointers
Mark

another side note...
i see the midi/power part of the board has 0..5v where it connects to the main part, if i chop off the part, can i use this to power axo from 0..5v?
(what would i need to do do disable usb , i.e. what do i connect to vbusend)
... its not a major thing, i can connect a 9v to barrel, but a bit tidier to drive it from 5v.


Suggestions for CV/gate out from Axoloti to new Euro-compatible Behringer Model D
Semi-modular hardware patch bay?
#2

ive got some ideas for (b), after finding a good video on opamps :slight_smile:


#3

Sorry cant help, but that guys is so nice :slight_smile:

He knows a thing or two :slight_smile:


#4

The actual scaling and offsetting of the -1.3 +1.3 to 0 5 is easy in itself using op amps. The trouble as far as I've been able to see it, is powering the opamps in the first place. If the reason you're doing it is to interface with Eurorack then you can power it from the it's +/-12 supply. If you're making it a stand alone thing you'll have to power it separately unless you want to look into sinle low power supply opamp stuff, which I'm not sure about.


#5

I don't know much about eurorack except that it helps to make synths, but couldn't you turn the audio signal into midi data, and send it to a Eurorack midi to CV converter like the followwing link, or is this in the wrong direction.. ?


#6

this is not for eurorack, a different project, details later :wink:

ok, on a breadboard ive got the basics working for audio out now...
for some reason (which I'm checking now), using the LM324 i had available (got TL072s on their way), I'm not getting rail to rail voltage though, on 5v. I'm getting clipping at around 3.6v, at 7.5v clipping at 6v.... this clip is not just amplication its also when moving the offset/vref.
anyway, I'm sure this can be ironed out, if not, just means i'll have to limit to 2.4vpp.

I started looking at the input side, this seems more difficult.

so i have 0...5v , centre 2.5v , i need to take this to +/-1.3.... i initially thought i can do the same, as above just in reverse i.e. move the vref to -1.3v (an as its an inverting config, i can easily scale) BUT the issue is i don't have a bipolar voltage source for the reference....
thoughts? how do i create a negative voltage for vref, to get back to into the ac dac range?

EDIT: ive found a max828 that creates a -ve voltage, is this whats needed, or am i barking up the wrong tree :wink:


#7

Have looked at a max828 circuit, it appears as though it should provide the negative voltage reference you are looking for.
Recomend however you test it to be sure it is outputting the correct voltage first.
You may even be able to find and buy a prebuilt circuit online.

There are alot of circuits on the intnet, not all of them work with a power supply, only batteries. This is where I have gotten confused in the past.
:grin:


#8

Thanks - I've had suggested a different solution which doesn't require a -ve supply, will report back after testing :slight_smile:

I'm also going order some mcp6002 for rail to rail output.

on the output I'm thinking i need to protect against plugging in a output , I guess just putting in a diode should work ?!
(I'm thinking the same for cv outputs ?)

One thing that would be be nice is for cv/audio to be switchable between in/out , but I've not seen a circuit which does this - I'm guessing she me how it 'knows' , so it can switch between amplifying in one direction and voltage dividing in the other - thoughts?


#9

I don't know anything about setting up "CV", I would have always thought you would want it only going one direction ?
However if whatever is sending and recieving the control votage, can do so also in reverse, then it should be possible but would realy need to understand the specifics involved when setting up, ("Not suggesting you advise me of the details as it is getting outside my scope of experience") but how it sends and recieves would define the relevant steps.
For example, if you are intending to send and recieve info on a single Axo pin, you would need to set it up so its state from input to output changes, in line with whatever relevant circuit is involved etc..
:grin:


#10

yeah, this is pretty much what I'm considering @Gavin

Ive seen 'modules' (usually like this) that the cv jack, can either be used for input or output, and then just in software you say which you want to use it for.
this is cool, because we only have (without multiplexing) a limited number of analog io on the axo, and for different patches you might want more or less inputs/outputs.

the axo board can cope with this, but obviously if you have scaling, then it would have to be bidirectional... (i.e. 3.3v to 5v, or 5v to 3.3v) and I'm assuming this needs to separate circuits?
saying that ive got some sparkfun level converters coming, and they are suppose to be bi-directional, so will give those a try. ( i'll also be able to see how they work for future reference)

EDIT: found schematics for level converter they use a bss138

anyway, i think I now have a solution for the audio input , a simple capacitor followed by a voltage divider (or diode clamp?) works as a DC to AC converter :slight_smile:

its all coming together slowly... the 'project' hopefully arrives next week, which gives me time to get a few parts (mainly rail to rail opamps)