New Estim powerbox design

Hello all!

I’ve been playing with the idea to design my own Estim powerbox. Finding this forum was the last push I needed to get my procrastinating ass on the job! I have a few design-features in mind, but it would be nice to hear from this community what else you can think of to be included in the design.

Today I will share with you the output stage of my design. This will be implemented as a module, meaning you can add as many of these modules to a power box as your heart desires (or I/O you have available).
It is a symmetrical output with some interesting features:

The same 42TL004 transformer as the MK312 is used but in a slightly different configuration. The current sinked through the transformer center tap is precisely controlled by a control-voltage (I_SET). And one of both windings is selected by the two control signals PULSE_P and PULSE_N.

This gives me two options to drive this configuration:
1.Set the I_SET voltage to control the power level and send pulse trains to the control signals. Pretty easy for software to do. I_SET voltage could even be a simple potentiometer.
2. Alternative it is possible to select a polarity by driving one of the control signals. Then generate an arbitrary wave on I_SET using a fast DAC.

Edit: Some diagrams for clarity.

Next up will be some SPICE simulations of this driver. And later I will get to the microcontroller, the communication and all the other bells and whistles.

Any feedback? Comments? Remarks? Let me know! :smiley:

the feedback driven current control is definitely smart approach. But I still believe the over-complicated ET-312 current control is there for a reason. Maybe you don’t want a constant current all the time - I don’t know I just assume Erostek engineers would try this idea first instead of doing their ADC->SW table->DAC thing.

Now the question… why? Do you want to make a multiple output 312 or something completely new?

Hi, thanks for your reply!
I see the ET-312 uses a DAC and buffer to drive a FET in it’s linear region and it then reads the current measurement back over a shunt into the MCU. This enables them to have a control-loop in software. That is definitely worth considering because it give a lot more flexibility to the control scheme.

Furthermore, I have been running SPICE simulations on this driver topology and the results are… underwhelming. Since the driver can only (actively) ramp-up the current and uses the freewheeling diode to (relatively slowly) ramp down. It just makes for a shitty asymmetric amplifier.

The reason I want to start building is simple: I like designing and building electronics!
A slightly different reason is that I wanted to make a bit more modern version of the things I have found here. Something compact using SMD components that uses a Li-Ion cell to drive some efficient DC/DC converters.
I also envision the output driver being built on a small separate PCB. That way I can experiment and swap out different drivers. Some other tinkerer could use this driver and experiment by wiring it up to an arduino.

I don’t think so. They create a lookup table only on power up. After that there is no real closed loop control. I guess the AVR ADC and DAC combo is way to slow for real time closed loop.

From my point of view there is no real issue with the output section - it might be too complicated but it works good enough.

I planned to make a “better” version of 312 with:

  • Better UI - graphic display and encoders - all parameters easily controlled from the main screen - no hidden menus.
  • STM32 micro with integrated DAC.
  • SD card (or USB stick) support for wav files - default waveforms are boring. And line-in is a hassle. And is hard to set up correctly because there is no signal saturation indicator.

Maybe in the future.

Does the lookup-table not cause the intensity to drift over time when the FETs heat up a bit?
Or maybe they rebuild the look-up table once in a while? I’m no expert on the MK312 firmware.

In any case, I reverted back to something that resembles the MK-312 topology more closely. This will be a good baseline for further experimenting.

This single channel output driver should be compatible with a MK312 controller (+DAC). Or some other MCU like an STM32.
By changing some resistor stuffing I can experiment with having a closed loop on the centre-tap voltage. Instead of an open-loop gate-voltage method of controlling the intensity. I also buffered and amplified the shunt voltage. That should give me some better signal at the MCU’s ADC.
I fitted everything on a 25x50mm board that can be used as a module to plug into a breadboard or a controller “motherboard” that I will design next.

Not without FW changes, check this thread: MK-312BT Failure 20
There is a fairly narrow window for the P-FET Vgs to fit in.

I am not sure if they are warm at all - I never used the stim without the enclosure. They are TO-220 devices they have a pretty good cooling capabilities even without a heatsink.
I look forward to see how these TO-236 packaged FETs will handle it. It is incredible how they can fit 2A / 192 mOhm device in such a small package.

I would maybe add some series resistors to FETs gates to eliminate the ringing but for such small FETs it is maybe not necessary.

To the schematic - keep in mind that “LVL_REF” will not be constant. Q1 will only create voltage drop when current flows.
There will be full voltage when Q2,3 are open.

I did some more SPICE simulations on my driver and made some (small) changes to the schematic.
However, I’m confident that this would still work with the stock firmware. Maybe it was not 100% clear in my schematic, but there is some room to play with the stuffing of the resistors. Also you’d need to find the correct values for the given FET you have so it sources the same current for the given MK-312 DAC code.

I do not fully understand what you mean here. LVL_REF is the reference-voltage of the DAC. LVL_REF should be driven with a low-impedance source, like the power-rail of that DAC. That way you can drive this circuit with a 5V DAC or even a 3,3V DAC. I plan to use the latter when combining with a ESP32 MCU.

I put everything in a github repo:

OK, my bad, I thought LVL_REF is an output from this circuit.

LVL_REF affects this feedback loop.

But the voltage at the Q1 drain is affected by Q2,3 switching.
Q1 wokrs in linear region… it is a “resistor”… there will be full “V+” voltage at Q1 drain when Q2,3 are off.
Because of this the U1A feedback loop will turn the Q1 off almost completely, because only current through R4 flows to the GND.

This means Q1 will be forced to oscillate synchronously with Q2,3.

Also maybe I am not thinking straight - aren’t U1A inputs reversed?

I think I forgot to mention some important caveat :flushed:: Not all resistors in the schematic should be stuffed.
There are two configurations:
Configuration 1: The MK312 style.

  • R2, R5, R6, R7 R8 = 100k
  • R9 = 200k
  • R4 and C2 are not stuffed.
    This configuration is just like the MK-312. The DAC will drive a gate voltage (referenced to GND) between 2.5 and 6.66V. So effectively using the P-fet as a rudimentary programmable resistor. The MCU can dan build that lookup table with the current feedback.

Configuration 2: Regulated voltage style

  • R7 = 0 ohm
  • R3, R9, R8 = 100k
  • R4 = 1k & C2 = 100nF
  • R5, R6, R2 not stuffed
    This turns the configuration into a rudimentary series voltage regulator. With the LVL input it is possible to set an arbitrary voltage at Q2 drain between 0v and V+. R4 will ensure a minimum load for regulation. And C2 will help stabilize. Then the MCU could build a lookup with the current shunt. Or it is possible to drive the configuration in a feedback loop on top of this. This configuration however is not compatible anymore with the stock MK312 firmware.

I do not know what driving method will yield be best results. Maybe they will be indistinguishable from each other. I would theorize that driving the centretap of the transformer to a controlled voltage is more robust over temperature and variations in V+ than driving a fixed Vgs on a mosfet. But experiments will confirm. :wink: