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

  • Ubuntu 9.10 Karmic: FAIL FAIL FAIL

    Soooo, for the last several days my main desktop system, recently installed with Xubuntu 9.10, has come up without networking services. The eth0 network interface is there, the (static!) IP is correct, Web browsing works… but NFS shares aren’t mounted and, upon poking around, other vital system services weren’t started.

    Worse, networking can’t be manually started, either, and there are no diagnostic log messages.

    Sometimes rebooting helps, sometimes it doesn’t. The problem is definitely timing-related, so sometimes pausing before signing in makes it work. Sometimes it doesn’t.

    Come to find out that Karmic has revised how system services get started during boot. The intricacies are lost on me, but the old Unix-style /etc/init.d/ model is now obsolete. Documentation on upstart, the replacement, is sketchy at best.

    We’re to type sudo service mumble start|stop|restart when we want to do things manually. Oh, maybe only start and stop have been implemented; everything else is defunct, but you can’t use the old method, either.

    Except that something in upstart 0.6.3-11 is broken / different, to the extent that system services no longer start up properly. Evidently that upgrade happened here in the very recent past, part of the usual system update routine. I do this manually, but there wasn’t any heads-up notice mentioning “Oh, by the way, this update will kill your system”, so I just installed it.

    Downgrading to -10 resolves the problem for many people, not including me, but that is not regarded as an actual fix. The older version has similar problems and downgrading just pushes the symptoms somewhere else. Part of the problem is that logging doesn’t (seem to) happen from upstart for any of the affected services.

    Now, Linux distributions started as a way to bottle up various combinations of upstream programs in known-good configurations, so that we end-user types didn’t have to go through the Linux From Scratch effort. That model seems largely dead; each major distro now applies so much floobydust to their combination that any resemblance to the upstream programs is purely coincidental.

    Like, for example, did you know that you’re probably not running OpenOffice, but Go-OO? Never heard of it? Me, either. Do the obvious search and see what you’ve not been told. Hint: Mono is still optional.

    Long ago, in a universe far away, I actually enjoyed beta testing software. These days, I just want it to work; I have other things to do. It’s painfully obvious that Windows isn’t the answer, but it’s becoming evident that (at least) Ubuntu has lost sight of the “it just works” goal.

    When vital parts of the system (like, for example, networking and system service startup) Just Don’t Work, something has gone badly wrong in the distro’s QA process. Yes, some problems remain hard to find, but when they’re reported (by other folks; I’m not first in line by any means) something should happen muy pronto.

    When a desktop environment (like, for example) KDE can’t handle two independent monitors, but has all manner of glitzy 3D effects, the development effort has wandered off into the bushes of irrelevancy. The fact that KDE can claim to have fixed 10,000 bugs in the 4.3 release is not, to my mind, much to brag about.

    To quote the immortal Iphigenia Deme, “That’s obscene-gerund enough!

    Right now, I have a column to finish and ship, with another right behind. With any luck, this system will hang together long enough to get those done, at which point I must devote some time to finding out which, if any, distros have a better recent track record.

    Some early fiddling indicates Arch Linux, which is sort of like Linux From Scratch with bigger and sorta-kinda snap-together pieces, should do the trick. Most important: it’s agnostic with respect to which desktop environment you pick, unlike the GNOME-oriented Ubuntu chassis that sorta-kinda allows you to bolt on KDE or Xubuntu bodywork.

    Quick summary of what’s needed: separate X sessions, right-hand session on a rotated-to-portrait monitor, Wacom tablet pinned to the left monitor, left- and right-handed trackballs. This configuration was fine in Kubuntu 8.04, got flaky in 8.10, and fell apart after that.

    There may well be upstream problems with some of those pieces, which generally isn’t something a distro can fix. I contend they could better apply their resources to fixing such problems than screwing up something else.

    More to follow…

  • DVD Player External Li-Ion Pack: A Pleasant Surprise!

    A friend mentioned a sale at Overstock.com (likely gone by now) that offered an Initial RB-270 9 V, 5.4 Ah lithium-ion battery pack, with a built-in charger, for $16. The pack was intended to keep a DVD player alive for long enough to avoid back-seat mayhem on long trips (for those toting undisciplined brats, anyway), but I saw it as a plug-in replacement for the NiMH AA-cell packs I’ve been using with the HTs on our bikes.

    The NiMH cells have been a major disappointment, as described there and there and there, with barely 1.5 Ah of capacity from nominal 2.4 Ah cells.

    Much to my surprise, all three of the Li-Ion packs delivered pretty nearly their advertised ratings. I varied the discharge level, but they’re all quite close…

    Initial External Li-Ion packs
    Initial External Li-Ion packs

    It looks like the packs include an internal regulator and over-discharge monitor, as the voltage is bar-flat right up to the point where it drops to zero. I’m mildly surprised at the regulator; I’d expect that they’d just deliver whatever the cells were producing, rather than waste any energy in the regulator.

    Notice that the 200 mA rate produced a lower total capacity than the 1 A rate. I’m guessing that’s power lost in the regulator over the protracted run time; 4.9 Ah at 200 mA added up to nearly a day of testing, far over the “up to six hours play per charge” rating.

    Let’s see: 5.4 Ah @ 6 hours makes the nominal load about 900 mA. So it delivered maybe 4.8 Ah at 1 A. Not what’s claimed, but much closer than those Tenergy NiMH cells.

    Next steps:

    1. Butcher the nice coily-cord cables to add Powerpole connectors that will click right into the bike radios
    2. Take one apart to see what bypassing the regulator would entail
  • Adobe Reader Default Toolbar: FAIL

    Maybe I’m misusing Adobe Reader, but I’ve always thought of it as a program that displays PDF files. In my case, that means data sheets for various & sundry electronic parts: I carefully squirrel both PDFs and parts away, having learned that physical parts can outlast both datasheets and company websites.

    So I open quite a few PDFs that reside on my file server in the basement.

    With that in mind, what’s missing from this row of toolbar icons?

    Adobe Reader Default Toolbar
    Adobe Reader Default Toolbar

    Go ahead, take your time…

    Hint: the only active button lets you “start an Acrobat Connect meeting and share documents”.

    This has been true for the last few versions; the Official Ubuntu Linux Version seems to be stuck at 8.1-ish. Let’s jump ahead a bit, fetch 9.3 directly from the Adobe download page, and install it:

    Adobe Reader 9.3 Toolbar
    Adobe Reader 9.3 Toolbar

    Now I can not only “Share documents and collaborate live within PDF documents”, but also “Click to create PDF using Acrobat.com”.

    What I can’t do is open a PDF file from disk by just clicking a button. That rarely used function is relegated to the File pulldown menu and, for those of us who can touch-type fairly well, hidden behind the arcane Ctrl-O keyboard chord.

    Reconfiguring the toolbar is a few minutes of clickety-click action, but it seems odd to me that none of the focus group participants suggested putting an Open File button on the toolbar.

    Although I never ascribe to malice what can be explained by stupidity, this continuing design decision does seem to require forethought.

  • Xubuntu 9.10: Quasi-functional Kensington Trackball Configuration

    As mentioned there, Ubuntu prohibits having two mice with different handedness. Xubuntu enumerates the various mice and allows you to set their handedness separately.

    This file swaps the upper two buttons.

    The scroll ring operates intermittently. I no longer believe it’s a hardware problem, as I have two Kensington trackballs and both behave the same way. I’m guessing the evdev driver has trouble with button pushes from two devices, but that’s just a guess. Sometimes it works perfectly for hours on end, other times it jams up first thing in the morning. Restarting X helps, which indicates the hole isn’t in the trackball’s end of the boat.

    Here’s my /usr/share/hal/fdi/policy/20thirdparty/10-expertmouse.fdi file:

    
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <deviceinfo version="0.2">
     <device>
     <match key="input.product" string="Kensington      Kensington Expert Mouse">
     <append key="input.x11_options.ButtonMapping" type="string">3 8 1 4 5 6 7 2</merge>
     </match>
     </device>
    </deviceinfo>
    
    

    [Update: made the code block cut-and-paste-able. Sorry ’bout that…]

  • Xubuntu 9.10: Barely Functional Wacom Tablet Configuration

    For some background on a single-monitor box, read that first. This file is for my dual-monitor setup, which introduces horrible problems: basically, this setup doesn’t really work.

    The MMonitor and ScreenNo values restrict the tablet to the left-hand X screen. Without those settings, things get really weird.

    But, with the X screen nailed down, the fundamental problem is that the tablet stylus cursor starts out restricted to just the upper-left part of the left-hand (landscape) monitor. The fraction of the screen seems somehow related to the aggregate total of the two monitors, but not in any numeric sense I can figure out.

    The fix for that is tweaking the BottomX and BottomY values so that the cursor can cover the entire screen. I used the wacomcpl utility to cut-and-try various numbers until I got something close. They are quite different than the tablet’s default values: 16700 and 12064.

    The values suggest that the driver expects the tablet to cover the entire range of coordinates for both monitors, but whether that’s with the right monitor rotated or not isn’t obvious. The numbers do not work out either way. Maybe it’s taking the outermost bounding box?

    It is not clear why this hocus-pocus works at all, as I thought those values were supposed to restrict the stylus cursor to specific locations of the tablet’s surface. Evidently they’re scaling factors.

    Note that this fdi file adds the names required by wacomcpl, without which nothing works.

    The GIMP is markedly unhappy with this arrangement. Mostly, the stylus works and provides pressure information, but none of the trackballs or the tablet can select fields within some (but not all) of the dialog boxes (like, for example, File->Save…). Only the keyboard Tab key can move between fields in that situation.

    The wacdump utility segfaults. This seems to be a known problem with Ubuntu 9.10, for reasons that aren’t clear.

    Sometimes, but not always, the stylus cursor has an offset: the visible cursor on the screen is a few inches up-and-right of the actual tool location that’s affecting the drawing. When this happens, tweaking the BottomX and BottomY values with wacomcpl sometimes restores proper operation; the ensuing values have no relation with anything I can understand.

    Much to my surprise, button remapping works perfectly: the front switch on the stylus is Button 3, the rear is Button 2. That means context menus pop up on the more easily reached switch. At least I think so.

    Basically, something that worked absolutely dependably and without much manual intervention in 8.10 has become completely, totally, and utterly dysfunctional in 9.10. I do not count this as progress.

    With all that in mind, here’s the /usr/share/hal/fdi/policy/20thirdparty/10-linuxwacom.fdi file…

    
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <deviceinfo version="0.2">
     <device>
     <match key="info.product" string="Wacom Graphire3 6x8">
     <merge key="input.x11_driver" type="string">wacom</merge>
     <merge key="input.x11_options.Type" type="string">stylus</merge>
     <merge key="input.x11_options.Button2" type="string">3</merge>
     <merge key="input.x11_options.Button3" type="string">2</merge>
     <merge key="input.x11_options.MMonitor" type="string">off</merge>
     <merge key="input.x11_options.ScreenNo" type="string">0</merge>
     <merge key="input.x11_options.BottomX" type="string">8146</merge>
     <merge key="input.x11_options.BottomY" type="string">11893</merge>
     <append key="info.callouts.add" type="strlist">hal-setup-wacom</append>
     <append key="wacom.types" type="strlist">eraser</append>
     <append key="wacom.types" type="strlist">cursor</append>
     </match>
     </device>
     <!-- Wacom names "parser" -->
     <device>
     <match key="info.udi" contains_not="subdev_0">
     <match key="info.udi" contains_not="subdev_1">
     <match key="info.udi" contains_not="subdev_2">
     <match key="input.x11_options.Type" contains="stylus">
     <merge key="info.product" type="string">stylus</merge>
     </match>
     <match key="input.x11_options.Type" contains="eraser">
     <merge key="info.product" type="string">eraser</merge>
     <merge key="input.x11_options.MMonitor" type="string">off</merge>
     <merge key="input.x11_options.ScreenNo" type="string">0</merge>
     <merge key="input.x11_options.BottomX" type="string">8146</merge>
     <merge key="input.x11_options.BottomY" type="string">11893</merge>
     </match>
     <match key="input.x11_options.Type" contains="cursor">
     <merge key="info.product" type="string">cursor</merge>
     </match>
     </match>
     </match>
     </match>
     </device>
    </deviceinfo>
    
  • Xubuntu 9.10: Functional xorg.conf

    After considerable thrashing, this hand-tweaked version of /etc/X11/xorg.conf seems to do what’s needed for Xubuntu 9.10. It includes only display setup stuff; all the input device configuration is now tucked away in HAL FDI files.

    I used the nvidia-settings control panel to create a basic xorg.conf file that used separate X sessions, saved it in my home directory, then tweaked it in small increments until everything worked. Or, more precisely, until things stopped failing…

    Some observations:

    • Obviously, this uses the proprietary nVidia driver
    • The option Rotate CCW line must be commented out (or omitted) to avoid killing xrandr, because many utilities expect xrandr
    • Use the Xubuntu display setup applet to apply the xrandr rotation; just specify Screen 2 as rotated left
    • X locks up occasionally when Wacom tablet cursor falls into the seam between the displays. Make sure you can ssh into the box to restart X: an X crash kills the keyboard, too!
    • Metamodes must specify the exact monitor resolution
    • The nVidia logo doesn’t appear on either monitor during boot, even with NoLogo turned off. I like the logo, because it gives an early heads-up when something goes wrong.

    The xorg.conf file:

    
    Section "ServerLayout"
     Identifier     "RotatedPortrait"
     Screen      0  "Landscape" 0 0
     Screen      1  "Portrait" RightOf "Landscape"
    EndSection
    
    Section "Module"
     Load           "dbe"
     Load           "extmod"
    #   Load           "type1"
    #   Load           "freetype"
     Load           "glx"
    EndSection
    
    Section "ServerFlags"
     Option         "Xinerama" "0"
    EndSection
    
    Section "Monitor"
     # HorizSync source: edid, VertRefresh source: edid
     Identifier     "Dell2001FP"
     VendorName     "Dell"
     ModelName      "DELL 2001FP"
     HorizSync       31.0 - 80.0
     VertRefresh     56.0 - 76.0
     Option         "DPMS"
    EndSection
    
    Section "Monitor"
     # HorizSync source: edid, VertRefresh source: edid
     Identifier     "Dell2005FP"
     VendorName     "Dell"
     ModelName      "DELL 2005FPW"
     HorizSync       30.0 - 83.0
     VertRefresh     56.0 - 75.0
     Option         "DPMS"
    EndSection
    
    Section "Device"
     Identifier     "GF9400_0"
     Driver         "nvidia"
     VendorName     "NVIDIA Corporation"
     BoardName      "GeForce 9400 GT"
     BusID          "PCI:1:0:0"
     Screen          0
    EndSection
    
    Section "Device"
     Identifier     "GF9400_1"
     Driver         "nvidia"
     VendorName     "NVIDIA Corporation"
     BoardName      "GeForce 9400 GT"
     BusID          "PCI:1:0:0"
     Screen          1
    EndSection
    
    Section "Screen"
     Identifier     "Landscape"
     Device         "GF9400_0"
     Monitor        "Dell2001FP"
     DefaultDepth    24
     Option         "TwinView" "0"
     Option         "metamodes" "DFP-0: 1600x1200 +0+0"
     Option         "NoLogo" "Off"
     SubSection     "Display"
     Depth       24
     EndSubSection
    EndSection
    
    Section "Screen"
     Identifier     "Portrait"
     Device         "GF9400_1"
     Monitor        "Dell2005FP"
     DefaultDepth    24
     Option         "TwinView" "0"
     Option         "metamodes" "DFP-1: 1680x1050 +0+0"
     Option         "NoLogo" "Off"
     Option         "RandRRotation" "On"
    #    Option         "Rotate" "CCW"
     SubSection     "Display"
     Depth       24
     EndSubSection
    EndSection
    
    
  • Pupa from Thailand

    Banana stand pupal case
    Banana stand pupal case

    As part of the Great Kitchen Cleaning, I was charged with replacing a missing foot on the banana gallows we received as a gift many years ago. I found a tiny hole in the bottom that we’d never noticed before, most likely because we mistook it for an ink dot or an imperfection in the wood.

    The spot seemed to have something inside and a pass under the microscope showed the remains of a pupal case. I pried it out, destroying it in the process. The insect was, of course, long gone.

    Those are millimeter ticks on the scale along the top edge, so the hole is the better part of 1.5 mm in diameter. Perfectly round, of course, as only an insect programmed to drill holes can produce.

    The hole was 8 mm deep (likely deeper before the wood was planed), so the bug was qualified for gun drilling!

    The stand is marked “Made in Thailand”, but who knows where the wood came from or where it’s been? We’ve had the stand for many years now, but I’m pretty sure the critter was in there when we got it.