Installing an augmented reality app on the Raspberry Pi

Installing an augmented reality app on the Raspberry Pi?

How did I end up playing around with augmented reality?

I recently published a paper on the usage of augmented reality in marketing, finding out that there is no real marketing via augmented reality yet. As it became clear that almost all cases we had a look at where focused on brand awareness or image shaping of some sort, I wondered if I could create an augmented reality app to test certain usage scenarios.

As part of my research on the paper I found some interesting resources. Sooner or later you will come across “The Reality Editor” developed by fluid interfaces team at the MIT. As the reality editor is basically the front end of an augmented reality solution, the backend is a software called Open Hybrid.

So my idea was, why not try this at home. All it needs is an Arduino Yun or a Raspberry Pi. Both of them are somewhere in my cupboard. And I’m trying to find a useful project for my YUN for years now.

As I’m more sufficient with the Raspberry Pi (that does not mean anything at all), will start there.

Installation on Raspberry Pi B+

As I do not like NOOBS (which is the recommended image), I went for a simple Jessie only Image. After the basic installation is done, which is very well documented here, I started the Pi for the first time.

As I do not have a monitor for the PI, I used KiTTY (Putty works as well) to connect to my PI via SSH. (I used my router to figure out the correct IP address to connect to. If you do not know how to do this, you should connect a monitor, and start the terminal there.)

After I connected I did the “usual” setup. So I entered

sudo raspi-config

There I expanded the file system (1).

config001

Changed my password (2)

config002
Changed the international settings to my liking (3) and then (I1) to (I3).

config003
The rest was ok for me for now. And I rebooted the Pi.

Next thing to do, make sure the pi is up to date.

sudo apt-get update
 sudo apt-get upgrade -y

This might take some time, depending on how many packages need updating.
Now comes the tricky part. For some reasons the pre-installed version of nodejs is not working. So it has to be removed and a new version has to be installed. As so often adafruit has the correct package.

To remove NodeJS just enter:

sudo apt-get remove nodejs

Answer the question with “yes” if asked. In my image there was nothing to remove as NodeJS was not installed.
Now connect to and add the adafruit repository to your Raspberry Pi sources:

curl -sLS https://apt.adafruit.com/add | sudo bash

When done install NodeJS again:

sudo apt-get install -y node

In my case Version 0.12.6-1 was installed. Important is that the version of the package is > 0.12.The installation took quite some time, as the PI B+ is not the fastest.

Now we can finally install the OpenHybrid code, by cloning the github repository.

git clone https://github.com/openhybrid/object.git

config004

We go to the installation path:

cd object

And install the package:

npm install

Again this last step took quite some time. There was a warning that the graceful-fs version was to old – but that was something that can be ignored for now.

config005

Finally I was able start OpenHybrid:

node server.js

The application can be accessed via web browser on port 8080. And it’s working!

config006

That is it for today. In my next port I will play around with the dashboard and create a new object.

3 Comments Add yours

  1. Jake says:

    Hey, you had an article up a few weeks ago about an arduino sourdough incubator. I had the website saved while but Ive been busy for a while and now I come back and the article has gone. Can you re-post the page please?

    The url was at http://electricgardener.net/2013/09/05/how-to-build-an-arduino-based-sourdough-incubator/sourdough-incubator-assembled/

    1. elaiel says:

      Hi Jake
      Thanks for the interest in my little project. I crashed some hardeware last week and as a result lost most of my blog content. Nevertheless I had enought of the content left to recreate the post. You can find it here: http://electricgardener.net/build-arduino-based-sourdough-incubator

Leave a Reply

Your email address will not be published. Required fields are marked *