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.

Author: Ed

  • OpenOffice 3.2 Graphics Cache Settings

    The default OpenOffice 3.2 graphics cache is probably large enough for ordinary documents. However, I put together a 9-page illustrated biography for a birthday party last year using (most likely) OOo 3.1 and that file dragged OOo 3.2 to its knees.

    The default cache settings are something like

    • 20 MB
    • 2 MB per object
    • 20 objects

    Crank those to

    • 256 MB
    • 5 MB per object
    • 50 objects

    Much better!

    I’m sure that depends on what you’re doing and how much memory your PC has, but when OOo gets really pokey on a graphics-intensive document, check the cache.

  • HT GPS + Audio: Battery Pack Contacts the CNC Way

    Flattening the screw head
    Flattening the screw head

    Faced with the daunting prospect of converting half a dozen 4-40 brass screws into battery contacts by hand filing, I did what I should have done in the first place: turn it into a CNC project.

    It’s quick-n-easy:

    • mill the head flat and 0.5 mm thick
    • shave off the sides

    I grabbed the screw in the Sherline vise, touched off XY on the head (close enough to being concentric for this purpose), and touched off Z on the nut supporting the screw. For the next few, I’ll eyeball the Z touchoff at the bottom of the head, rather than the nut, because the heads don’t quite sit flush on the nut.

    They dropped right into place, without any filing or fiddling! Well, the second one did. I had to tweak the dimensions slightly to make the answer come out right. But that’s one of the advantage of hammering out simple G-Code like this: change two lines and wham you’re done.

    Contacts in place
    Contacts in place

    The heads show some tool marks, but that’ll just make the silver solder stick better. Right?

    Herewith, the G-Code…

    (ICOM IC-Z1A battery pack shell)
    (Battery pack contacts)
    (Ed Nisley - KE4ZNU - June 2010)
    (Vise clamping on threads, XY orgin on central axis, Z=0 at *bottom* of screw head)
    (Tool table used just for Axis previews and to activate "manual" changer via M6)
    (Tool change @ G30 position above length probe)
    
    (-- Global dimensions & locations)
    
    #<_Traverse_Z> =        5.0
    #<_Cutting_Z> =            0.0
    
    (-- Get started ...)
    
    G40 G49 G54 G80 G90 G92.1 G94 G97 G98        (reset many things)
    
    M5
    (msg,Verify XY=0 on screw axis)
    M0
    
    (msg,Verify tool touched off at Z=0 on *bottom* of head)
    M0
    
    (debug,Verify vise clearance around head)
    M0
    
    #<Contact_Width> =        4.1            (X axis metallic contact - minus a smidge)
    #<Contact_Head_Dia> =    5.5            (recess for 4-40 head)
    #<Contact_Head_Radius> = [#<Contact_Head_Dia> / 2]
    
    #<Contact_Head_Depth> =    0.7            (recess depth - plus  smidge)
    
    #<Mill_Dia> =            1.98            (end mill diameter)
    #<Tool_Num> =            20
    #<Mill_Radius> =        [#<Mill_Dia> / 2]
    #<Mill_RPM> =            5000
    #<Mill_Feed> =             50
    
    (debug,Verify #<Mill_Dia> mm end mill)
    M0
    
    (debug,Set spindle to #<Mill_RPM>)
    M0
    
    F#<Mill_Feed>
    
    (--- Flatten the head)
    
    G0 Z#<_Traverse_Z>
    
    #<X_Step> = [0.5 * #<Mill_Dia>]
    #<X_Limit> = [3 * #<Mill_Radius>]
    #<Y_Limit> = [#<Contact_Head_Radius> + #<Mill_Radius>]
    
    #<X_Coord> = [0 - #<X_Limit>]
    
    G0 X#<X_Coord> Y[0 - #<Y_Limit>]
    G0 Z#<Contact_Head_Depth>
    
    O<Head_Trim> DO
    
    G1 Y#<Y_Limit>
    #<X_Coord> = [#<X_Coord> + #<X_Step>]
    G1 X#<X_Coord>
    G1 Y[0 - #<Y_Limit>]
    #<X_Coord> = [#<X_Coord> + #<X_Step>]
    G1 X#<X_Coord>
    
    O<Head_Trim> WHILE [#<X_Coord> LT [3 * #<Mill_Radius>]]
    
    G0 Z#<_Traverse_Z>
    
    (--- Trim the sides)
    
    #<Arc_Radius> = [#<Contact_Head_Radius>]
    #<Half_Width> = [#<Contact_Width> / 2]
    #<Angle> = ACOS [#<Half_Width> / #<Arc_Radius>]
    #<Half_Height> = [#<Arc_Radius> * SIN [#<Angle>]]
    
    G0 Z#<_Traverse_Z>
    
    G0 X[0 - #<Half_Width>] Y[0 - #<Contact_Head_Radius> - 3 * #<Mill_Dia>]
    G0 Z#<_Cutting_Z>
    
    G41.1 D#<Mill_Dia>
    G1 X[0 - #<Half_Width>] Y[0 - #<Half_Height>]
    
    G1 Y#<Half_Height>
    G2 X#<Half_Width> I[#<Half_Width>] J[-#<Half_Height>]
    G1 Y[0 - #<Half_Height>]
    G2 X[0 - #<Half_Width>] I[-#<Half_Width>] J[#<Half_Height>]
    G1 Y#<Half_Height>
    
    G0 Z#<_Traverse_Z>
    
    G40
    
    G30                    (back to tool change position)
    
    (msg,Done!)
    M2
    
  • Repurposing Tomato Cages

    Bending tomato cage wires
    Bending tomato cage wires

    Mary wanted to convert some old tomato cages into flower supports and deer protectors (until the flowers get big enough), by the simple expedient of flipping the cages over with the large end down. She figured we could chop off the wire ends that normally anchor the cages to the ground, then bend them into hooks for secure ground anchors.

    I deployed the linesman’s pliers, which only showed that my wire size estimation is grossly underdeveloped. The high-carbon steel wires required bolt cutters… but a few minutes of twang effort scattered two dozen really stiff wires across the patio.

    I ran a marker across the pile at the bend point, grabbed two random steel rods in the vise and, in short order, bent up a stack of ground anchors.

    Not every job requires G-Code …

  • Kensington Expert Mouse Trackball vs X Server 1.8

    After the fuffing and fawing required to get the Wacom tablet up to speed, swapping the buttons on the Kensington trackball required just one stanza in /etc/X11/xorg.conf.

    To wit:

    Section "InputClass"
    Identifier      "Kensington Trackball"
    MatchProduct    "Kensington Expert Mouse"
    Option          "SendCoreEvents" "True"
    Option          "ButtonMapping" "3 8 1 4 5 6 7 2"
    EndSection
    

    For some no-doubt logical reason, it Just Works without an InputDevice stanza or anything in ServerLayout.

    That will swap the buttons on any matching trackball, should I be so bold as to plug more than one in at a time …

    The old FDI file is there.

  • Monthly Aphorism: On Being Square

    • If you can’t be smart, be square

    Father Vaughn spent many years in IBM’s semiconductor biz, where he realized that the proper shape for a silicon chip was not long and skinny.

    His engineers would argue that they could lay out the logic much more easily on a rectangle. While that was true, he knew something they didn’t: high aspect ratio shapes snap much more easily during processing. An optimum layout doesn’t matter when you can’t build the chips.

    His aphorism also applies to human behavior: you’re rarely as smart as you think you are. Being square, in the stodgy, conventional, risk-averse sense, may save your bacon.

  • Wacom Graphire3 vs X Server 1.8

    A recent Arch Linux update introduced Version 1.8.1 of the X server, which jettisons the whole HAL infrastructure in favor of udev. This is almost certainly a step in the right direction, but once again it’s time to figure out exactly how to get my Wacom Graphire3 tablet running.

    The solution turns out to be putting all the configuration options back in /etc/X11/xorg.conf, exactly where they started out before they moved into HAL FDI files. Not that any of this is obvious, mind you, but that’s how it works out.

    So.

    At this point, the Arch Linux linuxwacom-bamboo-cth-ctl package installs the only Wacom driver version (0.10.7-4) that works with X 1.8+.

    In /etc/udev/rules.d/10-wacom.rules the two highlighted lines match the Graphire and throw the evdev driver overboard if it got control. The top line was the original file; I commented it out and inserted the rest based on a thread in the Arch wiki; I think the original would work fine.

    ###KERNEL=="event*", ID_VENDOR_ID=="056a", NAME="input/%k", SYMLINK="input/wacom"
    # udev rules for wacom tablets.
    
    KERNEL!="event[0-9]*", GOTO="wacom_end"
    
    # Multiple interface support for stylus and touch devices.
    DRIVERS=="wacom", ATTRS{bInterfaceNumber}=="00", ENV{WACOM_TYPE}="stylus"
    DRIVERS=="wacom", ATTRS{bInterfaceNumber}=="01", ENV{WACOM_TYPE}="touch"
    
    # Convenience links for the common case of a single tablet.  We could do just this:
    #ATTRS{idVendor}=="056a", SYMLINK+="input/wacom-$env{WACOM_TYPE}"
    # but for legacy reasons, we keep the input/wacom link as the generic stylus device.
    ATTRS{idVendor}=="056a", ENV{WACOM_TYPE}!="touch", SYMLINK+="input/wacom"
    ATTRS{idVendor}=="056a", ENV{WACOM_TYPE}=="touch", SYMLINK+="input/wacom-touch"
    
    # Check and repossess the device if a module other than the wacom one
    # is already bound to it.
    ATTRS{idVendor}=="056a", ACTION=="add", RUN+="check_driver wacom $devpath $env{ID_BUS}"
    
    LABEL="wacom_end"
    

    When X wakes up, it stitches together a bazillion snippets of config options that used to live in /etc/X11/xorg.conf. This default snippet in /etc/X11/xorg.conf/50-wacom.conf seems to be OK, although only the highlighted stuff applies to my setup.

    Section "InputClass"
    	Identifier "Wacom class"
    # WALTOP needs a patched kernel driver, that isn't in mainline lk yet,
    # so for now just let it fall through and be picked up by evdev instead.
    #	MatchProduct "Wacom|WALTOP|WACOM"
    	MatchProduct "Wacom|WACOM"
    	MatchDevicePath "/dev/input/event*"
    	Driver "wacom"
    EndSection
    
    ... snippage ...
    

    Meanwhile, back in /etc/X11/xorg.conf, the tablet requires two InputDevice stanzas and their corresponding ServerLayout entries.

    Section "ServerLayout"
        Identifier     "RotatedPortrait"
        Screen      0  "Landscape" 0 0
        Screen      1  "Portrait" RightOf "Landscape"
        InputDevice     "Wacom - stylus"
        InputDevice     "Wacom - eraser"
    EndSection
    
    Section "InputDevice"
        Identifier      "Wacom - stylus"
        Driver          "wacom"
        Option          "Device" "/dev/input/wacom"
        Option          "USB" "on"
        Option          "Type" "stylus"
        Option          "Button2" "3"
        Option          "Button3" "2"
        Option          "MMonitor" "off"
        Option          "ScreenNo" "0"
        Option          "BottomX" "16725"
        Option          "BottomY" "11893"
    EndSection
    
    Section "InputDevice"
        Identifier      "Wacom - eraser"
        Option          "Device" "/dev/input/wacom"
        Driver          "wacom"
        Option          "USB" "on"
        Option          "Type" "eraser"
        Option          "MMonitor" "off"
        Option          "ScreenNo" "0"
        Option          "BottomX" "16725"
        Option          "BottomY" "11893"
    EndSection
    

    I haven’t checked to see if the driver still requires the BottomX / BottomY values to keep the cursor from crashing X when it enters the crack between the displays.

    Most of that is documented in the man pages for xorg.conf and wacom.

    The corresponding FDI file for the previous X Server is there, just in case you want to compare notes.

  • Zire 71 Button Protector

    Zire 71 button protector
    Zire 71 button protector

    I carry around an ancient Zire 71, from the time before PDAs merged with phones and PCs to become fashionable objects of desire.

    Anyway, it turns out that the buttons on the front are remarkably easy to squash in your pocket: the poor thing spends a lot of time turning itself on and off. I machined a plate with two holes for the four buttons and a lengthwise recess with two notches for the joystick selector. The whole affair slides into the pouch Mary made for it and works fine.

    I tweaked the thing a bit when I got a replacement Zire a few months ago; the grippy tape I put on the sides seemed to be just large enough to force the joystick against the protector while sliding it into the pouch. Now that’s not a problem.

    Zire 71 protector in place
    Zire 71 protector in place

    This is in the nature of documentation, just in case I need something like this ever again. I found these pix while looking for something else …