Advertisements

Archive for category Machine Shop

Tour Easy: Ruggedized Zzipper Fairing Mount

After nigh onto 18 years, the pipe straps holding the Zzipper fairing struts to the handlebars of our Tour Easy recumbents finally shrugged off their plastic wraps:

Tour Easy Zzipper Fairing - OEM mount
Tour Easy Zzipper Fairing – OEM mount

Although they still worked, riding over broken pavement produced distinct rattles; alas, the roads around here feature plenty of broken pavement.

The solution is a rugged plastic block capped with aluminum plates to spread the clamping load:

Tour Easy Zzipper Fairing - block mount
Tour Easy Zzipper Fairing – block mount

The solid model is straightforward:

Zzipper Fairing - Strut Mount - solid model - Show view
Zzipper Fairing – Strut Mount – solid model – Show view

A slight bit of tinkering made the stack exactly the right height for 45 mm screws secured with nyloc nuts. No washers on either end, although that’s definitely in the nature of fine tuning.

The three sections print without support:

Zzipper Fairing - Strut Mount - solid model
Zzipper Fairing – Strut Mount – solid model

I reamed the smaller hole with a 3/8 inch drill to match the fairing strut rod. The as-printed larger hole fit the handlebar perfectly, although the first picture shows the tubing isn’t exactly round on the near side of the block, where it starts the outward bend toward the grips.

The cap plates cried out for CNC, but I simply traced two outlines of the block on 1/8 inch aluminum sheet, bandsawed near the line, introduced them to Mr Disk Sander for finishing & corner rounding, transfer-punched the holes from the plastic blocks, and drilled to suit:

Tour Easy Zzipper Fairing - clamp plates
Tour Easy Zzipper Fairing – clamp plates

Making two pairs of plates by hand counts as Quality Shop Time around here.

The first few rides confirm the fix: no rattles!

The OpenSCAD source code as a GitHub Gist:

Advertisements

, ,

2 Comments

DRV8825 Stepper Driver: Forcing Fast Decay Mode in a (Likely) Counterfeit Chip

The DRV8825 stepper driver chip defaults to mixed decay mode, which TI defines thusly:

Mixed decay mode begins as fast decay, but at a fixed period of time (75% of the PWM cycle) switches to slow decay mode for the remainder of the fixed PWM period. This occurs only if the current through the winding is decreasing (per the indexer step table); if the current is increasing, then slow decay is used.

The 24 V supply on the CNC 3018-Pro provides too much voltage for the motors, because slow decay mode can’t handle those rising slopes:

3018 XY - Mixed Fast - 24V - 10mm-min 12V 1A-div
3018 XY – Mixed Fast – 24V – 10mm-min 12V 1A-div

Note that “rising” means the current increases with either polarity from 0 A at the midline. The DRV8825 uses a MOSFET H-bridge to drive winding current in either direction from the +24 V motor supply voltage.

Both traces show motor winding current at 1 A/div, with the XY axes creeping along at 10 mm/min (thus, 7.1 mm/min each). The upper trace is the X axis, with a stock DRV8825 module in mixed decay mode. The lower trace is the Y axis, with its DRV8825 hacked into fast decay mode.

The basic problem, about which more later, comes from the current rising too fast during each PWM cycle:

V = L di/dt
di/dt = 24 V / 3 mH = 8 kA/s

The first 1:32 microstep away from 0 calls for 5% of max current = 50 mA at a 1 A peak. The DRV8825 datasheet says the PWM typically runs at 30 kHz = 33 µs/cycle, during which the current will change by 270 mA:

267 mA = 8 kA/s × 33.3 µs

Some preliminary measurements suggest these (probably counterfeit) DRV8825 chips actually run at 16 kHz = 66 µs/cycle:

3018 X - ripple 1 step - 18V - A0 B-90 500mA-div
3018 X – ripple 1 step – 18V – A0 B-90 500mA-div

During those cycles the current can increase by more than 500 mA. The first scope picture shows an abrupt increase to maybe 700 mA, so, yeah, that’s about right.

