Using Raspberry Pi as an Internet Kiosk

Following up on this morning post explaining how to get the kernel and minimal rootfs to run debian in qemu emulating an ARM1176 processor, I’ll show how to make a minimal rootfs to run Chrome browser in this platform.

I tested it in QEMU, but this should also run on the Raspberry Pi hardware.

First, you’ll have to complete the step I provided in Raspberry Pi Emulator in Ubuntu with Qemu.

Start qemu:

sudo qemu-system-arm -M versatilepb -cpu arm1176 -m 256 -hda rootfs.ext2 -kernel zImage -append “root=/dev/sda” -serial stdio

Once you login to the console as root, create a new user (e.g guest):

adduser guest

This user will be needed to login with the graphical interface and ssh.

In order to get an Internet Kiosk, we’ll need a web browser (Chromium) and a window manger. I chose fluxbox instead of gnome because of the size difference (8651 KB vs 1739 MB).

I installed the required package in qemu with apt-get:

apt-get install xorg gdm fluxbox chromium-browser chromium-browser-l10n

Here’s the installed size for each package (and dependencies) according to apt-get:

  • xorg – 27 MB
  • gdm – 66.6 MB
  • fluxbox – 8651 KB
  • chromium-browser and chromium-browser-l10n – 228 MB

I’ve also installed dropbear to be able to access qemu via ssh.

Once everything is installed, there is only 759MB used.

If we were to run this in an SD card as it would be the case wit the Raspberry Pi board, we would just have to add the kernel (2MB) and reserve space for the web browser cache.  So a 1 or 2 GB SD card would most probably be sufficient to run this system.

Once, everything is installed, shutdown qemu and restart it.

sudo qemu-system-arm -M versatilepb -cpu arm1176 -m 256 -hda rootfs.ext2 -kernel zImage -append “root=/dev/sda” -serial stdio -redir tcp:2222::22

Note I added the redir option. This is to access the board (qemu) via ssh:

ssh -p 2222 guest@hostip

where hostip is the IP address of the host running qemu.

After the board boots, you should get the login screen below after a while.

Gnome GDM Login Screen
GDM Login Screen in QEMU

Now logging as guest, (don’t be confused by the grey screen) and right click to access the menu. Select Applications->Network->Web Browsing->Chromium to start Chrome.

Rasperry PI Web Browser in Qemu
http://www.raspberrypi.org rendered by Chromium in Qemu for ARM11

If we want to autostart Chromium after login, edit /home/guest/.fluxbox/init and change the line with session.screen0.rootCommand to:

session.screen0.rootCommand: chromium-browser &

Missing features and known issues:

  • Color problem (as seen on screenshot above). I’m not sure exactly what may cause this, probably a wrong colorspace has been selected.
  • No flash support. Adobe/ARM apparently only support Cortex A8/A9.
  • No java support. I tried to install sun java runtime, but apt-get could not find a candidate. Maybe it would be possible to install another implementation of java.
  • Only support English for now. For other languages, some language packs and fonts would have to be installed.

If you want the binaries to try it out:

The root password is ‘raspberry’, guest user password is ‘guest’.

Share this:

Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress

ROCK 5 ITX RK3588 mini-ITX motherboard
Subscribe
Notify of
guest
The comment form collects your name, email and content to allow us keep track of the comments placed on the website. Please read and accept our website Terms and Privacy Policy to post a comment.
7 Comments
oldest
newest
Amit
Amit
12 years ago

Hello , Thanks for this informative and clearly written article. I have been trying to use the binaries provided by you on my installed QEMU emulator, just as startup to familiarise myself with the qemu environment. But after issuing the command as mentioned in the post
sudo qemu-system-arm -M versatilepb -cpu arm1176 -m 256 -hda rootfs-chromium.ext2\(2\) -kernel zImage -append “root=/dev/sda” -serial stdio

I am getting this error : Unable to find CPU definition
Is it a compatibility issue as my QEMU version QEMU PC emulator version 0.12.3 (qemu-kvm-0.12.3) is older than what you mentioned in the previous post.
Thanks

blueberry pi
12 years ago

looks pretty good and well done a nicely written article with clear information!

Justin Scott
Justin Scott
12 years ago

I am curious if there is a way to have it auto-login and bypass the need to enter a username. We have a place where this would be perfect if it could boot up and go directly to the web browser without prompting the user for a login. Also, in addition to SSHD, is it possible to run a VNC server as well for remote access and monitoring? Any way to force Chrome into a kiosk mode on start (e.g. no browser chrome or controls, just the viewing area). This is a great start for a true “kiosk” deployment, but… Read more »

Marco
Marco
12 years ago

There’s a new project in town, Instant WebKiosk for Raspberry Pi.
See: http://www.binaryemotions.com/instant-webkiosk-for-raspberry-pi/

Elson
Elson
11 years ago

How do we attach a Python powered coin acceptor module via RPi GPIO @Justin Scott

Khadas VIM4 SBC