Jeff Duntemann's Contrapositive Diary Rotating Header Image

rpi

Odd Lots

Odd Lots

  • Yes, I’ve been away from Contra for longer than I’d like, and the Odd Lots have been piling up. Some of that away was necessary for my sanity, and was spent by the pool at a resort in Phoenix, where Carol and I discussed things like the wonder of a single-celled organism that is 10 cm long. The secret appears to be evolving superior organelles. Bandersnatchi, anyone?
  • While I was gone, someone released a new OS for the Raspberry Pi: The Pidora Remix. It’s basically Fedora for the Pi. I haven’t tried it yet, but I’ll flip another SD card out of the drawer soonest and burn an image. Man, you have to run like hell just to stay in one place in this business.
  • The Raspberry Pi’s main competition, the BeagleBone, now has a 1 GHz ARM Cortex A8 version that ships with a Linux 3.8 kernel. BeagleBone Black supports the Linux Device Tree, which does a lot to decouple hardware details from the kernel. Looks terrific–now all it needs is an installed base.
  • I noticed a system resource draw-down when I had iTunes installed on my old and now electrocuted quadcore. The software took a lot of cycles and memory, even when it didn’t appear to be doing anything. The discussion has come up on Slashdot. (The poster also mentioned Rainmeter, which I tried once and found…ok.) I try to run a lean system here, and I frown on things that want services, tray icons, and 15% of my cycles all the damned time. (The Dell Dock does precisely that. For showing a row of icons. Sheesh.)
  • Amazon is setting up a new markeplace for short fiction, with a twist: It offers to share revenues on fan fiction with the authors of the original items. It’s unclear how many authors will accept that, but I would, like a shot. (I guess all I’d need are some fans.) In truth, Jim Strickland and I talked in detail some years back about opening up the Drumlins World to all authors who’d care to tell a story there, without even asking for money.
  • Clinical depression may be linked to sleep cycles, which appear to have a genetic basis. How to fix this is unclear, but I’ll testify that depression in the wake of losing Coriolis laid waste to my sleep habits for a couple of years. (Thanks to Jonathan O’Neal for the link.)
  • The Man Who Ploughed the Sea may soon be mining it…for uranium. I’d cut to the chase and just mine it for gold, so I can buy more ytterbium for my Hilbert Drive. Alas, there’s less gold in the oceans than we thought (1 part per trillion) and not much more ytterbium (1.5 parts per trillion) so maybe I should just extract the uranium (3 parts per billion) and make yellow pigments to sell on Etsy.
  • I’m not sure I buy this, but it’s an interesting speculation: That the Younger Dryas cold snap was triggered by a smallish asteroid that crashed…in Lake Michigan. Click through for the maps if nothing else. My favorite Great Lake is deeper and more complex than I thought.
  • Save the apostrophe’s! (From a fate worse than dearth…)
  • And save us, furthermore, from new Microsoft technology that counts people in the room watching your TV. Because having more than one person watching a TV show or movie rental is…is…stealing!
  • 3-D printing is still in the stone age (and the Old Stone Age at that) but if we don’t allow berserk patent law to strangle the kid in its crib, wonderful things will happen once 3-D printers are no longer CNC glue guns. (Thanks to Pete Albrecht for the link.)
  • I’m starting to think that 3-D printers like that will soon make one-off repro of small plastic parts like the ones at the center of kites practical. I guess the challenge is somehow getting the precise shape of the part into a file. If I weren’t trying so hard to be a novelist I would probably have a 3-D printer already. For the moment I’m glad I didn’t jump as soon as I otherwise might have.
  • Speaking of CNC…and guns: Plastic guns are dumb, dangerous, ineffective, and basically a stunt that seems designed (probably in Autocad) to make politicians say stupid things and make enemies. The real issue is cheap, portable CNC machines capable of cutting metal. That horse is out of the barn and beyond the horizon.

Odd Lots

The Pibow Case and Vesa Mount for Raspberry Pi

