{"id":353,"date":"2019-03-31T12:51:42","date_gmt":"2019-03-31T16:51:42","guid":{"rendered":"http:\/\/ninecrows.com\/pandamallet\/?p=353"},"modified":"2019-04-01T07:11:32","modified_gmt":"2019-04-01T11:11:32","slug":"onwards-to-linux-c-opencv-and-capturing-some-frames","status":"publish","type":"post","link":"https:\/\/ninecrows.com\/pandamallet\/2019\/03\/31\/onwards-to-linux-c-opencv-and-capturing-some-frames\/","title":{"rendered":"Onwards to Linux C++ OpenCV and Capturing Some Frames"},"content":{"rendered":"\n<p>I proven that the cameras can run on  Ubuntu and the RPi. I found a page with classic Unix\/Linux style install <a href=\"https:\/\/www.learnopencv.com\/install-opencv3-on-ubuntu\/\">instructions<\/a>. I&#8217;ll be working on getting this set up on my biggest RPi machine and take a look at building code to red from multiple cameras and stream the data to a host. If I can run two cameras on a single RPi then I should be set. <\/p>\n\n\n\n<p>I&#8217;ll probably also look at doing something similar for the RPi cameras on the RPi-2 machines. That might add a couple of additional cameras to my set.<\/p>\n\n\n\n<p>I&#8217;ll then move on to building a simple LED beacon and look at some simple camera calibration code on an appropriate host.<\/p>\n\n\n\n<p>Trying to build the OpenCV package on one of my RPi 3 machines. I think I&#8217;m running into heat issues. I&#8217;ve switched to a board that I can keep open and has a heat sink on it. Hoping that may be enough. I&#8217;ve also dropped the build scripts onto github to make them broadly available.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"alignright is-resized\"><img decoding=\"async\" loading=\"lazy\" src=\"http:\/\/ninecrows.com\/pandamallet\/wp-content\/uploads\/2019\/03\/IMG_20190331_154408-1024x768.jpg\" alt=\"\" class=\"wp-image-356\" width=\"303\" height=\"227\" srcset=\"https:\/\/ninecrows.com\/pandamallet\/wp-content\/uploads\/2019\/03\/IMG_20190331_154408-1024x768.jpg 1024w, https:\/\/ninecrows.com\/pandamallet\/wp-content\/uploads\/2019\/03\/IMG_20190331_154408-300x225.jpg 300w, https:\/\/ninecrows.com\/pandamallet\/wp-content\/uploads\/2019\/03\/IMG_20190331_154408-768x576.jpg 768w\" sizes=\"(max-width: 303px) 100vw, 303px\" \/><\/figure><\/div>\n\n\n\n<p>Pulling packages on this machine now.<\/p>\n\n\n\n<p>Now I&#8217;ve got a fan blowing. I see from some web pages that the RPi is supposed to warn and throttle when the temperature spikes&#8230;didn&#8217;t see that with my black and silver RPi 3&#8230;it seemed to halt completely after a short span. Keeping this one cool up front and we&#8217;ll see how this goes.<\/p>\n\n\n\n<p>Interesting&#8230;it looks as if the scipy build is eating all available physical memory on the RPi board (882 MB of 923 total). Nothing moving on the machine&#8230;not even the mouse cursor.<\/p>\n\n\n\n<p>Ah, reference <a href=\"https:\/\/www.pyimagesearch.com\/2018\/09\/26\/install-opencv-4-on-your-raspberry-pi\/\">here <\/a>to bumping the swap file for the RPi.<\/p>\n\n\n\n<p>Monday morning dawns and it appears that I have  a raspberry pi that is loaded up with an installed build of OpenCV. No time this morning to test this but tonight I&#8217;ll run through a few simple tests and then probably run the same process on one of my Intel NUC machines (should go faster and easier) to get a decently powerful system up and working with the same version.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Reading from cameras on Linux and streaming data back to a  single host for processing. OpenCV and a bit of sockets code.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[15,21],"tags":[],"_links":{"self":[{"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/posts\/353"}],"collection":[{"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/comments?post=353"}],"version-history":[{"count":6,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/posts\/353\/revisions"}],"predecessor-version":[{"id":361,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/posts\/353\/revisions\/361"}],"wp:attachment":[{"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/media?parent=353"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/categories?post=353"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ninecrows.com\/pandamallet\/wp-json\/wp\/v2\/tags?post=353"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}