The Smell of Molten Projects in the Morning

Ed Nisley's Blog: Shop notes, electronics, firmware, machinery, 3D printing, laser cuttery, and curiosities. Contents: 100% human thinking, 0% AI slop.

Category: Electronics Workbench

Electrical & Electronic gadgets

  • Astable Multivibrator: 2N7000 MOSFET First Light

    Taping a cardboard support under the soldering fixture helped hold all the parts in place:

    Astable - 2N7000 soldering
    Astable – 2N7000 soldering

    The struts fit neatly into an NP-BX1 battery holder and the circuit began blinking merrily:

    Astable - 2N7000 assembled
    Astable – 2N7000 assembled

    My photography hand is weak …

    The circuit schematic / layout resembles this:

    LED Schematic - MOSFET transistors
    LED Schematic – MOSFET transistors

    The missing 1 MΩ resistor at the LED would serve as a physical support to tether the loose end of the 100 (-ish) Ω resistor, which desperately needed some stabilization under the LED spider.

    The simulation says it should blink about every 4s:

    Astable - 2N7000 buffered - true model
    Astable – 2N7000 buffered – true model

    The 2N7000 MOSFETs use a SPICE model from the Motorola ON Semi downloads, although they behaved about the same way using the LTSpice 2N7002 model.

    It really does blink every 4s:

    Astable - 2N7000 overview
    Astable – 2N7000 overview

    The LED pulse width should be about 50 ms:

    Astable - 2N7000 buffered - LED current - true model
    Astable – 2N7000 buffered – LED current – true model

    The voltage at the bottom of the ballast resistor is directly proportional to the LED current:

    Astable - 2N7000 pulse detail
    Astable – 2N7000 pulse detail

    So the pulse is actually 80-ish ms, which is Close Enough™ for my purposes.

    The key advantage here is making both the astable’s period and the blink’s duration (roughly) proportional to the component values, so I can tweak them with some confidence the results will come out more-or-less right.

    I love it when a plan comes together!

     

     

  • Siglent SDM3045X Screen Shot File

    As with the Siglent SDS2304X oscilloscope, the SDM3045M multimeter delivers broken screen shot files over the network: the actual file size doesn’t match the BMP file size field, causing kvetching in subsequent use:

    [ed@shiitake tmp]$ lxi screenshot -a 192.168.1.41 -p siglent-sdm3000 test.bmp
    Saved screenshot image to test.bmp
    [ed@shiitake tmp]$ convert test.bmp test.png
    convert-im6.q16: length and filesize do not match `test.bmp' @ warning/bmp.c/ReadBMPImage/831.
    

    Files stored on a USB stick jammed into the meter’s front panel have the correct size, so it’s not clear where the fault lies.

    Because the files contain extra data following the (intact) image, it will display correctly:

    Astable - 2N7000 - IDSS cal
    Astable – 2N7000 – IDSS cal

    The BMP header contains the correct size at offset +0x02:

    lxi screenshot -a 192.168.1.41 -p siglent-sdm3000 test.bmp
    hexdump -C test.bmp | head
    00000000  42 4d 36 fa 05 00 00 00  00 00 36 00 00 00 28 00  |BM6.......6...(.|
    00000010  00 00 e0 01 00 00 10 01  00 00 01 00 18 00 00 00  |................|
    00000020  00 00 00 fa 05 00 00 00  00 00 00 00 00 00 00 00  |................|
    00000030  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
    

    The horizontal image size at +0x12 and vertical size at +0x6 are correct: the screen is 480×272 pixels. Each pixel has three bytes = 24 bits, as specified at +0x1C.

    So the file should contain 0x0005fa36 = 391734 bytes, but, as delivered, it’s much, much larger:

    ll --block-size=1 test.bmp
    -rw-rw-r-- 1 ed ed 1152054 Dec 26 08:45 test.bmp
    

    Oddly, 1552054 bytes is exactly the size the oscilloscope files should be. I have no explanation, although it looks like a copypasta error.

    As before, the simplest solution is to truncate the file and be done with it:

    #!/bin/bash
    lxi screenshot -a 192.168.1.41 -p siglent-sdm3000 /tmp/"$1".bmp
    truncate --size=391734 /tmp/"$1".bmp
    convert /tmp/"$1".bmp "$1".png
    echo Screenshot: "$1".png
    

    And then It Just Works:

    ~/bin/getsdm3045x.sh testfix
    Saved screenshot image to /tmp/testfix.bmp
    Screenshot: testfix.png
    

    Sheesh & similar remarks.

  • Astable Multivibrator: 2N7000 MOSFETs

    Some poking around revealed an astable multivibrator using now-obsolescent ZVNL110A MOSFET transistors. The key idea seems to be large gate resistors putting the DC operating point exactly at the voltage required to hold each transistor in the linear region, pretty much guaranteeing the astable will eventually start up.

    A bit of simulation suggests this variation ought to work:

    Astable - 2N7000 buffered
    Astable – 2N7000 buffered

    Well, after the kickstarter in the lower left shorts the transistor for millisecond to enforce some asymmetry, whereoupon the simulation ticks along just fine.

    The yellow trace shows the voltage across C2 ramping back and forth between ±1.3 V, with a period just over 4 s and almost exactly a 50% duty cycle: much better than the bipolar version, with sensible component values. As before, the cap sees both polarities, so an electrolytic cap isn’t appropriate.

    The red trace is the drain voltage at M2 (presumably, “M for MOSFET”, rather than a plebeian “Q” or “T”), which is firmly at 0 V when it’s ON and ramps upward as R4 pulls C1 higher to turn it even more firmly OFF.

    The green trace shows the LED current pulse when M2 turns ON at the end of each cycle. Rather than contort the astable into a very low duty cycle, I generate the pulse by dumping current through a smallish cap into the gate of M4. A few tens of milliseconds makes a perfectly serviceable blink and keeps the average current drain down around a milliamp or so.

    In between, M3 buffers the astable’s output to deliver enough current to C4. Without the buffer, the cap draws enough current to mess with the oscillations; that’s how I got backed into this corner.

    Figuring the LED at 20 mA for 50 ms, the astable at 10 µA, and the buffer at half of 40 µA, the average current of 1 mA comes entirely from the LED, so even a weak lithium camera battery should last a good long while.

    If the low average drain ekes 1000 mA·h from the battery, the LED should blink for a month or two before the battery shuts down.

  • Astable Multivibrator: 2N7000 MOSFET IDSS and Vthr Tests

    Building an astable multivibrator from MOSFETs for longer time constants and more reliable operation suggests I should know a bit more about their operation with minuscule currents and low voltages. I have a small stock of low-threshold ZVNL110A MOSFETs, but using something less obsolete seems in order.

    Dirt-cheap 2N7000 MOSFETs have a maximum IDSS around 1 µA at room temperature, which would be way too high in this situation; there wouldn’t be much difference between their ON and OFF states.

    The test setup is simplicity itself:

    2N7000 IDSS - calibration
    2N7000 IDSS – calibration

    The initial reading from a 4 V bench supply was 0.00 µA on the Siglent SDM3045, my best low-current meter, so I put a 10 MΩ resistor across the drain and source terminals:

    Astable - 2N7000 - IDSS cal
    Astable – 2N7000 – IDSS cal

    Close enough, particularly given the silver fourth band on that old carbon composition resistor and its no-doubt unclean surface.

    The rest of the 2N7000 MOSFETs have IDSS ≤ 10 nA, which you can’t distinguish from zero on that scale.

    The 2N7000 datasheet specs give a threshold voltage from 0.8 to 2.5 V for 1 mA drain current, bracketing a 2.1 V typical value, which would be too high for a nearly dead lithium cell.

    I calibrated the VGS(thr) current at 11 µA with a 348 kΩ resistor:

    2N7000 MOSFET Id cal
    2N7000 MOSFET Id cal

    Which produced 11.49 µA at 4 V, just as it should, so I plugged in a MOSFET and twiddled the trimpot for a nice round 10 µA:

    2N7000 MOSFET Vthr test
    2N7000 MOSFET Vthr test

    Most transistors conducted 10 µA with the gate at 1.42 V, with a few outliers spanning 50 mV on either side. Close enough and low enough!.

    Now, to conjure an astable.

  • Multimeter Probe Cable: FAIL

    A reasonably good silicone-wire multimeter probe set arrived last spring and has worked well enough (I thought, anyhow) for the usual voltage measurements, but recently failed while measuring a small current. We all know how this will turn out, but the details may be of some interest.

    Measuring the resistance from tip to plug located the fault to the black probe, after which I poked a pin through the insulation near the plug:

    Multimeter probe - diagnosis
    Multimeter probe – diagnosis

    The two leads near the bottom go to my shiny Siglent bench multimeter. Despite their similarity to the failed probes, I’m pretty sure Siglent has better QC (well, mostly).

    The probe’s resistance was near zero from the tip (offscreen to the left) to the pin and megohms from pin to plug (on the right). Figuring the wire worked loose, I pulled it away from the plug:

    Multimeter probe - disassembly 1
    Multimeter probe – disassembly 1

    Huh.

    Although I wouldn’t have trusted those probes anywhere near their alleged 1 kV rating, seeing that exposed copper-like substance was disconcerting.

    Hacking off the strain relief bushing around the wire got closer to the fault:

    Multimeter probe - disassembly 2
    Multimeter probe – disassembly 2

    And, finally, the problem becomes obvious:

    Multimeter probe - disassembly 3
    Multimeter probe – disassembly 3

    Yet Another Cold Solder Joint:

    Multimeter probe - cold solder joint
    Multimeter probe – cold solder joint

    Pulling a black banana plug from the heap, I decided to drill a proper hole to anchor the wire:

    Multimeter probe - drilling plug
    Multimeter probe – drilling plug

    Which looked like this afterward:

    Multimeter probe - soldered plug
    Multimeter probe – soldered plug

    And produced a strongly mismatched pair:

    Multimeter probe - repaired
    Multimeter probe – repaired

    Ain’t it amazing how much fun you can have for a few bucks, all delivered by eBay? [sigh]

  • Darlington Transistor Sorting

    A discussion of random numbers at Squidwrench brought those gamma ray detectors to the top of the heap, with the observation I probably needed a few more Darlington transistors:

    Darlington transistor - hFE sorting
    Darlington transistor – hFE sorting

    Sorting two lots of 50 transistors by gain kept me out of trouble for a while:

    Darlington transistors - sorted
    Darlington transistors – sorted

    Those are MPSA14 NPN and MPSA64 PNP transistors, with DC gains ranging from around the spec’s minimum 10 k spec all the way up to well over 100 k.

  • DSO150 Power Supplies: Bring the Noise!

    Finally getting around to measuring the boost converter between the 18650 lithium cell and the DSO150 oscilloscope:

    DSO150 - 18650 boost V - input output 100 mA-div
    DSO150 – 18650 boost V – input output 100 mA-div

    The yellow trace shows the booster output voltage is 9 VDC, as set by the twiddlepot, and doesn’t vary much under load. It has 200 mV ripple at 220 kHz, the booster’s switching frequency, which doesn’t induce any meaningful noise on the scope’s display, because it’s well outside the display bandwidth and well inside the voltage spec.

    The current traces are 100 mA/div from Tek Hall effect probes. The green trace is battery current to the booster, varying from 200 to 300 mA, averaging 250 mA. The cyan trace is DSO150 current from the booster, 75 mA min, 200 mA max, averaging 100 mA.

    The battery current is 2.5 × the scope current, the battery voltage is 1/2.5 × the scope voltage, and all is right with the world.

    Two multi-output wall warts (Powseed and Leapara, for whatever that’s worth) with a bag of right-angle tips just arrived and I gimmicked up a connection directly to the output:

    Powseed multi-voltage supply - hack-job test connection
    Powseed multi-voltage supply – hack-job test connection

    Which went to a 100 Ω dummy load drawing about the same current as the DSO150:

    Power supply load test - 100 ohm resistor
    Power supply load test – 100 ohm resistor

    Both seem to work OK, albeit with plenty of spiky noise:

    PowSeed Multi-Voltage Wart - 9 V 100 mA-div
    PowSeed Multi-Voltage Wart – 9 V 100 mA-div

    Much to my surprise, there’s no visible noise on the DSO150 display, surely because the scope’s bandwidth is nowhere near wide enough to grow that kind of grass.

    A power supply like that would convert the DSO150 into a bench instrument suitable for low frequency circuitry.