Last week I bought a Toshiba 23L1350U 1080p TV set as a display for the Raspberry Pi. It’s a terrific TV set, as TV sets go, and a reasonable monitor. I had to do some hunting around the configuration menus with the remote to get it out of TV mode and into PC mode, and then reduced the brightness until it didn’t make my eyes want to fall out and roll under my desk.

With that accomplished, boy, it’s a sweet display for the Raspberry Pi. The effective resolution is 1920 X 1080, which is a lot of pixels to push around for something not quite the size of a business card and running at a bare 700 MHz. It runs Scribus, Lazarus, and AbiWord tolerably well. In fact, the MagPi magazine is laid out with Scribus on an RPi, which makes this old magazine geek boggle.

Like a lot of people, I just let the RPi board lie in the thick of its nest of cables for awhile. I then cobbled a mount out of scrap aluminum for an old SX270 all-in-one stand, and that works pretty well on the matching 2004-era Dell 17″ 4:3 monitor. That’s now my spare RPi system. I bought a second board for the Toshiba and wanted a case to put it in, to get it off the desk and out of the way.

Pi in PiBow Case 1-500 wide.jpg

The Toshiba provides an ideal place to put the case: on the 100mm VESA mount at the back of the TV. The Pibow people sell these slick transparent cases consisting of seven layers of CNC-cut plexi, stacked, with vent-perfed front and back panels. The board fits snugly in the void left in the slabs by cutting. The plexi layers are not glued or fastened to one another in any way, which makes assembly tricky. Four long nylon bolts hold the assembly together. Tip: Don’t get the layers out of order, as they are not numbered.

Pibow on Vesa 1-500 wide.jpg

Pibow sells a VESA mount as a separate item. It’s simply a different rear panel, with four ears drilled for both 75mm and 100mm VESA templates. Bolted to the VESA inserts, it’s up and out of the way and reduces cable clutter radically. I’m wondering how warm the board will get inside the case, but as I’m not overclocking the board (yet) I suspect it’ll be fine.

I’m going to use Adafruit’s nano-Wi-Fi adapter for networking on this unit. It hasn’t come yet, and I’ll report on how easily it goes in and how it works in future entries.

The Raspberry Pi Keyboard Stutter Problem

When I first cabled up and ran my Raspberry Pi board, it worked like a charm, first time. I was powering it with the Motorola Droid X2 charger that I had stolen from the kitchen desk upstairs. To keep peace in the valley, I went out and bought a cheap Micro-USB phone charger at Best Buy. It booted normally, but then, when I tried to log in, the keyboard began repeating characters. I’d type in “pi” and see a parade of extraneous i’s march in stately fashion across the display:

piiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii

Needless to say, I couldn’t log in. Now, this didn’t happen every time, but probably half of all logins I attempted failed, with the same keyboard jitter. I tried two other USB keyboards I had on the shelf plus the known-good one attached to my GX620 USFF, and saw exactly the same behavior. It clearly wasn’t the keyboard itself. I’m using a Dell SK-8135 keyboard, which has a 2-port USB hub to which a Dell USB optical mouse is connected. This leaves one USB port on the RPi free, with any luck to use for thumb drive add-in storage. More on that once I figure it out.

Anyway. Some googling suggested a power supply shortfall. I got out my DVM and put the probes on test points 1 and 2. These are minuscule “doughnut” pads on the RPi circuit board. One is labeled TP1, the other TP2. Hunt around on the board for them; it’s not like there are a lot of square inches to search. TP1 is located next to the 220 uF filter cap at the Micro USB jack. TP2 is right next to the yellow RCA jack.

The RPi is designed to work at 5V. Anything much below that and things may start getting flaky. My reading across the test points was 4.72V. Aha! We now have a new phone charger for the kitchen desk–a cool one with a retractable cord–and I decided to dedicate the old one to the RPi. With the original Motorola Droid X2 charger in the wall, I measured 5.03V across the test points. Shazam! No more keyboard stutter.

