Part 3 – building the actual network (software)
First of all, we have to install the software that will be required to communicate with the XBee modules.
Step 1 – installing Oracle's JDK on BeagleBone Black
The software we will be writing requires Java and JavaScript, so the first step is to install Oracle's JDK. Then download the Linux ARM v6/v7 Hard Float ABI Version:
Copy
jdk-7u40-linux-arm-vfp-*.gz
to your BeagleBone Black.Perform
tar xzf jdk-7u40-linux-arm-vfp-*.gz
to extract the JDK.Perform
export PATH=$PATH:/home/root/jdk1.7.0_40/bin
to add the JDK to your path.Perform
export JAVA_HOME=/home/root/jdk1.7.0_40
to set theJAVA_HOME
on your installation.Perform
java -version
to verify your installation.
Step 2 – installing the Java serial port extension package
To install this package, perform the following commands on your terminal:
apt-get install build-essential sudo apt-get install nodejs npm install serialport
Step 3 – enabling serial ports on startup
In the serials.sh
file, use the following...