Having the wrong current in one winding means the motor isn’t positioned correctly during those microsteps. The 3018-Pro runs at (an absurd) 1600 µstep/mm, so being off by even a full step isn’t big deal in terms of positioning.

The real problem comes from running nearly 1 A through both windings. Those little motors run really hot: they’re dissipating twice what they should be.

Anyhow, the pin layout shows the DRV8825 DECAY mode selection on pin 19:

DRV8825 pinout
DRV8825 pinout

Which sits on an inconveniently skinny little PCB pad, fifth from the left on the bottom:

DRV8825 PCB - open Decay pin
DRV8825 PCB – open Decay pin

Memo to Self: Don’t make that mistake when you lay out a PCB. Always put a little pad or via on a disconnected pin, so as to have a hand-soldering target big enough to work with.

The objective is to pull the pin high:

DRV8825 DECAY pin settings
DRV8825 DECAY pin settings

Pin 15, in the lower left corner, provides the output of a 3.3 V linear regulator, with its PCB trace connected to the left side of the ceramic cap:

DRV8825 PCB - Decay pin wired low
DRV8825 PCB – Decay pin wired low

On the scale of TSSOP packages, even 30 AWG Wire-Wrap wire looks like a bus bar!

Those are two different PCBs. The crappy TI logos, not easily visible in those low-res pix, on both ICs suggest they’re by-now-typical counterfeits, so seeing a factor-of-two difference in PWM frequency isn’t surprising.

, , ,

Leave a comment

CNC 3018-Pro: GRBL Configuration

The CNC 3018-Pro router arrived with GRBL 1.1f installed on the Camtool V3.3 board and ran well enough, although it accelerated very slowly. After installing Home switches, figuring out the travel limits, and trying different speeds & accelerations, it runs much better:

3018 CNC - Endstop switches - overview
3018 CNC – Endstop switches – overview

Configuration values to remember for next time:

$1=100 turns off the stepper motor drivers after 100 ms of inactivity:

3018 X - 100ms timeout - 100mm-min 12V 500 ma-div
3018 X – 100ms timeout – 100mm-min 12V 500 ma-div

There’s no force worth mentioning on a diamond scribe when the motors stop, so there’s no reason to keep them energized, and the DRV8825 chips resume from the same microstep when re-enabled.

$3=5 reverses the X and Z motor rotation, so you can use the same type of cable on all three axes and have them move the way you’d expect.

$20=1 turns on Soft Limits, thereby producing an error when you (or the G-Code) tries to move beyond the machine’s limits, as defined by the $120 $121 $122 values relative to the Home switch positions.

$21=0 leaves Hard Limits off, because I didn’t see much point in switches on both ends of all the axes for this little bitty machine.

$22=1 enables the Home cycle, after which you must start each session by homing the machine.

$27=1.000 sets the Pull-off distance from all three Home positions, so the machine ends up at absolute XYZ = -1.000 mm relative to the switch trip points after homing. This depends on the mechanics of the limit switches, but seems OK with the MBI-style switches I used:

3018 CNC - X axis endstop - 1 mm pull-off
3018 CNC – X axis endstop – 1 mm pull-off

$100 $101 $102 = 1600 set the XYZ step/mm, which requires knowing the 3018-Pro uses two-start leadscrews with a 2 mm pitch = 4 mm lead:

3018 CNC - two-start leadscrew
3018 CNC – two-start leadscrew

The Camtool V3.3 board hardwires the DRV8825 stepper controllers into 32 microstep mode, so:

1600 step/mm = (200 full step/rev) × (32 microstep/full step) / (4 mm/rev)

$110 $111 $112 = 1100 set the maximum speed along the XYZ axes in mm/min. Note the hard upper limit set by the maximum microcontroller interrupt rate of about 40 k/s:

1500 mm/min = 25 mm/s = (40×10³ step/s) / (1600 step/mm)

I’ll have more to say about speed limits, stepper current, torque, and similar topics.

$120 $121 $122 = 3000 set the acceleration along the XYZ axes in mm/sec². These are two orders of magnitude higher than the default acceleration, which accounts for the as-received sluggish acceleration.

