The Temboo service has moved away from Arduino support. The service access in this older guide will no longer work.
Before we can write the software for our project, we need to install some more software on your Arduino Yun. We are also going to test the USB camera to see if the drivers are working correctly. In the rest of the project, I will assume that your Yun is already setup and connected to your local WiFi network.

First, the UVC drivers. To install them, you need to connect to your Yun via SSH. Simply open a terminal, and type:
Where you need to insert the correct name of your Arduino Yun, that you set when you first used the Yun. You will also be prompted to enter your password. If the connection is successful, you should see some ASCII art:
We can now install the required packages. Start with an update of the package manager:
opkg update
Then, install the UVC drivers:
opkg install kmod-video-uvc
And the python-openssl package:
opkg install python-openssl
We also need the fswebcam utility that we will use to take pictures from the terminal:
opkg install fswebcam
For the last part of the project, we are also going to need the mjpg streaming library. You can get it with:
opkg install mjpg-streamer
We are now ready to test the webcam. Make sure that the SD card is mounted into the Yun, and go over to the SD card folder with:
cd /mnt/sda1
To test the camera and take a picture, it is really easy. Simply type:
fswebcam test.png
You should see some information being displayed, along with some errors, but don't worry about them. The important thing is to see these lines:
--- Opening /dev/video0...
Trying source module v4l2...
/dev/video0 opened.
To check that the picture was correctly taken, remove the SD card from the Yun and read it using your computer. You should see the picture appearing at the root of the SD card:
Simply open it to make sure it was correctly taken and that it is not corrupted. If the picture looks good, you can go over to the next section and start building cool applications with the project!

This guide was first published on Mar 31, 2014. It was last updated on Mar 31, 2014.

This page (Setting up your Arduino Yun) was last updated on Mar 25, 2014.

Text editor powered by tinymce.