Raspberry Pi and Motion Graphing

MrMobileWill Debian, Linux, raspberry pi, Tutorials, wheezy 0 Comments

This week was the week of Raspberry Pi goodness and lots of coding. Now that I had the PIR sensor working, I wanted to do something with that data over time. I decided to log the data to MySQL running on my web server instead of the Pi. The Pi is awesome but I didn’t want the overhead of running MySQL  on it along with writing constantly to the SD Card. Here is how I did it, after the break. First thing was to setup the database on my Web server which is running Server 2008 R2 on my VMWare ESXi server. I ended up using the Web Platform installer to install MySQL 5.1 and PHP. I probably won’t need …

Raspberry Pi and Wheezy

MrMobileWill Debian, Linux, raspberry pi, Tutorials 0 Comments

I finally decided to take the plunge and upgrade to Debian Wheezy. I have been putting it off because Squeeze works and it would involve re-configuring everything I have setup so far. At the same time, the longer I wait the more stuff there will be to setup. The great thing about re-installing: I get to do a clean install without the mistakes of figuring things out. It is also a refresher of how I got where I am now. Jump below for notes about the upgrade process. Firstly, you should make a backup of the SD card in case you need to restore back or to check how you did something. I used win32diskimager on my Windows 7 PC to make an …

Raspberry and a PIR Sensor

MrMobileWill adafruit, c, Programming, raspberry pi 0 Comments

Last month I bought a PIR as part of my Adafruit order for Raspberry Pi stuff. This weekend I decided to try and use it with the RPi.  PIR Sensor (image from Adafruit) Rear of PIR Sensor (image from Adafruit) Using the WiringPi library, it was pretty easy to get it up and running. Here is a picture of it mounted on top of the Prototyping Pi Plate from Adafruit with double-sided tape. Raspberry Pi Plate with PIR and LED I connected it to GPIO 18 or pin 1 in the WiringPi library. Here is the code I used that blinks the LED when there is motion. I used the same technique as the blinking LED test so that I …


MrMobileWill Debian, raspberry pi, Tutorials 0 Comments

I was reading about the release of Chromium for the Raspberry Pi and read a comment about changing the memory split using rpi-update. I decided to see what it was all about. RPi-Update makes it much easier to change the memory split and keeping the firmware up to date rather than doing it manually. You can find it here https://github.com/Hexxeh/rpi-update/ Here is how I ended up getting it to install without the errors I got. This is based on the Debian Squeeze release from 06-19-2012. I haven’t switched to Wheezy yet. sudo apt-get install ca-certificatessudo apt-get install git-coresudo wget http://goo.gl/1BOfJ -O /usr/bin/rpi-update && chmod +x /usr/bin/rpi-updatesudo ldupdatesudo rpi-update If you get a error about the library then (I can’t remember the exact message) …

Raspberry Pi releases Debian Wheezy

MrMobileWill Debian, On the Web, raspberry pi 0 Comments

It has arrived: We are pleased to announce the release of our  first SD card image based on the Raspbian distribution. This is the result of an enormous amount of hard work by Alex and Dom over the past couple of months, and replaces the existing Debian squeeze image as our recommended install. Notably, it is the first official image to take full advantage of the Raspberry Pi’s floating point hardware for, amongst other things, much faster web browsing SOURCE: RaspberryPi.org Now to figure out if I can upgrade. Sounds like it would be worth the trouble to upgrade from scratch.

Raspberry Pi and GPIO Permissions

MrMobileWill Linux, php, Programming, raspberry pi, Tutorials 10 Comments

It works! Okay, back up a little. Getting a PHP web interface to talk to hardware proved to be rather difficult. You need root access to control hardware but the web service runs with minimal permissions. So how does one bridge the gap without compromising the system? The answer, very carefully. I found a few workarounds but they involved either using MySQL or the gpio-admin library that works from commandline or shell scripts. In my case I wanted to stay with using C programs with the wiringPi library being called from PHP. C is much faster to control GPIO and PHP gives me a web front end. Here is how I did it. First the PHP process needs a way to run the binary as …

Raspberry Pi, CommandIR and Beyond

MrMobileWill c, HomeAutomation, php, Programming, raspberry pi, Tutorials 6 Comments

Now that I have had some time to play with the CommandIR, progress has been made. Of the two initial issues I have one left. The first issue is that LIRCD doesn’t auto start even though it is configured in the hardware.conf. While researching, I came to the conclusion that LIRC isn’t reading the hardware.conf at all. I made a change to it, enabling the listen option to try an Android app but it didn’t take effect. When I manually start LIRCD I have to include the options at the commandline. This is still a mystery but I am working with support on it. The odd thing is the init.d service script doesn’t seem to do anything. TV with IR Emitter Xbox S with IR Emitter …

Raspberry Pi and CommandIR

MrMobileWill HomeAutomation, raspberry pi, Tutorials 0 Comments

While reading an article the other day I had an idea formulate in my head. I have a older USB CommandIR Mini that has 4 emitters and 1 receiver. This would make a great use of the Raspberry Pi, a network based IR gateway. Originally it was only for Linux, but now it is supported in WinLIRC which I haven’t tired. Newer version of mine First thing was to do some research and see about getting it to work on the Raspberry Pi with an ARM CPU. So here is a run down of how I got it to work. Rear ports Get LIRC installed: The version that is available in the Debian Squeeze repository isn’t new enough to support the CommandIR. In this case you need to download the lastest version …

Checking out the temperature of a Raspberry Pi

MrMobileWill On the Web, raspberry pi 0 Comments

[Remy] has access to a very nice Fluke thermal camera, so when his Raspberry pi came in he pointed the thermal camera at the Raspi (Spanish, Google translation) to see how far this neat computer could be pushed before it overheated. There are three main sources of heat on the Raspberry Pi: the voltage regulator, the USB/Ethernet controller and the Broadcom SoC. At idle, these parts read 49.9° C, 48.7° C and 53° C, respectively; a little hot to the touch, but still well within the temperature ranges given in the datasheets for these components. The real test came via a stress test where the ARM CPU was at 100% utilization. The Broadcom SoC reached almost 65° C while the …

The Raspberry Pi is Running: Getting You There

MrMobileWill Debian, Linux, Programming, raspberry pi, Tutorials 0 Comments

Excited, I ripped open the package to find my Raspberry Pi. The packing looked like it had been run over but my Pi was still intact. Yay! First thing I realized I needed to find a power source and a SD card. After some digging I just ended up using an iPad power adapter with a cell phone micro USB cable. I was going to use my Galaxy S power adapter but I didn’t want to run it close to the limit of 700ma. For some reason I thought I had plenty of SD cards around, but I guess not. Luckily Best Buy had a 32GB Sandisk Ultra class 10 available in store for $27. Perfect! Raspberry Pi packaging, amazing it wasn’t damaged For the most part I hard …