Building an Inforad with Raspberry Pi and Geckoboard
6The first time I heard the term inforad (information radiator) was while reading this blog post from Square's engineering team. Square built their inforads using Mac Minis which made sense at the time. I'm going to build inforads for Mediocre Laboratories using Raspberry Pis.
Like my last project, let's start by identifying some goals:
We need the inforad's computer to be small, at least as small as a Mac Mini so it can easily be mounted behind a large screen display. Raspberry Pi is perfect for this.
We'd like the inforad's computer to be as portable as possible. I'm not sure where in the office we're going to locate these things so I'd like to minimize the number of cables, power outlets, ethernet jacks, etc.
- The inforad's computer needs to be able to run a modern web browser in order to run the Geckoboard application we're using to build dashboards.
- The inforad's computer will be dedicated as an information radiator. Ideally, with the finish product, you wouldn't even know there's a computer there running a web browser. The computer and web browser should disappear and allow the content to surface as-if the dashboard application was built right into the display.
- Outside the initial setup and configuration, the inforad computer needs to have zero maintenance. Information radiators don't work if someone has to connect a keyboard and mouse and sign in to them every morning.
Step 1: Equipment
Since this is my first Raspberry Pi I decided to purchase a starter kit rather than trying to assemble the components a la carte.
@lukeduff suggested I also get a USB keyboard with a touchpad for initial setup and configuration which was a great idea.
$25.32: Smart Touch Mini USB TouchPad Keyboard
Total: $87.31
Step 2: Raspberry Pi Assembly
The kit arrived in a couple of days and was straightforward to assemble without any instructions.
Boxed:
Unboxed:
Case:
SD Card:
WiFi:
USB Keyboard and Touchpad:
Micro USB Power Supply:
HDMI:
All together now:
Step 3: Raspberry Pi Initial Setup
After assembly, I connected the HDMI cable to my 46" Samsung TV. Then I removed the micro USB cable from the AD/DC adapter and plugged the cable to one of the USB ports on the TV. There's enough power from the TV to run the Raspberry Pi which eliminates the need for an extra power outlet.
Upon initial boot it prompted me to select an OS to install. I choose Raspbian since it was recommend:
That took several minutes:
Once the OS was installed I rebooted:
Then I was greeted with the raspi-config tool:
From the raspi-config tool I did three things.
- Enabled boot to desktop
- Setup the timezone for Central Time
- Went to advanced settings and disabled overscan (the image wasn't taking up the full display and I had black bars)
After a reboot I was in the desktop. I used the WiFi Config tool to connect to my network:
Once I had a network configuration I was able open up a root terminal and update the software and firmware by running these commands (be prepared, some of these take a long, long time):
sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo apt-get install rpi-update
sudo rpi-update
Then I setup NTP to make sure the date and time is set correctly on the machine:
sudo apt-get install ntpdate
sudo ntpdate -u ntp.ubuntu.com
Step 4: Configure the Raspberry Pi as an Inforad
Once I had the network connected and updated the Raspberry Pi it was time to turn this thing into an information radiator.
Installed the Chromium web browser:
sudo apt-get install chromium
Needed to add some smoother fonts:
sudo apt-get install ttf-mscorefonts-installer
Setup Chromium to launch at startup. Kiosk mode makes the browser run full screen. Incognito mode prevents the “Chrome did not shutdown cleanly” message when the Raspberry Pi is turned off:
sudo nano /etc/xdg/lxsession/LXDE/autostart
ADD THIS LINE: chromium --kiosk http://your-dashboard-url.com --incognito
Made sure the screensaver doesn't turn on:
sudo nano /etc/xdg/lxsession/LXDE/autostart
REMOVE THIS LINE: @xscreensaver -no-splash
ADD THIS LINE: @xset s off
ADD THIS LINE: @xset -dpms
ADD THIS LINE: @xset s noblank
I also needed to modify the /etc/lightdm/lightdm.conf file:
sudo nano /etc/lightdm/lightdm.conf
ADD THIS LINE TO THE [SeatDefaults] SECTION: xserver-command=X -s 0 dpms
Last step was to remove the mouse cursor after the Raspberry Pi boots so it's not in the way of the dashboard:
sudo apt-get install unclutter
sudo nano /etc/xdg/lxsession/LXDE/autostart
ADD THIS LINE: unclutter
Step 5: Reboot and cross your fingers
After installing Chromium, setting it to auto-start in kiosk and incognito mode to our Geckoboard URL, disabling the screensaver, and hiding the mouse cursor... it's time to reboot.
I see the Raspberry Pi go through the traditional Linux boot sequence and into the desktop. I see the mouse cursor disappear. I see Chromium launch and BOOM GOES THE DYNAMITE. It works:
Here's a Vine of the boot sequence which takes about 60 seconds total
- 10 comments, 1 reply
- Comment
Great rundown of the raspberry pi build. Looks like a debian fork?
I'm interested in what you are using for your actual dashboard. That doesn't look like graphite?
Mrs. Durkzilla gave me a Raspberry Pi Starter Kit for Christmas - it was my favorite gift.
But I hope you're using a static IP address. My Pi doesn't like DHCP at all, either for wired ethernet or WiFi - it often fails to acquire an address and drops off the network rather than renew it's DHCP lease. Very frustrating.
@joneholland, Yeah, Raspian is based on Debian.
I'm not using Graphite. I'm using a service called Geckoboard: http://www.geckoboard.com which has widgets for a ton of services (including Graphite). Right now I'm using widgets for Google Analytics, GitHub, Pingdom, and StatHat.
The Geckoboard/StatHat integration was something I requested:
@durkzilla, Interesting. Not having any issues with DHCP so far. Which OS are you running on your Raspberry Pi?
You know what I like about this chat forum? It's that I often don't have a clue about what is being said even with pictures. Yes, I know what Raspberry Pi is (yum!)--just kidding.
But I'm not completely hopeless, I do speak some basic Linux:
sudo barnabee over and out
@shawn, Raspbian. I had problems with hard wired and wireless - I suppose it could be because of my router (FiOS Actiontec POC).
But then again, of all the Linux distros I've had the most headaches with the Debian branch.
Thanks for the write-up. I'm building my inforad now using an old Gateway 19" monitor. It will sit at my desk and show me server status without taking up real estate on my work PC.
Post some pictures when you get it setup. Would love to see it!
Stealing this idea for scrum projects in the office
Hi, great tutorial. I followed it, and yesterday it worked perfectly - but today when I met in first the browser startet to "The webpage is not available" - I restarted and then it took like 10 minutes to get to the geckoboard. I tried a reboot again, and the "The webpage is not available" came again?
I should mention that I'm using a wifi adapter, but it's not offline because I can reach the Pi with SSH.
I just want to run to the nearest computer and purchase a Rasberry Pi!! Thanks for the awesome description, I am going to have to try this out.