The BookBox : A localized, portable ebook delivery system using open-source components

Ebooks are becoming an essential part of library services. Most library eBooks are delivered through third party vendors encumbered by DRM and access controls. Open and out of copyright ebooks provide a large library of books and articles that Librarians and information professionals can experiment with and provide to their patrons.

This post shows how librarians can use cast-off technology to create a localized ebook  delivery system to deliver ebooks over a Wifi connection. The system described in this post can be put together with a wide variety of hardware, much of which can be re-purposed from obsolete components. This system can also be powered by battery power to deliver a large number of electronic texts to school rooms, agricultural centers or higher educational institutions even in areas without consistent electrical power.

Components of the system.

  1.  A computer that can run the Debian operating system. Old laptops, old desktops, plug computers and even NAS devices like the PogoPlug can be used as the computing platform.
  2.  A Router capable of running  the DD-WRT open source firmware
  3.  A USB drive or flash memory key ( if computer doesn’t have memory like the PogoPlug)
  4.  (optional) A battery pack
  5.  (optional) An enclosure to hold the system.

For my example build I used a Seagate FreeAgent DockStar as the base computer and a Asus WL – 330GE as the router. My example build fits in a standard metal lunch box, including a battery pack. My example build cost ~$100 US.

Plug the computer into a router with an ethernet cable.

Install Debian on the computer platform. Debian can be downloaded from http://www.debian.org/.

In my example build, I used a Seagate DockStar FreeAgent NAS device and installed Debian from the version maintained by Jeff Doozan. His instructions for installing Debian on the Dockstar are found at http://jeff.doozan.com/debian/

If using the DockStar as I did in my example build, David Dart’s guide to creating the ‘PirateBox’ can give you additional valuable advice on mounting partitions on your drive or USB memory key.

http://wiki.daviddarts.com/PirateBox

Install the Monkey webserver software on your project computer. http://monkey-project.com/
The Monkey webserver is an extremely simple webserver with minimal configuration required. You can install monkey using the apt program manager by issuing the command

sudo apt-get install monkey

All of the monkey configuration files are found in conf/ directory.
Open monkey.conf in nano by issuing the command

sudo nano monkey.conf

In monkey.conf, ensure that monkey is listening on port 80, and note the location of the HTTP directory. If necessary, you can change the location of the HTTP directory. This is the location where we’ll be uploading the ebook files.

Save the monkey.conf file.

To test, create an index.html file with ‘Hello World’. Open the IP address that your router has given the computer like this http://%5BIP Address]:[Port Number].

On another computer, use the Calibre software (http://calibre-ebook.com/ ) to create an ebook library from the source of your choice. Calibre is a powerful tool for organizing, editing, creating and distributing eBooks. Sources for your library include the Project Gutenberg books, open access books from the Internet Archive, or a project like TEEAL http://www.teeal.org/. Using Calibre you can add metadata, download covers and other details from Amazon.com and the Internet Archive.

Once your Calibre library is created, you can use a companion program called Calibre2odps to create a set of static HTML pages. http://wiki.mobileread.com/wiki/Calibre2opds

This set of static HTML pages can be uploaded to any webserver, in any location.

Copy the complete Calibre2odps library over to the HTTP directory of your Debian webserver.

Your webserver can now be plugged into any network connection, and will serve up the complete catalog in HTML and ODPS formats on port 80.

I created a simple index.html landing page pointing to both the catalog.html and catalog.xml files. This is the default landing page.

To create a standalone system, use an old router capable of running the DDWRT open source firmware. You can find a list of compatible routers by visiting http://www.dd-wrt.com/site/index.

Install DDWRT according to the directions for your particular model. For my project I used the Asus WL330GE because it can be powered by a USB cable.

Once DDWRT is installed, you can change the SSID to something more appropriate, I suggest ‘Bookbox’

Plug the DDWRT router into your computer platform, turn everything on and connect to your ‘Bookbox’ wireless network.

The goal of this setup is to force all traffic to visit index.html when they connect to the network.

Point your browser to 192.168.1.1 to visit the control interface for the router.  Go to Status > LAN and write down the IP address that has been assigned to the computer by the router. This may take a while.

Next, go to Services > Services  and set the DNSMasq and Local DNS buttons to Enable. In the “Additional DNSMasq Options” add the following

address=/#/0.0.0.0 (enter the IP address you wrote down)

Click Save.

Go to Services > Hotspot tab and click Enable beside HTTP Redirect.

Enter the following items

HTTP Destination IP: 0.0.0.0 (Your server’s IP Address)

HTTP Destination Port: 80

HTTP Source Network: 192.168.1.0 (the “0” denotes the whole range of IP addresses under this address)

Click Save, then go to the Administration > Management tab and click the Reboot Router button at the bottom of the page. Wait for the router to reboot and enter any address in the address bar of your browser. You should now be redirected to the index.html landing page .

If you connect to the Bookbox wireless network with a ODPS compatible ebook reader you can browse a catalog of ebooks within the ereader.

If this system has been put together with a plug computer, or using one of the systems that David Darts prototyped with his Piratebox systems, you should be able to power the entire system using a consumer laptop external battery pack. The DockStar or Pogoplug systems are particularly easy to power as their extra USB ports can easily provide power to the router over USB. The entire system, when set up using the DockStar and the Asus WL330GE  can be fit into a standard tin lunchbox, including a fairly large battery pack.

I have found that simpler web browsers, such as those found on e-readers actually handle this system better than the more complex Mobile Safari. From the feedback from David Darts project, it looks like Android phones seem to handle this connection quite well.

Resources

http://wiki.daviddarts.com/PirateBox_DIY_Plug_Computer
http://jeff.doozan.com/debian/
http://calibre-ebook.com/
http://wiki.mobileread.com/wiki/Calibre2opds
http://monkey-project.com/documentation/index

Advertisements

One Response

  1. […] did an update to my BookBox project, adding additional storage in the form of a rescued 320 GB harddrive from my old media center […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: