Hi !
I'm still toying with the Bela alone, but I'm starting to want to couple it with my modular, specifically to get signals from it.
I'm not quite advanced on the electronics part. I know I have to bring down the current to 0-3.3V, and make it oscillates within this range if need be, and have a vague idea on how to achieve it, but maybe someone here already managed to do it and have some schematics to share ?
Thanks !
Eurorack Input
- Edited
Hi UlrichH ,
Be aware that not observing the absolute maximum voltage ratings when connecting an external voltage source to Bela inputs may permanently damage your Bela board and/or BeagleBone Black.
you can safely connect Bela's analog outputs to a modular synth already. These outputs have a range of 0V-5V, which should be able to control most modular synths (e.g.: if you have a 1V/oct oscillator, this gives you a 5-octave range).
No external electronic components are needed for this connection, just make sure:
- you connect each analog output to CV input you intend to control, and
- you make exactly ONE connection between the ground of your synth and a ground pin on Bela.
See here http://bela.io/belaDiagram/ where you can find a ground pin on Bela.
When connecting CV or signal outputs from your synth to Bela's analog inputs, you will want to make sure they are in the range 0-5V (though the usable range is only 0-4V for inputs). This can be done, e.g.: with a simple zener limiter
http://hyperphysics.phy-astr.gsu.edu/hbase/electronic/limiter.html combined, if needed, with a schottky diode which prevents the analog input from going below -0.3V.
When using digital I/O from Bela, care must be taken that the voltage on them is in the range 0-3.3V.
Again, protection circuits like the ones described above should be ok. Be aware, I would not expect digital outputs to be able to gate/trigger all synths, as often the gate voltage is 5V, while some other times it is -5V. In these cases, you may need external electronic components to shift/scale your levels.
To figure out voltage ranges for your modular:
- check your synth's documentation
- verify with a multimeter
- always use protection circuits if unsure
Also check out Giulio's video demo of interfacing with a Doepfer Dark Energy II using PureData:
https://www.youtube.com/watch?v=xAYvp6fVWBM
I've added the #Eurorack tag to this conversation to collate all discussions of Bela and analog synths - can't wait!
Thank you for the answer ! I've seen the video, I'll work on that. I'll come back here as I try things and hopefully succeed without burning my Bela (which is awesome by the way
This is a great idea. I haven't done it yet in BELA, but in other mcu (teensy, arduino, raspberry) and the points are always the same. A universal solution needs some compromise but you will certainly want to scale and offset the signals (maybe adding a pot for atenuate and one for scaling)
In a modular there are many different signals, which one are you targeting?
- Bipolar -5, 5V
- Unipolar CV type 0-5V
- Unipolar 0-10V
- Gates
Here are good ideas from the open source modules (Mutable Instruments)
https://www.muffwiggler.com/forum/viewtopic.php?t=123595&highlight=
I find good to use a voltage reference of -10V, an opamp in inverting configuration running from 3.3V rail MCP6002/4 and with a gain of 0.33 (150K and 50K for example), 100K resistor at the input, 1K at the output, 100nF capacitor in the opamp loop for stability... I will go for ordering a bunch of those opamps and experiment with the oscilloscope.
Hope it helps
Ideally, I would like to get audio signal, so - if I'm not mistaken - bipolar -5/5V. But I'm a true software guy, and have very little knowledge in electronics. I toyed with op-amps to get a line signal to eurorack levels, but that's it.
Ok, audio in that will be quite doable, you just have to attenuate your synth signal, either with a passive voltage divider or with a non-inverting opamp with gain (1/10) assuming your synth is delivering 10vpp.
I found some interesting things here:
http://masteringelectronicsdesign.com/design-a-bipolar-to-unipolar-converter/
http://masteringelectronicsdesign.com/bipolar-to-unipolar-converter-examples/
The second link provides what seems to be the perfect way to get bipolar signals from the Euro world.
I have now to figure out a safe way to source power from Eurorack busses (a nice way to do it here I think http://yusynth.net/Modular/Commun/STEINERVCF/Steiner-improved-sch.gif ) and to protect the circuitry against input/output wrongdoings and shortcirctuis when inserting jacks, and I'll be on my way to burn an Arduino
Great link. Scale and offset (like in software ;-)) For my modular I have such a collection of brands and modules that I need to fine tune everything so I will go with the variable offset and attenuator. I breadboard it yesterday, and wow, great. Something different compared to arduino, teensy and co, was the smoothness path from DC to Audio Rate. (Thanks BELA team). When I start to turn the frequency knob of my lfo/osc modulating a simple sine in bela there was that moment when I though: now it will come the staircase of digital sampling but it didn't. Instead the beautiful sidebands of the fm!
About power: that's an issue. Sourcing from the eurorack bus is not a good idea: you don't need a lot of current from the powerful 12/-12v rails, but you need a rock solid 5v that many cases don't have (well now doepfer psu3 has it) but then it is important to clean the power lines with inductors and stabilizing capacitors, well regulated voltage references, etc. Because of that, I think I will go as a spare unit with its own external power supply maybe 12v/2A and regulated everything in that box. (maybe generating the -12v as well).
How is your plan?
Have you seen this project: https://github.com/mxmxmx/terminal_tedium
- Edited
I was hoping to use the Eurorack to power the op-amp needed to mix the signals. But maybe I don't need it, as I don't need the negative voltage in this case ? I can get +5V from the Bela itself, also the 2.5V from a voltage divider. Is it how you've done it ?
For now, my plan is simple: to get the two interact in the most boring way possible without frying anything. So Modular -> Bela -> Headphones
Hypasus For the 5V you do not really need them from the power supply, I think, you would be happy (and better) with a voltage reference, which is spec'd to lower noise figures. You probably want an external one rather than Bela's. It is important that you DO NOT get the 2.5V from a 5V power supply that you are using to power some ICs, because that would get you horrible PSRR performance.
I am not sure about your specific modules, but if I am not wrong, usually ± 12V rails are already stabilized, so you would be happy with some large-ish electrolytics, while if you have something around ±15V or more, it could be unstabilized and you'd need an lm7812/lm7912 pair.
I am planning to go whith an external power source of 5V/2A then use one of these to get the +12/-12V
http://www.reichelt.de/Wandler-2-3-W/RD-0512D/3/index.html?ACTION=3&GROUPID=7254&ARTICLE=159031&OFFSET=16&SID=10V4-SQawQATIAAGK-oa872ff3fe9b1912606d67d12a866251573&LANGUAGE=EN
For the offset I will use an LM4040 rated a -10V.
A question: are the analogue outputs buffered?
- Edited
There are internal buffers in the DAC (AD5668) http://www.analog.com/media/en/technical-documentation/data-sheets/AD5628_5648_5668.pdf and then there are external 220ohm resistors in series with each analog out. Full schematics https://code.soundsoftware.ac.uk/attachments/download/1495/beaglert_cape_rev_A3.zip (the current board layout is slightly different, but electronically it is the same).
The RD-0512D seems a nice piece of kit, but don't you think the 150mV ripple is a bit too large? That is about -38dB, while an LM7812, for comparison, would normally come with about -70dB ...
- Edited
So I managed to interface an VCO to the Bela, and as @Hypasus said, it is amazing ! I'm using Supercollider to get the audio in, and everything sounds and works perfectly. I'll put it on hold for now though, I'm waiting for some components I didn't have so I can secure the inputs, then I'll start experimenting
I'm following your discussion with great interest. My signal is still a bit noisy. Can I blame it only on the "breadbording"/low grade components effect or a a better 5V source would improve it (as I'm dividing the 5V output of the Bela to get my 2.5 reference) ? Or both ?
Good news!
Difficult to say what the source of your noise is, without more details on your setup and on your noise.
Surely using Bela's 5V to passively obtain a 2.5V reference is not a good idea...
What is your current setup?
and
What is your noise like?
- Edited
It is basically the input of this one:
http://interface.khm.de/wp-content/uploads/2008/11/arduinoaudiofig1.gif
Except that now I'm getting my 2.5 from dividing the output of a 5V external power supply. And it is not a 4.7n but 100n, I don't have any other values at the moment...
It's not noise, it's more like interferences, discrete little spikes. Not continuous noise. I blame the dirty way of wiring all of it together, but I'm (surely) maybe wrong. I could record a gif of the scope if you want.
- Edited
100n should be fine, as long as it is not electrolytic ( I doubt they manufacture electrolytics in that range).
A pic of the scope could help, also some sort of frequency-domain representation would help. Ideally, you'll want to scope your 5V reference at the same time as your signal, to see if the noise comes from the 5V.
Let me see if I get this right: you connected one of the analog outputs from Bela to the "audio input" on the schematic and then connect "analog input 0" from the schematic to your VCO's CV input. Correct?
How are your grounds connected?
What is your external power supply like? Lots of 5V PSUs are switching and not necessarily well filtered, depending on the application they were designed for, but I would expect more like a 5-6kHz periodic signal from them rather than discrete spikes.
The other way around. The VCO output is the Audio Input, the Analog Input 0 is on the Bela. I get a wave of max 2.5Vpp centred around 2.5V, approximately.
So this is, in blue, the signal from the VCO with 2.5 from the PSU:
http://www.balladeenruaba.fr/blog/wp-content/uploads/2016/07/scope1.png
In red is just a phasor I made for reference.
Still in blue, the PSU with the signal unplugged:
http://www.balladeenruaba.fr/blog/wp-content/uploads/2016/07/scope2.png
Any advice for a better PSU ? I'll start looking on my own too
It looks like troubles with the PSU. Just to confirm, why don't you make one of the analog outputs output a constant voltage and connect it to your input, just to make sure you do not see any of those spikes?
I also like to "listen to the PSU": connect the PSU to an AC-coupled audio input (maybe put a few hundred ohms in series, just in case) and listen to it. The noise you hear there will leak into your signal.
You do not really need a PSU for this application, a voltage reference is all it takes. A few silicon diodes in series or a 4V zener would probably give you a stable enough reference (remember the analog input range is 0-4.096V), alternatively, look for a proper voltage reference IC. Also an LM7805 would probably be good enough for this application, but voltage references are less noisy and you do not need much current, so they are better suited. Note that stabilizers and references have up to 2V of dropout, so you need either a PSU with higher voltage or pick a low-dropout device. You can also try if you are lucky using one of the voltages available on the BBB, like the 3.3V on P9-3 and P9-4 (you will have to change your upper resistor in the divider to match the new voltage).
I have no recommendation about commercially available power supplies... but prices can be quickly become esoteric if you google for "audio power supply", at which point you are probably better off with a transformer, bridge rectifier, cap and LM78xx ...