{"id":1447,"date":"2014-01-26T13:09:06","date_gmt":"2014-01-26T12:09:06","guid":{"rendered":"http:\/\/www.vennercorp.com\/blog\/?p=1447"},"modified":"2014-01-26T13:09:06","modified_gmt":"2014-01-26T12:09:06","slug":"how-do-i-install-a-camera-on-to-my-raspberry-pi","status":"publish","type":"post","link":"https:\/\/www.vennercorp.com\/blog\/2014\/01\/26\/how-do-i-install-a-camera-on-to-my-raspberry-pi\/","title":{"rendered":"How Do I Install A Camera on to My Raspberry PI?"},"content":{"rendered":"<h1>How Do I Install A Camera on to My Raspberry PI?<\/h1>\n<p>Looking at fitting a camera to your raspberry pi? Luckily it is actually quite simple to do. Just follow the Easy and straight forward instructions below to install your camera.<\/p>\n<p><b>Installing the camera<a href=\"http:\/\/www.vennercorp.com\/blog\/wp-content\/uploads\/2013\/04\/raspberrypi_200.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignright size-full wp-image-901\" alt=\"Raspberry PI\" src=\"http:\/\/www.vennercorp.com\/blog\/wp-content\/uploads\/2013\/04\/raspberrypi_200.png\" width=\"165\" height=\"200\" \/><\/a><\/b><\/p>\n<p>Before installing the camera make sure you are not carrying a static charge by wearing a proper anti static bracelet or discharging yourself on a tap or radiator.<\/p>\n<p>Insert the ribbon cable into the socket located between the Ethernet port and the HDMI socket. Make sure the contacts are facing the HDMI port.<\/p>\n<p>The ribbon cable socket opens by pulling the tabs on the connector towards the Ethernet port, one you have inserted the cable close the socket and make sure the cable is firmly held in place.<\/p>\n<p><b>Update Raspian<\/b><\/p>\n<p>First you will need to update your copy of raspian to the latest version, to make sure all the applicable drivers and software are installed on your pi.<\/p>\n<p>Start your Pi and open a terminal window, now type the following commands to update your software.<\/p>\n<ul>\n<li>\u00a0sudo apt-get update<\/li>\n<\/ul>\n<ul>\n<li>sudo apt-get update upgrade<\/li>\n<\/ul>\n<p><b>Enable the Camera.<\/b><\/p>\n<p><b>\u00a0<\/b>Open the PI\u2019s configuration screen by entering the following command;<\/p>\n<ul>\n<li>\u00a0sudo raspi-config<\/li>\n<\/ul>\n<p>Select camera and move the tab to enable<\/p>\n<p>Click Finish and the restart your PI.<\/p>\n<p><b>Using the Pi\u2019s software <\/b><\/p>\n<p>There are 2 applications that will help you use your camera, raspivid and raspistill. raspivid allows you to capture video and raspistill allows you to capture still\u00a0 pictures.<\/p>\n<p>Both are command line applications.<\/p>\n<p>You can view all the extensions for raspivid or raspistill use the following commands;<\/p>\n<ul>\n<li>\u00a0raspivid | less<\/li>\n<\/ul>\n<ul>\n<li>raspistill | less<\/li>\n<\/ul>\n<p>Type \u201cq\u201d to quit.<\/p>\n<p>Below are some example extensions you can use when calling the applications.<\/p>\n<ul>\n<li>Grab a still image.\n<ul>\n<li>raspistill -o filename.jpg<\/li>\n<\/ul>\n<\/li>\n<li>Grab a short 5 second video using the format h264.\n<ul>\n<li>raspivid -o video.h264<\/li>\n<\/ul>\n<\/li>\n<li>Grab a short 20 second video using the format h264.\n<ul>\n<li>raspivid -o video.h264 -t 20000<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><b>Transmit your Video feed<\/b><\/p>\n<p>Type the following command into the terminal window on your PI.<\/p>\n<ul>\n<li>raspivid -t 999999 -o &#8211; | nc [IP Address of the receiving device] 5001<\/li>\n<\/ul>\n<p>Insert the IP Address of the receiving device in to the area indicated above, get the IP by using the command ipconfig on the receiving device.<\/p>\n<p>&nbsp;<\/p>\n<p><b>Receive your Video feed<\/b><\/p>\n<p><span style=\"text-decoration: underline;\">Windows<\/span><\/p>\n<p>You will need 2 programs Mplayer and Netcat, grab them from from the 2 urls below;<\/p>\n<ul>\n<li><a href=\"https:\/\/code.google.com\/p\/mplayer-for-windows\/downloads\/detail?name=mplayer-svn-36251.7z&amp;can=2&amp;q=\">mplayer<\/a><\/li>\n<\/ul>\n<ul>\n<li>\u00a0<a href=\"joncraton.org\/media\/files\/nc111nt.zip\">netcat<\/a><\/li>\n<\/ul>\n<p>Open up your terminal window by the shortcut in your programs menu or by typing cmd into the run or search boxs<\/p>\n<p>Now Type in<\/p>\n<ul>\n<li>[Path to netcat]\\nc.exe -L -p 5001 | [Path to mplayer]\\mplayer.exe -fps 31 -cache 1024 &#8211;<\/li>\n<\/ul>\n<p><b>Raspberry Pi<\/b><\/p>\n<p>Open up the terminal window on your PI and then type in the following commands;<\/p>\n<ul>\n<li>mkfifo buffer<\/li>\n<\/ul>\n<ul>\n<li>nc -p 5001 -l &gt; buffer | \/opt\/vc\/src\/hello_pi\/hello_video\/hello_video.bin buffer<\/li>\n<\/ul>\n<p><strong>For more Tutorials and Hints &amp; Tips on the Raspberry PI check out our <a title=\"Raspberry PI Tutorials\" href=\"http:\/\/www.vennercorp.com\/blog\/2013\/04\/14\/how-to-wipe-sd-card-before-installing-os-on-raspberry-pi\/\" target=\"_blank\">Raspberry PI Blog Section<\/a><\/strong><\/p>\n<p><strong>If you would like to Buy a Raspberry PI, its accessories or software check out our &#8211;<\/strong><\/p>\n<ul>\n<li><a title=\"VennerCorp Online Shop Raspberry PI section\" href=\"http:\/\/shop.vennercorp.com\/raspberry-c-22.html\" target=\"_blank\">Raspberry PI section on our Online Shop.<\/a><\/li>\n<li><a title=\"VennerCorp Ebay Shop\" href=\"http:\/\/www.ebay.co.uk\/sch\/vennercorp\/m.html?_nkw=&amp;_armrs=1&amp;_from=&amp;_ipg=&amp;_trksid=p3686\" target=\"_blank\">Our Ebay Raspberry PI shop.<\/a><\/li>\n<\/ul>\n<p><strong>If you would like help with your Raspberry PI, computer or laptop then please <a href=\"http:\/\/www.vennercorp.com\/html\/get_a_quote.php\">contact us<\/a> or visit our <a href=\"http:\/\/www.vennercorp.com\/html\/help_and_support.html\">IT Support<\/a> Page.<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>How Do I Install A Camera on to My Raspberry PI? Looking at fitting a camera to your raspberry pi? Luckily it is actually quite simple to do. Just follow the Easy and straight forward instructions below to install your camera. Installing the camera Before installing the camera make sure you are not carrying a&hellip; <a class=\"more-link\" href=\"https:\/\/www.vennercorp.com\/blog\/2014\/01\/26\/how-do-i-install-a-camera-on-to-my-raspberry-pi\/\">Continue reading <span class=\"screen-reader-text\">How Do I Install A Camera on to My Raspberry PI?<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[53,80,78,121,7],"tags":[196,304,99,314],"class_list":["post-1447","post","type-post","status-publish","format-standard","hentry","category-computer","category-electronics","category-hints-and-tips","category-raspberry-pi","category-vennercorp","tag-camera","tag-computer","tag-hints-tips","tag-raspberry-pi","entry"],"_links":{"self":[{"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/posts\/1447","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/comments?post=1447"}],"version-history":[{"count":4,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/posts\/1447\/revisions"}],"predecessor-version":[{"id":1451,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/posts\/1447\/revisions\/1451"}],"wp:attachment":[{"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/media?parent=1447"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/categories?post=1447"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.vennercorp.com\/blog\/wp-json\/wp\/v2\/tags?post=1447"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}