Archive for December 2012
I recently had a short post that rode the front page of Hacker News for the better part of 24 hours, spending at least 8 hours at the number one spot.
Compared to my last popular piece, this post took very little time to write. Really it was just a thought, an annoyance that I was experiencing over the last few months, and finally it was enough for me to write a short post about it.
I can’t explain what happened after I posted it. The only explanation I have for over 20k people reading it is that it is something that has been lurking just in people’s subconscious minds for a while and I found just the right tone and attitude to galvanize people around the issue without coming off as a flake or just a rant.
I’d like to say that I had some kind of master plan for this or that I intended to write my post this way intentionally, but sadly that is not the truth. I accidentally hit on something very divisive in just the right way.
If anything maybe I can learn that it’s ok to take the gloves off for a little while to get some emotional engagement. Some of my technical posts are long and a little dry so maybe this is telling me something? Or… perhaps not.
I’m getting sick of being prompted by random Web sites to download their special iPhone app. I really just want to use the site without having to clutter up my phone with yet another single-purpose app.
I can’t put my finger on exactly when so many sites started prompting iPhone users to download apps, but recently I’ve been to a few forums and news sites that all seem to want me to install something to basically read a blog or browse a forum.
The value of the Web is the content and connections. Just let me use the Web. I don’t care that much if I get slightly jerky scrolling, or if the list doesn’t seem like it’s infinitely scrolling off the edge of my little iOS world.
I think the app should not have to be the default mobile experience. I do like having the option of a higher-fidelity experience if I want it. If you provide a lot of value, I’ll grab the app on my own accord and enjoy it that much more, thanks.
The Raspberry PI single-board computer has been getting a lot of buzz since its launch early this year. For the first few months it was nearly impossible to get one of these things, and even now the only distributor that seems to have a reliable stock is Farnell in the UK. Well, I just got one for Christmas and now that I’ve gotten it up and running I’ll make a few comments on the process here and some initial thoughts.
My board is a Model B board, meaning it has the on-board Ethernet port. The setup here is the same for the other boards though, you just won’t be able to use the SSH server to log in remotely to it unless you attach a USB Ethernet interface.
There are a few things you need in order to get started. First is a power adapter that can power the board. The PI gets its power from a micro-USB jack on the board. I had a power supply from something else sitting around that worked ok, but it’s worth noting that you aren’t supposed to power this thing from your laptop or USB host directly. Powered hubs are ok, but the board draws 700ma or so, so be sure you don’t fry anything trying to get it juiced up.
Second thing is an SD card. Almost all of the available images need 2GB of space, so take this into consideration. I had a bunch of 1GB cards around but only one 16GB card that I’m using for my camera. I tried in vain to get a 1GB image to boot and ended up just clearing my camera card off and using the official Raspbian distribution. Of special note is that the PI will not boot from a USB stick, at least not without some kind of help (that is not available when you first pull it out of the box, for sure). This was a bummer since I was hoping to use a 2GB USB stick since I seem to have a lot of these lying around.
Third thing is a compatible display, at least while getting things set up. I used my TV with the composite video output. One of the 1GB images I booted from initially flickered so badly that I couldn’t make out any of the text from the Linux boot output. I was getting worried at this point, but it turns out that not all of the supported video modes on the PI flicker so badly, and the default frame buffer looked fine when I booted the official Raspbian distro image.
And finally, of course you need a USB keyboard. Once setup is done I just log in using SSH over the network, but initially we need a physical keyboard.
Once the board boots, a small setup utility runs that lets you set up things like keyboard and monitor overscan. Enabling a SSH server was very simple and worked fine the first time. By default, the PI tries to use a UK keyboard layout, so I had to mess with the keyboard to get a US key layout. This was more of a pain than than in some other Linux distros, but overall I figured it out quickly enough.
Video, or more accurately, overscan was the biggest pain. If you are using the HDMI output I don’t think this is an issue at all, but since I was using the composite video out, the edges of the display were being cut off by my TV. Confusingly, in order to enable overscan control, you have to disable overscan and set up some parameters for how much margin to add to the image. I didn’t get the configuration tool to work for this so I edited /boot/config.txt to correct my overscan settings.
# uncomment this if your display has a black border of unused pixels visible # and your display can output without overscan disable_overscan=0 # uncomment the following to adjust overscan. Use positive numbers if console # goes off screen, and negative if there is too much border overscan_left=24 overscan_right=24 overscan_top=0 overscan_bottom=0
The most confusing part about this is understanding what overscan is doing here. Usually overscan is a way to make sure that an NTSC or PAL image goes all the way to the edge of the screen, allowing some extra video content at the edges that is understood to be potentially cut off, sort of like the bleed area on a printing press image.
Overscan with respect to the PI means that we are adjusting the image to compensate for the output device. In my case I was actually using the overscan feature to create underscan so I could see everything on my TV.
The GUI doesn’t start by default, but can be started using startx manually. There is a configuration parameter to start the GUI on boot also. Note that startx won’t work using a remote X server. I’m using VcXsrv and putty to log into my PI from Windows, and to get the full desktop you’ll want to run startlxde, which starts the lxde desktop.
Once we have gotten this far, things behave a lot like any Debian distribution. Using apt-get to install things works as expected, and is the underlying mechanism that the PI Store uses. The default Web browser is Midori, presumably since something like Mozilla would have been too big or resource intensive for the PI.
I’ve gone on to test some Audio and MIDI interfaces on the PI and install some other custom things, and so far everything pretty much works like any other Linux environment.