I have my RPi with its camera in my hand, finally. But I need to remote the RPi camera display from my macbook laptop, how? Well its explained well in here http://www.raspberrypi.org/archives/tag/camera-board . The main thing i need to do is install mplayer and netcat application on my macbook, and after searching the packages, I found that homebrew packages framework is the coolest so far, and very light. Before that, I have and installed the macports, but after couple times upgrading the OS until mountain lion, the macports need to be upgrade as well, quite complicated, and very heavy framework though. Ok, now i removed the current macports and migrate to homebrew, cool? lets start with the installation by typing this below.
ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"
The installation itself was very easy, and clean. The homebrew ( http://brew.sh/ ) running under ruby. After done the installation we can verify the latest packages by typing below…
biskandar:~ benny$ brew update Already up-to-date. biskandar:~ benny$ brew Example usage: brew [info | home | options ] [FORMULA...] brew install FORMULA... brew uninstall FORMULA... brew search [foo] brew list [FORMULA...] brew update brew upgrade [FORMULA...]
So, for back to the mplayer and netcat installation , by the way mplayer is the mpeg player and netcat is a simple tool to read and write data across network connections, i just did by typing this below command
biskandar:~ benny$ brew install mplayer netcat Warning: Your Xcode (4.6.2) is outdated Please install Xcode 4.6.3. ==> Installing mplayer dependency: fontconfig ==> Downloading http://fontconfig.org/release/fontconfig-2.10.93.tar.bz2 Already downloaded: /Library/Caches/Homebrew/fontconfig-2.10.93.tar.bz2 ==> Patching patching file src/fcarch.h ==> ./configure --with-add-fonts=/Library/Fonts,~/Library/Fonts --prefix=/usr/local/Cellar/fontconfig/2.10.93 ==> make install 🍺 /usr/local/Cellar/fontconfig/2.10.93: 447 files, 4.8M, built in 87 seconds ==> Installing mplayer ==> Downloading http://www.mplayerhq.hu/MPlayer/releases/MPlayer-1.1.tar.xz ==> ./configure --prefix=/usr/local/Cellar/mplayer/1.1 --cc=cc --host-cc=cc --disable-cdparanoia --disable-libopenjpeg --enable-menu --disable-x11 ==> make ==> make install 🍺 /usr/local/Cellar/mplayer/1.1: 9 files, 19M, built in 5.6 minutes ==> Downloading http://downloads.sourceforge.net/sourceforge/netcat/netcat-0.7.1.tar.bz2 ==> ./configure --prefix=/usr/local/Cellar/netcat/0.7.1 --mandir=/usr/local/Cellar/netcat/0.7.1/share/man --infodir=/usr/local/Cellar/netcat/0.7.1/shar ==> make install 🍺 /usr/local/Cellar/netcat/0.7.1: 9 files, 116K, built in 24 seconds
After done the installation , ok now i can remote my RPi camera from my laptop . How ? go to my RPi and stream all the display to laptop with port 5001 , the streaming itself done by netcat command , type below in the RPi
pi@raspberrypi ~ $ raspivid -t 90000 -o - | nc 192.168.2.11 5001
The raspivid is the command builtin inside RPi to display the RPi camera and record as video, and I set the timing about forever like 90000 ms. The output of the video will be stream into my laptop with current 192.168.2.11 and local listener port 5001.
And last on my laptop i shall execute this command to start the stream listener.
biskandar:~ benny$ nc -l 5001 | mplayer -fps 31 -cache 1024 - MPlayer 1.1-4.2.1 (C) 2000-2012 MPlayer Team Playing -. Reading from stdin... Cache fill: 4.30% (45056 bytes)
Done, now here the screen shot …