Getting started with Bela » History » Version 9
Version 8 (Giulio Moro, 2015-07-17 12:21 PM) → Version 9/45 (Giulio Moro, 2015-07-17 01:12 PM)
h1. Getting started with BeagleRT
h2. Prerequisites
Before starting, make sure you have:
* Beaglebone Black
* BeagleRT cape
* standard-A to mini-B USB cable
* 2GB or more micro-SD card
* Optional, but recommended: up to two 3-ways female connectors for audio in/out from the cape. You will probably want some sort of stereo female jack connector at the other end.
h2. Hardware setup
Stack the audio cape on top of the Beaglebone Black (BBB). Make sure all the pins from the cape fit into the socket header of the BBB and that no pin gets bent in the process.
[TODO: connector wiring]
h2. Software setup
Clone the disk image from [TODO: url] on the SD card. This image contains a Debian 7.7 distribution with Xenomai extensions which contains all the toolkits needed to compile and run BeagleRT projects.
Insert the SD card into the BBB and plug it into your computer with the USB cable. The BBB will boot Debian and advertise itself to your computer as a network interface.
Communication between the BBB and the host pc takes place through the Ethernet over USB network connection. In order to log into the BBB you need an ssh client and you might need some network drivers according to your operating system, as detailed below.
h3. Linux users
All you need should be already on your machine, jump to *Test the ssh connection* below and have fun!
h3. MacOS users
* install network drivers for the BBB from http://beagleboard.org/static/Drivers/MacOSX/RNDIS/HoRNDIS.pkg and the serial drivers from http://beagleboard.org/static/Drivers/MacOSX/FTDI/EnergiaFTDIDrivers2.2.18.pkg
* make sure the BBB is plugged in and booted up (might take up to one minute after you plug it in).
* go to System Preferences->Network, click the + symbol at the bottom left. From the popup window, select "Beaglebone Black"
* now set the "Configure IP v4" field to "Using DHCP with manual address" and set the IP address to 192.168.7.1
!ss_dhcp.png!
* click apply and wait a few seconds, the indicator close to the icon should turn green
* jump to the *Test the ssh connection* section below to check that everything is working properly
h3. Windows users
* you will need a toolkit that allows you to use ssh and some other basic shell tools. The shell scripts in this project have been tested with *mingw* http://mingw.org/ . You will want to note that in order to paste code on the mingw terminal you have to right click on the terminal's title bar and navigate the menu to edit->paste .
* additionally, you need to install the network drivers from http://beagleboard.org/static/Drivers/Windows/BONE_D64.exe (Windows 64 bit) or http://beagleboard.org/static/Drivers/Windows/BONE_DRV.exe (Windows 32bit)
* in the network connections manually set thel IP address for the BBB to 192.168.7.1
!win.png!
* jump to the *Test the ssh connection* section below to check that everything is working properly
h3. Test ssh connection
When using the USB network connection, the BBB has a self-assigned IP of 192.168.7.2, we will log in with username *root* and password *a* .
If you have gone through operating system-specific steps above, you should be able to connect to the beaglebone with
<pre>$ ssh root@192.168.7.2</pre>
According to the settings of your ssh client, you might, or might not, be prompted with something along the lines of
<pre>The authenticity of host '192.168.7.2 (192.168.7.2)' can't be established.
RSA key fingerprint is 35:b2:ff:ae:c2:02:30:af:84:1e:0d:f5:c9:c8:4b:34.
Are you sure you want to continue connecting (yes/no)? </pre>
type @yes@ and press the return key.
Next, you will be prompted with the password.
Enter a single *a* character and hit the return key.
If everything is ok, you will now be displayed the BBB prompt:
<pre>root@arm ~$</pre>
h3. (Optional) ssh keys setup
ssh would require you to enter the password everytime you open a connection to the BBB. This will happen a few times during setup and then 3 times every time you build and run your project. To avoid quickly getting annoyed by this, you can use ssh keys. In the @scripts/@ you will find a setup script which
* generates (if not exists) a key-pair on your host machine (stored in @~/.ssh/@ )
* sets the @~/.ssh/config@ file
* copies the public key to the BBB
To do so, run the @./setup-ssh-windows.sh@ if you are on Windows or @./setup-ssh.sh@ otherwise from the @scripts/@ folder
This way you will be able to log into the BBB simply typing:
<pre>ssh bbb</pre>
h2. Build your first project
Do you want to get started immediately, without need to install any software on your machine? Grab a terminal and learn about [[ Compiling BeagleRT projects on the board]]
Do you want to turn your computer into a cross-compiling machine, with the advantages of an IDE and you are willing to put (some) effort into it? [[ Compiling BeagleRT projects in Eclipse]]
h2. Prerequisites
Before starting, make sure you have:
* Beaglebone Black
* BeagleRT cape
* standard-A to mini-B USB cable
* 2GB or more micro-SD card
* Optional, but recommended: up to two 3-ways female connectors for audio in/out from the cape. You will probably want some sort of stereo female jack connector at the other end.
h2. Hardware setup
Stack the audio cape on top of the Beaglebone Black (BBB). Make sure all the pins from the cape fit into the socket header of the BBB and that no pin gets bent in the process.
[TODO: connector wiring]
h2. Software setup
Clone the disk image from [TODO: url] on the SD card. This image contains a Debian 7.7 distribution with Xenomai extensions which contains all the toolkits needed to compile and run BeagleRT projects.
Insert the SD card into the BBB and plug it into your computer with the USB cable. The BBB will boot Debian and advertise itself to your computer as a network interface.
Communication between the BBB and the host pc takes place through the Ethernet over USB network connection. In order to log into the BBB you need an ssh client and you might need some network drivers according to your operating system, as detailed below.
h3. Linux users
All you need should be already on your machine, jump to *Test the ssh connection* below and have fun!
h3. MacOS users
* install network drivers for the BBB from http://beagleboard.org/static/Drivers/MacOSX/RNDIS/HoRNDIS.pkg and the serial drivers from http://beagleboard.org/static/Drivers/MacOSX/FTDI/EnergiaFTDIDrivers2.2.18.pkg
* make sure the BBB is plugged in and booted up (might take up to one minute after you plug it in).
* go to System Preferences->Network, click the + symbol at the bottom left. From the popup window, select "Beaglebone Black"
* now set the "Configure IP v4" field to "Using DHCP with manual address" and set the IP address to 192.168.7.1
!ss_dhcp.png!
* click apply and wait a few seconds, the indicator close to the icon should turn green
* jump to the *Test the ssh connection* section below to check that everything is working properly
h3. Windows users
* you will need a toolkit that allows you to use ssh and some other basic shell tools. The shell scripts in this project have been tested with *mingw* http://mingw.org/ . You will want to note that in order to paste code on the mingw terminal you have to right click on the terminal's title bar and navigate the menu to edit->paste .
* additionally, you need to install the network drivers from http://beagleboard.org/static/Drivers/Windows/BONE_D64.exe (Windows 64 bit) or http://beagleboard.org/static/Drivers/Windows/BONE_DRV.exe (Windows 32bit)
* in the network connections manually set thel IP address for the BBB to 192.168.7.1
!win.png!
* jump to the *Test the ssh connection* section below to check that everything is working properly
h3. Test ssh connection
When using the USB network connection, the BBB has a self-assigned IP of 192.168.7.2, we will log in with username *root* and password *a* .
If you have gone through operating system-specific steps above, you should be able to connect to the beaglebone with
<pre>$ ssh root@192.168.7.2</pre>
According to the settings of your ssh client, you might, or might not, be prompted with something along the lines of
<pre>The authenticity of host '192.168.7.2 (192.168.7.2)' can't be established.
RSA key fingerprint is 35:b2:ff:ae:c2:02:30:af:84:1e:0d:f5:c9:c8:4b:34.
Are you sure you want to continue connecting (yes/no)? </pre>
type @yes@ and press the return key.
Next, you will be prompted with the password.
Enter a single *a* character and hit the return key.
If everything is ok, you will now be displayed the BBB prompt:
<pre>root@arm ~$</pre>
h3. (Optional) ssh keys setup
ssh would require you to enter the password everytime you open a connection to the BBB. This will happen a few times during setup and then 3 times every time you build and run your project. To avoid quickly getting annoyed by this, you can use ssh keys. In the @scripts/@ you will find a setup script which
* generates (if not exists) a key-pair on your host machine (stored in @~/.ssh/@ )
* sets the @~/.ssh/config@ file
* copies the public key to the BBB
To do so, run the @./setup-ssh-windows.sh@ if you are on Windows or @./setup-ssh.sh@ otherwise from the @scripts/@ folder
This way you will be able to log into the BBB simply typing:
<pre>ssh bbb</pre>
h2. Build your first project
Do you want to get started immediately, without need to install any software on your machine? Grab a terminal and learn about [[ Compiling BeagleRT projects on the board]]
Do you want to turn your computer into a cross-compiling machine, with the advantages of an IDE and you are willing to put (some) effort into it? [[ Compiling BeagleRT projects in Eclipse]]