element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      • Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
BeagleBoard
  • Products
  • Dev Tools
  • Single-Board Computers
  • BeagleBoard
  • More
  • Cancel
BeagleBoard
Blog BeagleBone Blue - enable ssh before updating.
  • Blog
  • Forum
  • Documents
  • Quiz
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join BeagleBoard to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: carmelito
  • Date Created: 21 Oct 2017 5:31 AM Date Created
  • Views 3191 views
  • Likes 4 likes
  • Comments 2 comments
  • mjpg-streamer
  • beaglebone blue
  • BeagleBone
  • fswebcam
  • webcam
Related
Recommended

BeagleBone Blue - enable ssh before updating.

carmelito
carmelito
21 Oct 2017

This blog post discuss a weird  issue I faced when upgrading (apt-get upgrade) the Beaglebone blue and how I overcame the issue, basically the lesson learnt here is to enable SSH on the Beaglebone before doing anything else.

 

In addition, in the second half of the blog, I have also include the list of commands I used to setup USB webcam, to steam video over WiFi.This is going to help with demoing the features of the Beaglebone Blue as part of my Roadtest review, and a  couple mini projects I plan to do along the way. For this you will need an USB powered hub, to connect the web cam to the Beaglebone as you see in the picture below.

 

image

 

 

I received my Beaglebone Blue last week for a Roadtest review, and the first thing I did after going through the documentation, was to open the Cloud 9 IDE in Firefox using the url http://192.168.7.2:3000/ide.html and setup the WiFi network using the connmanctl command, and selecting my wifi router.

 

The next obvious step was to update and upgrade the Beaglebone blue, using the following commands

root@beaglebone:/var/lib/cloud9# apt-get update
root@beaglebone:/var/lib/cloud9# apt-get upgrade

 

Since the upgrade command required 170 MB of space to upgrade all the software, I left this to run and head to the kitchen to make myself a cup of tea. But after I was back in about 5 mins, I found my Beaglebone was shutdown, so I disconnected and reconnected my USB cable, and found that default drive for my Beaglebone showed up and I was able to launch default page using http://192.168.7.2 , but was not able to open the Cloud 9 IDE using http://192.168.7.2:3000/ide.html. Then I tried to SSH into the Beaglebone using IP address given to the Beaglebone by my router,(I figure this out by running the nmap command on my laptop), but I was not able to login. I then found a couple of blog post on the internet, that said ssh is not enabled by default on the Beaglebone with Debain Jessie, this meant I was stuck image . After trying a few more things in vain for the next couple of hour, I took a break and revisited the issue again in a couple of days.

 

Now , when scrolling through the default Beaglebone page at  http://192.168.7.2  I came across Node –RED, which I knew had a feature to execute system commands, based on reading a few blog post about Node-RED  on the Raspberry Pi.

image

This was the first time I used  Node – RED, and I just added 3 steps as you see in the screen shot below. The exec step is the middle step named ‘test’, and is used to run commands, so the first thing I ran was a simple ls command to check if this would work, and yes it did !. This meant I then ran

mkdir /var/lib/cloud9  -to create the missing cloud9 ide folder, which could have potentially be deleted as part of the apt-get upgrade process that did not complete.

 

And then I modified the exec step again with – reboot, but after the Beaglebone rebooted this dint do the trick image, I then upgrade step again with

apt-get upgrade

which took about 10 mins to complete, and this time around at sat at my desk without moving a mussel image, and then reboot the Beaglebone. And finally hooray image  the cloud9 ide was up and running again.

 

Now the first thing I did was enable SSH using

root@beaglebone:/var/lib/cloud9# nano /etc/ssh/sshd_config

and then modifying the following section

from:

PermitRootLogin without-password

To:

PermitRootLogin yes

 

And then restarted the ssh service, and was able to login to the Beaglebone from my laptop via the terminal(if you are using Window then this would be something like putty.exe)

root@beaglebone:/var/lib/cloud9# /etc/init.d/ssh restart
[ ok ] Restarting ssh (via systemctl): ssh.service.

 

 

 

I also plan to do a couple of mini projects as part of my Roadtest for the Beaglebone Blue, which meant I had to use the USB webcam to demo, while simultaneously running commands on my laptop and doing a screen record of my laptop.This is something I saw in most of the youtube videos posted about the BeagleBone blue .Here are step to install mjpg_streamer to stream video from the usb webcam to the laptop via wifi. For this you will also need a powered USB hub.

 

Before you move ahead with the steps below check if your webcam is detected using lsusb, in my case I am using a very old Logitech C270 webcam.

root@beaglebone:~# lsusb
Bus 001 Device 003: ID 046d:0825 Logitech, Inc. Webcam C270
Bus 001 Device 002: ID 1a40:0101 Terminus Technology Inc. 4-Port HUB
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

 

Now if you USB webcam is detected run the following commands

root@beaglebone:~#apt-get install libjpeg62-turbo-dev imagemagick libv4l-dev

 

Then download the modified version of MJPG-Streamer from Shrkey github repo, and then extract it, and install

  root@beaglebone:~#wget https://github.com/shrkey/mjpg-streamer/raw/master/mjpg-streamer.tar.gz
  root@beaglebone:~#tar -xvf mjpg-streamer.tar.gz
  root@beaglebone:~#cd mjpg-streamer
  root@beaglebone:~/mjpg-streamer# make
  root@beaglebone:~/mjpg-streamer# sudo make install

 

Now, if you are using the same webcam as I am run, the following command

root@beaglebone:~/mjpg-streamer#./mjpg_streamer -i "./input_uvc.so -y YUYV" -o "./output_http.so -p 8090 -n -w ./www"

 

image

Note: if you are using a different web cam you may have to modify the command above, to include the video format of your webcam. To check the video format run

root@beaglebone:~/mjpg-streamer#v4l2-ctl --list-formats

 

To login checkout the video stream of you webcam use the url http://BeagleBoneIPaddress:8090/?action=stream

 

image

Note: If you are only interested in taking picture with the webcam you can install fswebcam, using apt-get install fswebcam.

  • Sign in to reply

Top Comments

  • DAB
    DAB over 8 years ago +1
    Nice update. How easy did you find Node Red to learn and use? DAB
  • carmelito
    carmelito over 8 years ago in reply to DAB

    Thanks DAB, it was surprising easy to get started with Node Red, I was putting it off for sometime now, because I thought it would have a good enough learning curve to it, but this situation forced me to use it , which is great!!  I have just put two flow together till today, and have a long way to go - Carmelito

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB over 8 years ago

    Nice update.

     

    How easy did you find Node Red to learn and use?

     

    DAB

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube