How I made my SMU - Page 1
Forum section: electronics / projects

author: jaromir
author_rank: Unknown
timestamp: August 14, 2021, 02:39:01 pm
content: I've been intrigued by SMUs for a long time, but since I've seen project of djerickson , I decided to give it a go. I put together bits from his schematics, added some of mine, wrote my firmware for both microcontrollers, made two revisions of PCBs, made my own transformer (it's surprisingly difficult to obtain materials for that) and here is the result. The component crisis in 2020/2021 made me re-evaluate a lot of components sitting in my junkboxes unused, so I decided to make use of them. Therefore, there is a few questionable component choices, but I totally don't feel bad for it. I'm glad the components got second chance to do something useful.Whole design, including manufacturing files is public on github  with picture dump at My design goal was to have an 4-quadrant SMU capable of delivering at least 100V and 100mA, with resolution on lowest range 1pA. That last one wasn't trivial, but it looks like the last digit on current measurement is reasonable. I can observe slight drift with temperature on the last digit, but for short term measurements it's perfectly usable.I have no definitive specs validation done, but it looks like after proper calibration it's better than 0,01% at source accuracy and even better and measurement. I tried to run a few more tests, for example linearity test - I observed output voltage, measured by SMU itself and external DMM (HP34401A), at 120V range. I can clearly see major component of the DAC quantization error (DAC is only 16-bit), but internal measurement is in much better agreement with HP34401A, see the attached picture.Right now I included this SMU into my instrumentation rack and I started to use it as everyday instrument, so I guess I'll do some more testing.Attached is also documentation package, slimmed down github snapshot at the time of writing(without Kicad PCB sources, those were too large for an attachment here, but available at github).https://www.eevblog.com/forum/projects/diy-smu-project/msg3391690/https://github.com/jaromir-sukuba/J-SMUhttps://imgur.com/a/rR8cIFG

author: justanothername
author_rank: Regular Contributor
timestamp: August 14, 2021, 04:38:12 pm
content: WOW!!

author: voltsandjolts
author_rank: Unknown
timestamp: August 14, 2021, 05:52:49 pm
content: Tidy schematics, tidy boards, tidy build, and well documented too. Very nicely done sir.Seriously tempted to have a go at building that.

author: Kleinstein
author_rank: Super Contributor
timestamp: August 14, 2021, 06:39:42 pm
content: Really impressive project.The linearity measurement looks a bit like there is some signal effecting the ADC reading where it should not. Otherwise I would have expected better matching between the 34401 and read back ADC. The OPA2333 to drive the ADC looks a bit odd: the OPA2333 is a very low power OP and relatively slow and thus not very good with pulse like loads from the ADC. The 1 nF cap at the output of the OP could also cause problems - though the ADC likes it.If DAC resolution/linearity is an issue, could it help to use the 4 th ADC channel (still unused) to read the DAC ouput ?The switching at the current reading shunts may have quite some leakage. With better parts availability I would have choosen DG21xB instead of DG444. There are some leakage paths parallel to the 2 M shunt, so some drift for the low current ranges is to be expeced.There may be a better configuration for shunt switching, though I know that this is a rather difficult part and always needs some compromises. The more brute force way would be to use relays, at least for the higher currents.

author: 2N3055
author_rank: Super Contributor
timestamp: August 14, 2021, 06:54:39 pm
content: Another great project from you... Really nice work...

author: Renate
author_rank: Super Contributor
timestamp: August 15, 2021, 01:35:42 pm
content: That's a very nice, professional build.(Although I would have preferred black-faced LED displays or a filter.)I did have to look up "Shmoo" as I've never heard that term.https://en.wikipedia.org/wiki/ShmooActually, I had already built the exact same thing (except for a few details).It is only 1 quadrant instead of 4 quadrant.It only goes to 12V instead of 100V.You set the voltage/current with trimpots instead of digital control.Still, it's good enough for my usages, battery eliminator on Android devices or USB power monitoring.

author: Kleinstein
author_rank: Super Contributor
timestamp: August 15, 2021, 05:23:14 pm
content: I looked a bit at the design and found a few point to note:The easy one is probably the value of C7 - chances are this are more like 2.2 µF and not 2.2 nF.The DAC seems to run at a gain of 2. This makes sense to make the convoltage to use a +-5 V range. It is a slightly hidden detail of the DAC.For the ADC, I have some trouble understanding how measuring negative voltages should work - the ADC may still have some option to measure relativ to the reference, or maybe a 2.5 V level at input 4 missing ?.The shunts for the 100 mA range may run quite hot. 200 mW for 4 relatively small resistors in close proximity is quite a bit of power.At least one OP could be a lower grade than the OPA140 shown for most OPs: U9 is inside the loop, directly at the power amplifier input and thus not all all critical with input offset, dirft or noise. So a simpler OP like TL071 should be OK there. I am not sure how much speed is needed, but I would not expect that much.The guard part may want a little extra protection: e.g. some ( ~ 10 V ?) zener / transorb to ground from the ouput of U21. Just 1 K to the output is not that much protection and could burn if accidently connected to the output or possibly ESD damage to U21.I don't think the regulator loop is especially fast - it is already difficult enough to get good stability with a wide range of currents and shunts. It would still be interesting to see how well the cross over from CC to CV mode and back is handeld, compared to a more convetional lab supply. The cross over / clamping before the frequency compensation / integration could be a nice idea.

author: xrunner
author_rank: Super Contributor
timestamp: August 15, 2021, 05:38:13 pm
content: Really nice job. Looks better than some commercial equipment I've run across.

author: jaromir
author_rank: Unknown
timestamp: August 15, 2021, 07:59:06 pm
content: Hi all,thanks for feedback. I really appreciate that.Kleinstein:- There is not much of a problem with DAC linearity for given purpose. Majority of the non-linearity is caused by non-zero step size of the DAC itself; it's 16-bit DAC and that's about it. There is one unused DAC channel, though, PCB has footprint (R72 on A1 PCB) for one more resistor to sum small amount of current into main setpoint. Currently this resistor is unpopulated, but could serve for more experiments, for example adjusting the DAC from ADC measured value, as ADC has muss less non-linearity than DAC. That would be another feedback loop, though. For now it's running in simple mode with no adjustments and it's OK for this application.- Yes, the DAC runs at 5V range. Also the ADC.- DG2xx versus DG4xx choice may have some influence, though from my measurements DG4xx and DG2xx switches are very similar in terms of leakage.- Negative measurements are possible by shifting the ADC amplifiers towards positive voltage. Resistors R66 and R68 on A1 board take care of this. When voltage on "hot" end of R67/R69 is zero (zero measured value), U25A/B are at 2,5V, with full swing few tens of milivolts less than 0-5V to have safety margin.- ESD protection on guard output is fair point. More protection is always welcome.- Yes, opamp choices could be different. Opamp market is wide (though those days the real availability is quite limited). The feedback loop is quite critical and I spent some time playing around it. Changing some opamps may bring financial savings (though not for me, because I already bought the existing components), but will mean to spend more time verifying all ranges and working modes of the SMU and perhaps some fine tuning of passive components.- I optimized the shunts, especially at 100mA range, because from thermal standpoint this is the hardest operating regime. I was interested how much drift will induce changing the current from zero to 100mA. Just for this reply I took quick measurement with HP34401A, see result on attached picture. Right after turning the SMU output on, deviation from setpoint was ~17ppm of range (1,7uA), increased to ~35ppm (3,5uA) after 80 samples (120 seconds) - I assume this is from self-heating - and kept relatively stable after it. The graph is intentionally in +-100pm range, to illustrate +-0,01% range. I don't have any more stable current source to determine how much from this drift is caused by HP34401A alone. I think majority of visible noise is caused by HP34401A, though.Mind that this is second revision of the PCB. The first revision had only two resistors in paralell, with slightly worse tempco and no copper planes, the overall non-stability was significantly worse, roughly 60ppm (0,006%) - this is close to my design goal (0,01%), so I reworked this.- Regarding feedback loop speed - this is always thing of a compromise. I set up the SMU on 100V range, with 9mA limit and attached 1kOhm resistor and oscilloscope to the output, please see attached oscilloscope trace. Majority of transient happens in first ~10-20us with slow slope towards setpoint, after ~200us the transient seem to be practically over. I've seen a few lab power supplies, even from A-grade vendors, having few orders of magnitude slower feedback loop.-----------------------Bottom line: To illustrate how I approached the design of this SMU - I set my goals, namely:* particular fraction of percent as setpoint accuracy,* output ranges,* UI choices,* availability of components (critical in 2021),* reasonable price for my hobby needs,* easy mechanical design. The whole thing is doable with single hand drill and usual hand tools.When I checked all marks with reasonable margin (it was not in the first design iteration and major rework of some PCBs was needed), I considered the design as finished and released it. There is always possibility of adding more features or improving the design, at the cost of postponing the actual design completion.

author: Kleinstein
author_rank: Super Contributor
timestamp: August 15, 2021, 09:03:00 pm
content: The difference from DG2xx and DG44x is at least there in the datasheet. The DG40x many be better than DG44x. The Dg44x are often offered as the low cost version. The problem is anyway that the limiting values are pretty loose and the typical values quite a bit better. So one may have to be prepared to worst case remove a bad chip.The drift in the current still looks quite good. Chances are you got lucky with the TC of the shunt resistor. The remark was also meant as a warning to other to build a similar circuit - those shunt is critical and should be high power and low in TC.The response for the CV to CC transient looks indeed quite good and fast. There is very little capacitance at the output (mainly the caps at the divider for the gates, so less than 1 nF). Compare this to often 100s of µF with some lab supplies (though at a higher current).I can imagine that it is tricky to get it stable with all the ranges and also for CC and CV mode. So I had expected a relatively moderate and not so fast response.For stability it may make a difference if the output stage has a little standing current. Currently it looks like a class B or very low current class AB ouput stage (depends on the transistor BE voltage). The rather high current through R12 and R13 may be to get some bias.

author: ali_asadzadeh
author_rank: Super Contributor
timestamp: August 16, 2021, 11:11:06 am
content: Tahnks for sharingI think if you add STM32 and TouchGFX, it would beat Keysight

author: Berni
author_rank: Super Contributor
timestamp: August 16, 2021, 11:15:14 am
content: Now that is really neat and tidy looking. Lot's of commercial products don't look half as tidy as this inside.Great work!

author: EEVblog
author_rank: Unknown
timestamp: August 16, 2021, 10:23:22 pm
content: Wow, this looks GREAT!I need to really dig into this and possibly build one

author: HighVoltage
author_rank: Super Contributor
timestamp: August 17, 2021, 09:01:08 am
content: Very impressive !And very well documented.Thanks for sharing this project with us.

author: Dave
author_rank: Super Contributor
timestamp: August 17, 2021, 08:58:14 pm
content: Very well made.I like how tidy your wiring inside is.

author: BFX
author_rank: Frequent Contributor
timestamp: August 18, 2021, 07:06:00 am
content: Great job!

author: djerickson
author_rank: Regular Contributor
timestamp: August 25, 2021, 08:35:31 pm
content: Nice work, Jaromir. I like what you've done, many good ideas. Great to see the design evolving. And no Touch-screen / TFT headaches.I switched from OPA140/2140 to OPA145/2145 for most of the precision amps. Similar DC specs, 5.5MHz instead 13MHz, which is fine. Lower cost and better availability.Dave Erickson

author: Badwolf
author_rank: Contributor
timestamp: October 17, 2021, 09:40:26 pm
content: Very nice job.How did you make the front side? I have been looking for a result as professional as yours for years.

author: jaromir
author_rank: Unknown
timestamp: October 17, 2021, 10:07:44 pm
content: Front and back side are made as 1,6mm PCB, no copper, black mask and white silkscreen, made in JLC PCB within the same order as other PCBs. Manufacturing files are available in github repository.

author: Bansci
author_rank: Contributor
timestamp: December 23, 2021, 07:35:34 pm
content: Absolutely brilliant work, both you and Dave, I'm very keen to try building a two channel unit for sweeping transistors and the like.Do you have any advice/guides on the transformer you wound? Dave suggests two electrostatic shields (mains and output), did you implement this? What kit did you need and how did you verify a good wind? I'll probably buy a transformer, but I'm intrigued at the idea of winding one.

author: Roehrenonkel
author_rank: Frequent Contributor
timestamp: December 25, 2021, 12:55:40 pm
content: Hi and merry christmas to all,kudos to Dave and Jaromir.On Jaromirs work i like the classic LED-display and it would fit in a 1U (44.45mm) 19"-case.Also the ADC-section with 32 Bits theoretical resolution is great.What i really miss is the remote-capability (SCPI).Idea for the transformer:No custom transformer needed if you use two trafos back to back.(Must have 2* 115V primary) The low-voltage-section (interstage)can be connected to case-ground for shielding.

author: Johnny10
author_rank: Frequent Contributor
timestamp: December 25, 2021, 02:10:26 pm
content: Wow is right!

author: Bansci
author_rank: Contributor
timestamp: December 25, 2021, 02:52:01 pm
content: Quote from: Roehrenonkel on December 25, 2021, 12:55:40 pmHe's done this, check out the youtube here:https://youtu.be/f8vA7snVf3MYou're right, its on the original design by Dave but not on this one.Quote from: Roehrenonkel on December 25, 2021, 12:55:40 pmGood idea for a pinch, I think I'm going to go one of two ways. I'm either going to try to design a switch-mode power supply to generate the rails (cheap, easy to stamp out, but noisy), or I'm going to wind a transformer as the more I look at it the more fun it seems.Answering my own question on transformer design, there's a BOM here:https://github.com/jaromir-sukuba/J-SMU/blob/master/bom/transformer.odsI've found a source for transformer parts in the EU:https://www.delatsch.com/product/e-i-transformer-laminations/The BOM says E32, which I've seen mean the external E width is 32mm, but confusingly I think this is a EI-96 and it corresponds to a 32mm core width. To check, I used the android TransCalc apphttps://play.google.com/store/apps/details?id=ru.avglab.transcalc&hl=en_US&gl=USI put in the winding voltages and currents from the BOM, and I get very close on the number of turns, 84% fill factor, but my min diameter wire is all a little bit larger. I am assuming a square core at the moment which might be my issue.So I'm fairly happy I can wind this now, I just wonder how the electrostatic shields were done. Was it copper tape between windings? Do you shield the 150V on both sides? I've seen that you use a dielectric sometimes and space the shields away from each other to prevent capacitative coupling. Any advice on this part would be welcome, as many Youtubers cover transformer winding but I haven't seen double shielding yet!Edit: Talking out loud here in the hope that someone corrects me, I've attached the calculation I did showing slightly larger winding wire diameters required, although I've might have assumed an incorrect parameter for the core.

author: jaromir
author_rank: Unknown
timestamp: December 25, 2021, 09:31:15 pm
content: Please find attached PDF file where I tried to draw the transformer cross-section as I made it.The bobbin has two sections. One is fully occupied by primary and its shielding, second section contains S3 as first layer. This secondary isn't shielded. On this secondary goes insulation layer (yellow mylar tape) on this goes secondary shielding. Both primary and secondary shieldings aren't just one layer of copper tape, but it forms "trench" where goes primary or S1 and S2. It's not difficult, but time consuming to make the shieldings - I guess there must be better way than hand-crafted copper foil origami. S1 and S2 are not shielded in between, because the are in the same "domain", I just take care of proper electrical insulation. What I tried to accomplish was minimal leakage current to mains PE. Therefore primary shielding is connected to PE and secondary goes to ground of main analog gruound, as per schematics. Transformer core is also connected to PE.Difference to your calculation is core height (or stack height) - I used 35mm, because that was the core and bobbin I had. Also notice I calculated the primary winding so that core flux is lower than usual 1T, I aimed at 0,85T. This lowers core losses (and therefore heat) as well as decreased stray fields.In this configuration I achieved a bit under 1uA p-p of ground leakage current, with mostly 50Hz component.This was my first time I made my own transformer. At the time I had no coil winder, but made the windings by hand, it took me roughly 6 hours of exhausting nonstop work. If I were to construct the transformer again I would:1, try to enclose the secondary from all sides. That could cut down the leakage some more.2, use coil winder. In the meantime I bought one for 50USD, with mechanical counter from usual asian source. I made another similar transformer with this counter, it took significantly less effort compared to this SMU transformer.3, use thicker wire for primary. I used 0,3mm, it's on the edge of calculated current density, 0,35 or 0,4mm would be more on the safe side.Or alternatively:4, ask professional company to make the transformer for me.Regarding SCPI - yes, in this area is my SMU lacking. For now the commands are quite "dumb" and more resembling sparse GPIB communication of 80's instruments rather than verbose SCPI commands. It served me quite well in my home test automation, but I agree having proper SCPI would be much easier to use.Fortunately changing this is a bit easier than changing the hardware and slowly I'm working on it, but I'm busy with other projects too - but it's definitely very high on my TODO list.

author: jaromir
author_rank: Unknown
timestamp: December 25, 2021, 09:35:18 pm
content: Quote from: Roehrenonkel on December 25, 2021, 12:55:40 pmYes, I was strongly inspired by K236 design - those reside in 19" form factor enclosure, I tried to cram it into smaller one.The ADC isn't fully used here, I just happen to have a few pieces left from other project. Cheaper ADC (LTC24xx for example) would fit perfectly here.I agree, SCPI is lacking, but I'm slowly working on it, see my previous reply.

author: Bansci
author_rank: Contributor
timestamp: December 26, 2021, 01:03:01 am
content: Quote from: jaromir on December 25, 2021, 09:31:15 pmThank you for such a comprehensive and well illustrated reply!A winding machine does indeed seem like a nesscessity, six hours of winding sounds very frustrating. I'm trying to find a local (UK) transformer EI lamination supplier but I've already ordered the NK-1 you speak of. I'm really inspired to try winding myself and to learn it so thank you again. The split bobbin seems like a nice way to separate the shields!

author: Roehrenonkel
author_rank: Frequent Contributor
timestamp: December 26, 2021, 01:06:11 pm
content: Hi Bansci and all,when winding a transformer yourself keep in mind not to build a short-circuit with the shield-foil.Start and end of the foil can be lead to the outside (for test purposes), but never connected together.Also i would highly recomend vacuum-impregnation/potting.And for the very best noise-reduction run it over an UPS (sine-wave of course),like the hardcore-hifi-freaks. ;-)))Will post my ideas regarding the output-connectors in Daves SMU-thread.

author: cnt
author_rank: Contributor
timestamp: December 27, 2021, 01:26:18 am
content: wow this is fantastic. I know its never the point but what do you think the BOM cost was?

author: Bansci
author_rank: Contributor
timestamp: December 27, 2021, 08:23:37 am
content: The original design this is based off has a BOM goal of $350.https://www.djerickson.com/diy_smu/

author: Bansci
author_rank: Contributor
timestamp: January 19, 2022, 09:08:08 pm
content: Jaromir, I've found a UK supplier of split bobbins, EI inserts, and I'm just putting together my order. It washttp://www.ascocomponents.co.uk/,who have very reasonable prices and small order quantities, you just have to email to get them. My winding machine has also arrived!I had a few questions I was hoping you'd help me with.(1) How did you avoid forming a shorted turn with your shielding? Did you insert paper to prevent a short while overlapping your copper tape, or did you leave a gap?(2) I plan to use kapton as insulation. Did you do this between windings and shields? Paranoid I can see isolation being needed everywhere, but actually I think we're nowhere near the enamel breakdown voltages...(2) I've seen this video on YouTube where the guy pots the transformer using bees waxhttps://youtu.be/K4VcmJIoNBA?t=1174I think he's winding a audio output/input transformer though.Did you pot your mains transformer? I'm tempted not to do this as I'm worried about it melting, but perhaps my transformer shouldn't get that hot anyway.Thanks again for all the detail you gave, I'm much more confident about buying/designing this transformer now and I'm really looking forward to developing this new skill.

author: Kleinstein
author_rank: Super Contributor
timestamp: January 19, 2022, 09:46:10 pm
content: Bees way is a bit low in the melting point. It may be OK for an audio transformer that on average is used only for low power.I would avoid potting, at least for the first few tries, till you know it is for sure working. Once pottet it would be had to fix.Oe could try something with a much higher melting point, like rosin, if needed to fix some wires in place.Idolation on both sides of the shield may be a good idea. It would also reduce the capacitance.

author: jaromir
author_rank: Unknown
timestamp: January 19, 2022, 10:22:45 pm
content: Bansci:I'm glad you found EI parts supplier. Those are hard to find nowadays.1, The shielding was quite laborious task. I left small gap in the shielding to prevent short circuit. Overlapping may be easier to do, if the overlapped part is insulated.I put one layer on insulation tape between shield and windings. Insulation of the magnet wire itself may be probably enough, but better safe than sorry. Enamel should withstand the voltage just fine, if not damaged - I was worried that can happen during hand winding.2, I used both classic "yellow mylar tape" and kapton tape in my transformers, with good results. Mind that mylar tape was made for this application, has known dielectric strength and somehow lower thickness - so perhaps it's preferred. Be careful with insulation thickness, it adds quite a lot to volume consumed on the bobbin. When buying insulation tape, buy rolls with various width, it makes life easier. Cutting narrow slices of a tape from wider one is PITA job.3, (you had point 2 twice). I did not pot the transformer, though I bought beeswax just for this purpose - it was fairly cheap, under 10EUR/kg at local beekeeper. My intent with potting was reducing transformer hum (by fixing parts that can move against each other in the magnetic field) and somehow improve cooling of the transformer. At the end I decided not to do this step, because mains hum was nearly inaudible (I had to drop a few drops of thin lacquer on outer EI laminations to "glue" them in place - still easy to disassemble if needed). Leaving it as is also let me back door for transformer modification - if any - as potting it makes repairs/modification difficult. Cooling doesn't seem to be a problem with my transformer.There are also dedicated synthetic transformer varnish solutions (those are usually even more PITA to disassemble). For ideal impregnation vacuum setup is probably needed, which is something I don't have anyway.

