Raspberry Pi Camera Module Review and Setup

The kind people at RobotShop sent me a Raspberry Pi Camera module for a review. In this post I will go through the setup of the camera module, taking the first picture and  first video.

IMG_0695

Note: This is the older 5MP version of the module. There is a new 8MP upgraded module released recently.

Before we start here are some specs on the camera module I found on the RobotShop product page :

  •  5 megapixel OV5647 sensor in a fixed-focus module.
  • Camera specifications:
    • CCD size : 1/4 inch
    • Aperture (F) : 2.8
    • Focal Length : 3.37 mm
    • Diagonal : 72.4 degree
    • Sensor best resolution : 1080p
  • 2592 × 1944 still picture resolution
  • Support 1080p30, 720p60 and 640x480p60/90 video record.

 

Enabling the Raspberry Pi Camera Module:

The advantage of the RPi Camera Module over a USB webcam is that there is no need to install drivers or any support software since the latest version of Raspbian Jessie comes with the picamera app installed. This means that the camera can be accessed using the command line. In order to enable this feature first enable the Raspberry Pi Camera Module in the raspi-config menu and reboot. This will enable you to control the module via the terminal window.

Taking your first picture :

Enter the command :

raspistill -o img1.jpg

Screenshot (96)

Here the picture will be saved in the home/pi directory and the file name will be img1. Once you press enter a box will open showing the camera feed and the image will be clicked after a few seconds delay. Type ls to check that your file is saved in the home directory. I have provided a screenshot where the file is highlighted :

Screenshot (99)

The image taken by the camera :

imgpic

 

Taking your first video :

Taking a video using the camera module is as easy as taking a picture. Enter the command in the terminal  as shown in the screenshot:

raspivid -0 vidtest.h264 -t 10000

Screenshot (97)

For taking a video the raspivid command is used. The file will be saved as vidtest in h264 format since that is the format output by the Raspberry Pi Camera Module. This video file will be save in the home/pi directory.

The -t 10000 parameter sets the length of the video. It is given in miliseconds so 10000 would correspond to 10000 mS i.e. 10 Seconds. This parameter can be changed depending on the length of video you would want to record. The default value is 5 seconds.

I’ve had success playing the video using VLC however I’d recommend using an online mp4 converter so that sharing the video on YouTube would be possible. Here is the video I took using the Raspberry Pi Camera Module :

Note : There is no audio on the video since the Raspberry Pi Camera Module consists of only a camera sensor and does not have a built in microphone.

More pictures :

I also made a case/stand for the camera module so that it can take steady pictures and video. I’ve included pictures of the build here.

I plan to use this module in order to build a lane-tracking and obstacle detection car  using OpenCV and Python. I will update the progress of that project in another post. Till then i highly reccomend the OpenCV tutorials on Pyimagesearch.

Advertisements

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: