Book Image

BeagleBone By Example

By : Pei JIA, Jayakarthigeyan Prabakar, Alexander Hiam
Book Image

BeagleBone By Example

By: Pei JIA, Jayakarthigeyan Prabakar, Alexander Hiam

Overview of this book

BeagleBone is a low cost, community-supported development platform to develop a variety of electronic projects. This book will introduce you to BeagleBone and get you building fun, cool, and innovative projects with it. Start with the specifications of BeagleBone Black and its operating systems, then get to grips with the GPIOs available in BeagleBone Black. Work through four types of exciting projects: building real-time physical computing systems, home automation, image processing for a security system, and building your own tele-controlled robot and learn the fundamentals of a variety of projects in a single book. By the end of this book, you will be able to write code for BeagleBone in order to operate hardware and impart decision-making capabilities with the help of efficient coding in Python.
Table of Contents (17 chapters)
BeagleBone By Example
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Logging into the board via SSH over Ethernet


If you are familiar with Linux operations, then you might have guessed what this section is about. But for those people who are not daily Linux users or have never heard the term SSH, Secure Shell (SSH) is a network protocol that allows network services and remote login to be able to operate over an unsecured network in a secure manner. In basic terms, it's a protocol through which you can log in to a computer and assess its filesystem and also work on that system using specific commands to create and work with files on the system.

In the steps ahead, you will work with some Linux commands that will make you understand this method of logging into a system and working on it.

  1. Setup SSH Software.

    To get started, log in to your BeagleBone board now, from a Windows PC, you need to install any SSH terminal software for Windows.

    My favorite is PuTTY, so I will be using that in the steps ahead. If you are new to using SSH, I would suggest you also get PuTTY.

    The software interface of PuTTY will be as shown in the following screenshot:

    You need to know the IP address or the Host Name of your BeagleBone Black to log in to it via SSH. The default Host Name is beaglebone but in some routers, depending on their security settings, this method of login doesn't work with Host Name. So, I would suggest you try to login entering the hostname first. If you are not able to login, follow step 2. If you successfully connect and get the login prompt with Host Name, you can skip step 2 and go to Step 3.

    But if you get an error as shown in the following screenshot, perform Step 2.

  2. Find an IP address assigned to BeagleBone board.

    Whenever you connect a device to your Router, say your computer, printer, or mobile phone. The router assigns a unique IP to these devices. The same way, the router must have assigned an IP to your BeagleBone board also. We can get this detail on the router's configuration page of your router from any browser of a computer that is connected to that router.

    In most cases, the router can be assessed by entering the IP 192.168.1.1 but some router manufacturers have a different IP in very rare cases. If you are not able to assess your router using this IP 192.168.1.1, refer your router manual for getting access to this page.

    Note

    The images that are shown in this section are to give you an idea about how to log in to your router and get the IP address details assigned to your BeagleBone board from your router. The configuration pages and how the devices are shown on the router will look different depending on the router that you own.

    Enter the 192.168.1.1 address in you browser.

    When it asks for User Name and Password, enter admin as User Name and password as Password

    These are the mostly used credentials by default in most of the routers. Just in case you fail in this step, check your router's user manual.

    Considering you logged into your router configuration page successfully, you will see the screen with details as shown in the following screenshot:

    If you click on the highlighted part, Attached Devices, you will be able to see the list of devices with their IP as shown in the following screenshot, where you can find the details of the IP address that is assigned to your BeagleBone board.

    So now you can note down the IP that has been assigned to your BeagleBone board. It can be seen that it's 192.168.1.14 in the preceding screenshot for my beaglebone board. We will be using this IP address to connect to the BeagleBone board via SSH in the next step.

  3. Connect via SSH using IP Address.

    Once you click on Open you might get a security prompt as shown in the following screenshot. Click on Yes and continue.

    Now you will get the login prompt on the terminal screen as shown in the following screenshot:

    If you got this far successfully, then it is time to log in to your BeagleBone board and start working on it via Linux Shell.

  4. Log in to BeagleBone board.

    When you get the login prompt as shown in the preceding screenshot, you need to enter the default username which is debian and default password which is temppwd. Now you should have logged into Linux Shell of your BeagleBone board as user with username debian.

Now that you have successfully logged into your BeagleBone board's Linux Shell, you can start working on it using Linux Shell commands like anyone does on any computer that is running Linux.

The next section will walk you through some basic Linux Shell commands that will come in handy for you to work with any Linux system.