author: 8334455
author_rank: Newbie
timestamp: January 24, 2022, 01:29:30 am
content: Hi , exciting job, is there any update in your github? I'm expecting repeat your awesome work.

author: jaromir
author_rank: Unknown
timestamp: February 24, 2022, 08:28:01 pm
content: Right now I pushed new release of firmware into the repository -https://github.com/jaromir-sukuba/J-SMUMajor change is rework of USB communication, it works now via SCPI commands, unlike previous communication protocol similar to 'R2D2-talk' of older test gear. Apart from that, I refactored the code and made minor cleanups.Next update will include user and calibration quick manual.

author: RikV
author_rank: Regular Contributor
timestamp: February 24, 2022, 08:52:39 pm
content: Thanks Jaromir! I am anxious to see your approach on the calibration issue!

author: voltsandjolts
author_rank: Unknown
timestamp: August 07, 2025, 03:11:38 pm
content: Just pointing out minor documentation issue...The filesmu_interconnect.schdoesn't seem to be in the github repo, just the pdf copy.I think there is is small error in that file, as highlighted in attached picture;J1 and J4 should be 6W connection, and pins numbers on one of those connectors should be reversed.

author: robson2017
author_rank: Contributor
timestamp: October 12, 2025, 04:16:35 pm
content: Hi Jaromir,"Next update will include a user and calibration quick manual."Have you created this manual? If not, could you describe the calibration procedure?