eurorack: what to do with digital inputs

flok

Well-known member
Hi,

Couldn't find a kit or ready made eurorack-to-teensy thing, so I'm now developing one myself.
The first attempt only has a DAC and an ADC that accept -5...+5 Volt - the pcb arrived today! I'm writing my efforts down on https://nurdspace.nl/Teensy_4.1_to_eurorack

Now only days after I sent the gerbers to JLCPCB, I realised that digital I/O would be nice as well. Should not be problematic I thought: just connect a jack-socket to an I/O-pin & GND. But it should be protected against shorts (for output): that can be solved with an 1 kOhm resistor. But then I also need to protect against +5 V going into it, or even -5 V - two diodes? And what about digital input? Maybe that's easier: only a diode to protect against negative voltages. But then there's also voltages higher than 5V. Oh and I forgot: the teensy doesn't like 5V, so I should add a voltage divider - for each pin? Isn't there a smarter way?
I'm aiming at a low component count and only through-hole components.
All help is welcome!
 
In cases where a user might do something stupid, I’d tend to go for an opto isolator. You should be able to find a fast enough one with several channels in surface mount, I’d’ve thought.
 
In cases where a user might do something stupid, I’d tend to go for an opto isolator. You should be able to find a fast enough one with several channels in surface mount, I’d’ve thought.
Oh indeed! Didn't think of that! I've still got quite a few of those from experiments with MIDI. Cool.
 
Does it make sense to put an opamp voltage follower in front of the output-pins?
 
It definitely makes sense to protect the Teensy pins, and an opamp gives you the opportunity to shift the levels if needed. I’m not familiar with Eurorack stuff so not sure what might be needed…
 
A resistor between the external signal and Teensy (or whatever other circuitry) is the main thing you need. Diodes to clamp the voltage also help, but they're far more effective if a resistor limits the amount of current. The input pins have tiny clamping diodes built it, meant for small ESD, but they're extremely small so they can only handle pretty low current. If the resistor is a high enough value, they're probably enough.

If you're willing to add a chip and more parts, consider a LM339 or similar voltage comparator. These parts are like opamps, but they're meant to give a digital output rather than analog. Best way uses 4 resistors per input.

1793103194292.png


You'll also need a resistor from the input to GND, because this circuit will "float" with a positive voltage if the input is unconnected.

The voltage at the the - input defines the threshold. The ratio of feedback resistor (1M) vs the pullup resistor (4.7K) defines the amount of hysteresis. If you want a very precise sharp threshold, just leave out the feedback resistor. But the sharper the threshold, if the input signal has even slight noise or undesired modulation, you risk the output rapidly switching between on-off-on-off-etc when the input voltage is right near the threshold. Even a tiny amount of hysteresis turns your threshold into a small window which gives a much more stable output. Good control of hysteresis is the huge advantage you get from using a part like LM339.

FWIW, this circuit is from Ornament and Crime. Lots of other stuff in there for using Teensy with Eurorack synth.
 
Well, soldered the pcb, plugged in the teensy 4.1 etc. Smoke test: some ics (opamp at least) became very hot very quickly so I think I made a mistake somewhere :-/ If someone is willing to take a look at the schematics, please let me know. I'm a software developer by day so I can easily made a stupid mistake somewhere.

1793430161651.png
 
I can't see what's wrong, but if you're stuck I would recommend pulling the ADC and DAC chips and install fresh opamps. If the opamp still gets burning hot, at least you'll know to focus on just its circuitry. And if not, then you'll know to focus on how parts (don't) work together.
 
Have you connected low-impedance headphones by any chance? The TL074 is not really designed to drive headphones.
Just a shot in the dark.
 
@Paul will do! still waiting for a batch to arrive from $somecountry :) I pulled the ones I used from an other device, maybe that damaged them.

@Mcu32 the whole setup is meant to be used for "eurorack modulair synthesizers", so output does not go directly in a headphone, but via an amplifier first.

@Pio I don't think so no, the red wire is -12 V, so that is fine

I also thought that I just did the input wrong, but that is not the case according to the simulation in falstad: https://www.falstad.com/s.py?s=mDJm0H In this schematic the AC is the input (via the jack sockets), the +5 is the maximum voltage it should do.



a bit later:

Ok, so I removed the DAC and ADC and the opamps did not get hot. I put back the DAC/ADC, power on: not hot. Then I remembered that I had a "pyrometer" in my storage. With that I measured the maximum temperature to be 26,8 degrees celcius (80 fahrenheit). Installed the T4.1 with power attached: 26,8 too! No magic smoke either.

🤔

So what is possible:
* my thermometer is broken (my skin is 33,2 it says, with environment temperature 18,7 so I think it works correct)
* reseating the dac/adc fixed it
* it did not get hot in the first place: the thermometer in my fingers was confused maybe?

Lessons learned: always measure with a real thermometer and don't panic. Oh and get a working multimeter to verify assumptions.
 
Ha, one other bug: the dac produces 2.048 V, not 3.3 V as I expected. It can do 4.048 but only if given 5 V VCC - that is easy to fix with some resistor changes.
 
Last edited:
Back
Top