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

  • Nuheara IQbuds² MAX Battery Replacement: Round 3

    Nuheara IQbuds² MAX Battery Replacement: Round 3

    The OEM lithium batteries in my Nuheara IQbuds² MAX not-really-hearing-aids lasted for about 2-½ years before needing replacement. Two more years pretty well did those in and I replaced them again without fanfare about a year ago.

    After replacing the 802050 pouch battery in the charging case and having discovered two spare LIR1654 batteries at the back of a workbench, I installed those and renewed the gaffer tape holding the earbuds together:

    Nuheara IQBudsMax2 - battery replacement
    Nuheara IQBudsMax2 – battery replacement

    The workbench stash also disgorged the old Varta LIR1654 batteries, but not the OEM ones, so a test session seemed in order:

    Lithium LIR1654
    Lithium LIR1654

    The Varta batteries (red and blue traces) are in sad shape, after two years of regular use and another three years idling in a small bag. The EEMB batteries (pink and cyan traces) are in better shape, despite their year of use, with the lower pair of traces showing their as-extracted charge and the upper three traces their just-charged capacity.

    They’re still doing better than their 0.4 W·hr nominal capacity, which is not to be sniffed at, particularly as the tester’s minimum 150 mA current presents a rather stiff load for a 100-ish mA·hr cell.

    This being a quick-n-dirty set of tests, a simple discharging “fixture” sufficed:

    LIR1654 battery discharge clamp
    LIR1654 battery discharge clamp

    The charging “fixture” wasn’t much fancier:

    LIR1654 battery charge clamp
    LIR1654 battery charge clamp

    The EEMB batteries are in the bag and may remain in good shape after two more years, ready for another tour in the earbuds when their relatives wear out.

  • Tour Easy: E-Bike Brake Sensor Installation

    Tour Easy: E-Bike Brake Sensor Installation

    Having verified the brake sensors work and with some idea of their actuation distances, installing them on Mary’s Tour Easy involved no more than:

    • Remove the fairing
    • Unwrap three spiral looms from All The Cables
    • Wrestle the Julet connectors apart
    • Plug in the new sensors
    • Stick the sensors in the proper locations
    • Verify proper brake operation
    • Rewrap the looms
    • Install the fairing

    The “proper location” put the actuation point about halfway between the brake lever’s released and pulled positions. Given that the previous sensors lacked indicators, I don’t know where their actuation point might have been, other than likely too close to their released position.

    A slideshow of the front brake lever positions:

    • Tour Easy LED brake sensor - front released
    • Tour Easy LED brake sensor - front activated
    • Tour Easy LED brake sensor - front pulled

    Similarly for the rear brake lever positions:

    • Tour Easy LED brake sensor - rear released
    • Tour Easy LED brake sensor - rear activated
    • Tour Easy LED brake sensor - rear pulled

    Obviously, the rear brake lever sensor has the “dim” LEDs.

    There’s not much to go wrong and the first ride was uneventful, so we’ll declare victory until the sensors or magnets shift their position, despite the wraps holding their wires to the brake cables.

    The magnets come from power toothbrush heads, encased in urethane adhesive in 3D printed mounts.

    Stipulated: I sometimes over-do things.

    However, I am absolutely not going to back down from saying the lashup shown in this screen grab from the sensor installation video is utterly and completely wrong:

    E-bike Brake Sensor - suggested installation
    E-bike Brake Sensor – suggested installation

    Do not get me started, you know how I am. OK?

  • E-Bike Brake Sensor Bench Check

    E-Bike Brake Sensor Bench Check

    A pair of brake sensors with LED indicators arrived and should improve the situation on Mary’s bike.

    The connector pinout, as seen looking into the jack on the controller side of the cable:

    Bafang Brake Sensor pinout
    Bafang Brake Sensor pinout

    Of course, one cannot depend on color codes, but now we know it uses a 5 V supply. Some rummaging produced a suitable (“Julet”) connector, a cutoff USB cable, and a USB power supply:

    Tour Easy LED brake sensor - bench test harness
    Tour Easy LED brake sensor – bench test harness

    You’ll note the sensor’s signal wire is blue, not white, but red = 5 VDC and black = common on both sides of the splice. This is not to be sniffed at.

    With the disk magnet (supplied with the sensors) oriented edgewise to the sensor, so the magnetic field is largely cancelled, the maximum separation allowing the sensor to remain On is about 7 mm:

    Tour Easy LED brake sensor - edge - max ON
    Tour Easy LED brake sensor – edge – max ON

    The minimum distance allowing it to be Off is 8 mm:

    Tour Easy LED brake sensor - edge - min OFF
    Tour Easy LED brake sensor – edge – min OFF

    Orienting the disk face-on to the sensor increases the distances, because the magnetic field is not cancelled out in that direction. Similarly, positioning the magnet either above or below the plane of the sensor changes the results.

    The maximum On distance is now 20 mm:

    Tour Easy LED brake sensor - side - max ON
    Tour Easy LED brake sensor – side – max ON

    The minimum Off distance is 22 mm:

    Tour Easy LED brake sensor - side - min OFF
    Tour Easy LED brake sensor – side – min OFF

    The other magnet has a similar field strength and the other sensor responds at nearly the same distances, so they’re reasonably matched.

    The LEDs are, however, not well matched: one sensor is much brighter than the other. I only have one connector, so I cannot show both in the same picture. These pictures have the same exposure (1/120 s and f/1.7), with the top sensor appearing in the previous pictures:

    E-bike Brake Sensors - LED Brightness comparison
    E-bike Brake Sensors – LED Brightness comparison

    The red LEDs show a similar difference. I’m certain this doesn’t rise to the level of a warranty claim, because, hey, maybe the brighter one should be dimmer.

    Now, to fit them on Mary’s bike …

  • Bafang Brake Sensor Magnet Re-Re-Realignment

    Bafang Brake Sensor Magnet Re-Re-Realignment

    Several years and realignments later, the brake sensors on Mary’s Tour Easy became slightly mobile on the foam tape holding them to the brake lever mounts and, of course, anything affecting the sensor position relative to the magnet inevitably makes it overly sensitive to the brake lever position.

    For unknown reasons, the DPC-18 displays devote zero pixels to the brake sensor status, so the only indication of a brake sensor being active is when the motor cuts out. This is not to be tolerated, particularly in traffic, so both the sensors and their magnets are now remounted on fresh tape with careful attention to proximity.

    The magnet is snugged against the sensor when the lever is released:

    Tour Easy brake sensor gap - released
    Tour Easy brake sensor gap – released

    The activation point is about a third of the way to the fully pulled position:

    Tour Easy brake sensor gap - braking
    Tour Easy brake sensor gap – braking

    I would prefer having the magnet move parallel to the sensor’s long axis, but that’s just not the way these levers work.

    The left-side sensor cable is now snugged to the brake cables to keep it out of harm’s way as she installs & removes the water reservoir on the handlebars under the fairing:

    Tour Easy brake sensor cable - left
    Tour Easy brake sensor cable – left

    For symmetry, the right-side sensor cable sports a similar tiedown:

    Tour Easy brake sensor cable - right
    Tour Easy brake sensor cable – right

    Having recently discovered brake sensors with integral LED status indicators, I plan to update that whole mess in the near future.

  • Water Heater Anode Rod Replacement

    Water Heater Anode Rod Replacement

    The Bradford White AeroTherm heat pump water heater that Came With The House™ has been running for three years. Based on previous experience with the same City of Poughkeepsie water, it was time for a look at the anode rod.

    Which, as always, required the Greatest Ratchet with a foot of extensions getting the 1-1/16 inch socket down to the rod:

    Water Heater Powered Anode - socket wrench
    Water Heater Powered Anode – socket wrench

    Remember to:

    • Turn off the water heater power
    • Shut off the inlet and outlet valves
    • Open the drain valve to relieve the tank pressure
    • Only then loosen the anode rod

    Seeing the first few inches justified extracting the rod:

    Water Heater Powered Anode - old rod top
    Water Heater Powered Anode – old rod top

    Due to low overhead clearance and inauspicious pipe locations, I had to hacksaw the bottom third off to extract the rod:

    Water Heater Powered Anode - old rod overview
    Water Heater Powered Anode – old rod overview

    Water Heater Powered Anode - old rod bottom
    Water Heater Powered Anode – old rod bottom

    With the rod out, draining a few gallons of water into a pan didn’t produce any notable gravel, so I didn’t do a complete flush. Much to my delight, the drain has a ball valve!

    Given that this is a fancy water heater and I no longer regard anode rod maintenance as a fun-filled activity, I installed a Corro-Protec powered anode rod for cathodic protection without all the crud:

    Water Heater Powered Anode - Corro-Protec parts
    Water Heater Powered Anode – Corro-Protec parts

    The wall wart proclaims 15 mA with a green LED indicating it’s hard at work:

    Water Heater Powered Anode - Corro-Protec wall wart
    Water Heater Powered Anode – Corro-Protec wall wart

    The data plate on the back reports 24VDC 15mA, but, being me, I poked at it with a handful of resistors:

    Corro-Protec power supply measurements
    Corro-Protec power supply measurements

    The electronics could be as simple as a 24 VDC wall wart feeding a 425 Ω series resistor and a transistor switch lighting the LED for currents a little over 6 mA.

    A quick ohmmeter check shows the powered rod electrode is open-circuit with respect to the tank, as it should be without much applied voltage. Applying +24 VDC from the wall wart drives 15 mA into the water: the rod is hard at work.

    I’ll take a look at it in a year or so just to see what’s going on in there …

  • Nuheara IQbuds² MAX Charging Case Battery Replacement

    Nuheara IQbuds² MAX Charging Case Battery Replacement

    After five years of daily use, the lithium battery in the charging case of my Nuheara IQbuds² MAX they’re-not-hearing-aids earbuds began absorbing far more energy during its overnight recharges than the usual 100-ish mA·hr. This isn’t unexpected and, of course, Nuheara specifically mentions their batteries are not replaceable, so just toss the earbuds in the e-waste stream and buy another set.

    Having already replaced the smaller and harder-working lithium batteries in the earbuds twice, that’s just useless information … and something of a challenge.

    So, we begin.

    The lower part of the hinged case holds all the good stuff, with that blank hump obviously covering a great place for a battery:

    Nuheara IQBudsMax2 charging case - overview
    Nuheara IQBudsMax2 charging case – overview

    The bands around the earbuds are strips of gaffer tape holding their halves together after replacing their batteries. In this application, gaffer tape works much better than duct tape.

    There being no obvious screws, wedging a thumbnail into the joint just above the Micro-B USB jack proved promising. Doing the same on the other side produced enough of a gap to force a flat steel blade in there; further prying popped the snaps (red):

    Nuheara IQBudsMax2 charging case - snaps and glues
    Nuheara IQBudsMax2 charging case – snaps and glues

    The green ovals mark places where the case halves were glued together, accounting for some of the struggle.

    The two neodymium magnets in the front corners grab similar magnets in the upper cover to hold the case closed. The two magnets along the front edge grab magnets in the earbuds to hold them in the pockets, with more magnets flanking the gold-ish pogo pins visible in the first picture for better connections. If you’re concerned about the health effects of static magnetic fields, get over it.

    The battery was glued in place, so the first position after cracking the case apart must look like this:

    Nuheara IQBudsMax2 charging case - pried open
    Nuheara IQBudsMax2 charging case – pried open

    Yes. Yes, that is five years of earwax. You’ll note the lack of a seal at the bottom of the tunnels guiding the foam earbud tips: any and all particles falling off the earbuds have a direct path to the interior of the case.

    Easing the battery from its restraints reveals the data plate:

    Nuheara IQBudsMax2 charging case - snap and glue locationsNuheara IQBudsMax2 charging case - 802050 lithium cell
    Nuheara IQBudsMax2 charging case – snap and glue locationsNuheara IQBudsMax2 charging case – 802050 lithium cell

    The reflections in the pouch’s now-curved upper surface show the battery has become a Spicy Pillow.

    Somewhat to my surprise, 802050 batteries are available from the usual sources.

    Unwrapping several layers of kapton tape exposed the battery protection PCB:

    Nuheara IQBudsMax2 charging case - battery management PCB
    Nuheara IQBudsMax2 charging case – battery management PCB

    Comfortingly, the DW01 topmark on the upper IC says it’s a battery protection IC and the 8205A topmark on the lower IC indicates a dual MOSFET switching the battery current off during shutdowns. I did not trace the circuitry, but the white wire might control the DW01 CS terminal.

    The solder side:

    Nuheara IQBudsMax2 charging case - BMS solder joints
    Nuheara IQBudsMax2 charging case – BMS solder joints

    The new battery had a similar protection PCB with two wires. Rather than argue the point, I snipped its (welded!) battery tabs and transplanted the Nuheara PCB to the new battery, adding 30 AWG jumpers because the new tabs were shorter than the old ones:

    Nuheara IQBudsMax2 charging case - new battery installed
    Nuheara IQBudsMax2 charging case – new battery installed

    The strangely empty space to the right of the battery is just big enough for the protection PCB and all the kapton wrappings. The various plastic tabs around the battery hold it in place, so I did not renew its glue.

    Similarly, the four case snaps do a great job of holding the halves together, so they’re not glued, either.

    An overnight charge brought the case back to life and it’s once again working fine. However, the earbuds may be due for their third battery refresh.

    I love a happy ending!

  • Sherline vs. LinuxCNC 2.9.8

    Sherline vs. LinuxCNC 2.9.8

    Notes on finally getting the Sherline CNC mill operating in its new home, with a suitable Axis startup image:

    Sherline setup 2026-06
    Sherline setup 2026-06

    The gray countertop from its former home sits on foam strips soaking up a slight warp with enough isolation to keep things quiet.

    The gantry required the usual fiddling to make the cable hoist the Z axis directly upward, with the orange flag on the counterweight barely visible below the monitor.

    I recently touched the box of precision XYZ positioners and there might be something useful, albeit grossly overqualified, in there to simplify dropping the laser pointer beam directly through the spindle bore.

    A clean installation of LinuxCNC 2.9.8 on an ancient Dell Optiplex 9020 proceeded smoothly. Installing x11vnc let the rest of the proceedings happen from upstairs in the Comfy Chair. For unknown reasons, vinagre works better than Reminna as a VNC client, after recalling F11 enters / exits fullscreen mode.

    The mesaflash utility accompanying LinuxCNC 2.9.8 did not recognize the Mesa 6i25 card. Fetching & compiling the most recent version (3.5.17) cleared that hump and flashed the bitmap:

    sudo mesaflash --verbose --device 5i25 --write 5i25/configs/hostmot2/5i25_prob_rfx2.bit
    

    The 6i25 wants to be known as a 5i25, with its jumpers in their default positions:

    Mesa 6i25 - jumper locations
    Mesa 6i25 – jumper locations

    For unknown reasons, the button originally known as btn-trigger became btn-joystick for a while and has now reverted to btn-trigger. It’s labeled 1 in the four-button cluster:

    Logitech Dual-Action Gamepad - relabeled
    Logitech Dual-Action Gamepad – relabeled

    Which required changing the pin name in the Kicad library component:

    Sherline HAL schematic - Logitech button 1 name
    Sherline HAL schematic – Logitech button 1 name

    Which required converting the old Kicad library format into the new Kicad library format, a completely automatic process without, AFAICT, any unpleasant side effects.

    The new name fed into the schematic as expected, after minor fumbling while re-adding the modified component and setting its annotation number:

    Sherline HAL schematic - Logitech AZ button logic
    Sherline HAL schematic – Logitech AZ button logic

    The X axis home microswitch has (apparently) become more bouncy while it was idle, so I increased the number of samples before HAL sees a change in that GPIO input:

    Sherline HAL schematic - home switch debounce
    Sherline HAL schematic – home switch debounce

    The dbounce block runs in the servo thread at 1 m per tick, so those 20 samples take all of 20 ms while the X axis moves 0.15 mm. At some point I should apply a scope to that switch, but for now It Just Works™.

    Considerably to my surprise, compiling the modified Kicad schematic into a HAL file proceeded without incident, despite various Python updates in the last five years.

    Kicad produces an “intermediate XML file” containing the netlist data intended for a conversion / export program, which is basically what my Kicad-to-HAL lashup does. I told Kicad to use Bash’s true command as a converter:

    Sherline HAL schematic - netlist export
    Sherline HAL schematic – netlist export

    So I can run the Kicad-to-HAL converter manually:

    python ../Kicad\ Conversion/Kicad-to-HAL.py Sherline\ HAL\ -\ Logitech\ Gamepad\ jogging.xml Sherline.hal
    

    You could tell Kicad to run it and it would probably Just Work™, but I’m used to peering at the results and dinking with my program.

    Which produced a new Sherline.hal file that Just Worked™ with the existing Sherline.ini file containing the configuration constants.

    The Sherline has cut only air so far, but, as the man said, “E pur si muove.”