$130=299.000 $131=179.000 $132=44.000 set the XYZ travel limits relative to the Home switch trip points, which feed into the $20=1 Soft Limits. You could probably eke out another millimeter along each axis, but this is what I came up with.

With all those in place, the G54 coordinate system puts the XY origin dead in the middle of the platform and the Z origin a little bit below its upper travel limit. Set them thusly:

G10 L2 P1 X-147 Y-90.6 Z-1.5

The original and tweaked GRBL configuration settings as a GitHub Gist:

The as-shipped configuration is mostly for reference, but ya never know when it might come in handy.

, ,

Leave a comment

Michelin Protek Tube: Another Slow Leak

After a few days of topping off the rear tire on Mary’s bike, with no gashes or debris in the tire, I finally replaced the Michelin Protek tube and autopsied it:

Michelin Protek tube autopsy
Michelin Protek tube autopsy

While it’s possible to extract the valve and perhaps even clean / replace it, I think that’s just delaying the inevitable. The rubber shreds may be necessary to fill large punctures, but they seem to wreck the valve seal.

Her bike now has an ordinary (pronounced “cheap”) tube inside the Schwalbe Marathon Plus armored tire. We’ll see how long this lasts.

2 Comments

Raspberry Pi vs. MicroSD: Another One Bites the Dust

The Raspberry Pi running the MPCNC recently seized up with baffling symptoms, which generally indicates the poor little MicroSD card serving as a “hard disk” has failed:

Defunct Sandisk Ultra 32 GB MicroSD
Defunct Sandisk Ultra 32 GB MicroSD

I managed to open a terminal emulator, whereupon all of the non-built-in shell commands couldn’t be found.

Proceed as before: binary-copy the entire MicroSD card to another one, pop it in the RPi, and it’s all good again.

For the record, the new card is an unused Samsung Evo Plus. I do not understand the difference between the “Evo Plus” and “Evo+” branding, other than to suspect one of being a very good fake.

In round numbers, MicroSD cards seem to last a year under what seems like not-too-demanding service; I’m not running the MPCNC all day, every day.

, ,

2 Comments

Bathroom Drain Rod Status

The bathroom drain rod slipped out of the pop-up stopper, giving me the opportunity to see how well it’s surviving:

Bathroom drain lever - 2019-08-03
Bathroom drain lever – 2019-08-03

After not quite two years, it’s not obviously rotting away.

Life is good …

,

Leave a comment

Logitech “QuickCam Pro 5000” Ball Camera Disassembly

Another alignment camera contestant from the Big Box o’ Junk Cameras:

Logitech Pro 5000 Ball Camera - overview
Logitech Pro 5000 Ball Camera – overview

It’s a Logitech QuickCam Pro 5000 with a native 640×480 resolution. For no obvious reason, it seems to work better on a Raspberry Pi than the Logitech QuickCam for Notebooks Deluxe I ripped apart a few weeks ago, where “better” is defined as “shows a stable image”. I have no explanation for anything.

Remove the weird bendy foot-like object by pulling straight out, then remove the single screw from the deep hole visible just behind the dent in the top picture:

Logitech Pro 5000 Ball Camera - disassembled
Logitech Pro 5000 Ball Camera – disassembled

The stylin’ curved plate on the top holds the microphone and a button, neither of which will be of use in its future life. Unplug and discard, leaving the USB cable as the only remaining connection:

Logitech Pro 5000 Ball Camera - USB connector
Logitech Pro 5000 Ball Camera – USB connector

Inexplicably, the cable shield is soldered to the PCB, so the connector doesn’t do much good. Hack the molded ball off of the cable with a diagonal cutter & razor knife, taking more care than I did to not gouge the cable insulation.

A glue dot locks the focusing threads:

Logitech Pro 5000 Ball Camera - focus glue
Logitech Pro 5000 Ball Camera – focus glue

Gentle suasion with a needle nose pliers pops the dot, leaving the lens free to focus on objects much closer than infinity:

Logitech QuickCam Pro 5000 - short focus
Logitech QuickCam Pro 5000 – short focus

Now, to conjure a simpleminded mount …

,

Leave a comment