I’m not sure it’s a question of the RPi drawing more current than the charger can provide. The Droid X2 charger that works is rated 850 ma. The no-name charger that provided only 4.72 volts is rated 2.1 A. Current sourcing ability is important, especially since different USB keyboards and mice draw different amounts of power–but accurate voltage is just as important. I’m guessing it’s sloppy voltage regulation in the cheap charger. If you’re getting keyboard weirdness, put your DVM on the test points and see what your charger is feeding the RPi.

What? You don’t have a DVM? No Pi for you!

The RPi Enthroned

I wonder how many Raspberry Pi boards will spend their entire working lives sitting cockeyed on a desk somewhere, at the center of a tangle of cables. That’s how mine was until a couple of days ago, when despite my cough I allowed myself a few minutes of quality screwdriver time to pull a proper RPi system together.workstation-500wide.jpg

It didn’t take much. Mostly what it took was a 2004-era Dell SX270 all-in-one system minus the SX270, which I now use as a bookend. The key component is a heavy stainless steel base with a VESA monitor mount and a bracket to hold the SX270 behind the monitor. The monitor itself is an unexceptional Dell 1704fp, with a native resolution of 1280 X 1024. (Those now sell for ~$50 on eBay.) That’s more than enough pixels for an RPi, although I tested it on one of my 21″ 1600 X 1200 behemoths and the little gadget did quite well overall.

BackView-500wide.jpg

I had already mounted the board on an aluminum plate, and all I had to do this time was drill two holes and bolt the plate to the SX270 mounting bracket. I may dress the wires a little to keep them from placing any torque on the connectors, but it works well as-is.

I was surprised to find out that the MagPi magazine is actually laid out on an RPi, using the open-source Scribus layout program. I installed Scribus via apt-get and poured some text into a layout. (I’ve been playing with Scribus for years.) Brisk! I guess we need to stop boggling at the capabilities of tiny little computers with all of two ICs on the mobo.

It certainly does a good job with FreePascal and Lazarus, which is why I went to all this trouble. They’ve now sold half a million of these things. At least a few of those people ought to be willing to buy a Lazarus tutorial for it. We’ll see.

Odd Lots

Pi, Oh My

PiAssembled-500Wide.jpg

My longtime friend and collaborator Jim Strickland has had a Raspberry Pi board almost since the beginning, and he startled me by handing me one as a Christmas present. I was aware of it but hadn’t researched it deeply. Here’s a good place to start if you’re new to the concept.

Basically, it’s an ARM-6 board with HDMI and composite video output, two USB ports, and a standard RJ45 Ethernet connector. For disk it uses an SDHC card. There’s an I/O header for connecting to physical gadgets like relays and lights and things. There’s more than one OS available for it, but most people use the adaptation of Debian Wheezy called Raspbian.

I don’t like having circuit boards flopping around in mid-air, so I drilled and tapped two 4-40 holes in a husky 3/16″ aluminum plate and mounted the Pi on a pair of 3/8″ nylon standoffs.

Putting it together was a snap. I downloaded the Raspbian image file, wrote it out to a spare 8 GB SDHC card I had in the drawer with Image Writer for Windows, plugged the card into the card slot on the board, hooked up the cables, and turned it on.

Bootup isn’t snappy, and the first time in you have to set a few things like time zone, but in a couple of minutes I had Linux on my big-screen LED TV. The small black item connected to the USB port block in the photo above is the Bluetooth dongle for a Logitech wireless keyboard and mouse. This leaves me a port free for something else. Ethernet came to the device through a pair of Linksys Powerline bridges, which I’ve described here before.

I now have what Michael Abrash would call “Linux on my bedroom wall.”

This particular distro comes with Python and Scratch preinstalled, but Jim’s already gotten the ARM-6 port of FreePascal/Lazarus downloaded and running. That’s next on the list for me. I’ll wrestle with that another time, as it’s getting late here. I have a special purpose in mind for the gadget which I won’t spill just yet, since it may not be realistic. More as I learn it.