1. References


2. jFed and Fed4FIRE+ account

Register for a jfed account at the following URL. You can use your student account at your institute, or alternatively request to join the "pervasivenation" project when registering


3. Download jFed Framework

Download jFed client software to run the RSPEC file in the next section


4. Rspec for Seeeduino LoRAWAN Board at Iris - Support for Pervasive Nation

Load the following rspec, with connected Seeeduino LoRaWAN Board  with  ubuntu 20.04 image.

<?xml version='1.0'?>
<rspec xmlns="http://www.geni.net/resources/rspec/3" type="request" generated_by="jFed RSpec Editor" generated="2021-02-18T19:38:43.096Z" xmlns:emulab="http://www.protogeni.net/resources/rspec/ext/emulab/1" xmlns:delay="http://www.protogeni.net/resources/rspec/ext/delay/1" xmlns:jfed-command="http://jfed.iminds.be/rspec/ext/jfed-command/1" xmlns:client="http://www.protogeni.net/resources/rspec/ext/client/1" xmlns:jfed-ssh-keys="http://jfed.iminds.be/rspec/ext/jfed-ssh-keys/1" xmlns:jfed="http://jfed.iminds.be/rspec/ext/jfed/1" xmlns:sharedvlan="http://www.protogeni.net/resources/rspec/ext/shared-vlan/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.geni.net/resources/rspec/3 http://www.geni.net/resources/rspec/3/request.xsd ">
  <node client_id="Seeeduino_node" exclusive="false" component_manager_id="urn:publicid:IDN+iris-open-testbed.connectcentre.ie+authority+am">
    <sliver_type name="vm">
      <disk_image name="urn:publicid:IDN+iris-open-testbed.connectcentre.ie+image+seeeduino-board"/>
      <flavor_type xmlns="http://iris-testbed.connectcentre.ie/rspec/ext/openstack/1" name="seeeduino-iot"/>
    <location xmlns="http://jfed.iminds.be/rspec/ext/jfed/1" x="353.0" y="208.0"/>

 5. Jfed

Make sure that Seeeduino board is connected to the VM at Iris, by running the following command. dmesg | grep Seeed - and if the board is there you should see the following information. 

iristest@seeeduino-node:~$ dmesg | grep Seeed
[    3.171580] usb 1-1.5: Product: Seeeduino LoRaWAN
[    3.174509] usb 1-1.5: Manufacturer: Seeed Studio


6. Download the PN TheThingsNetwork GitHub code 

Clone the pervasive nation Seeeduino code or copy the contents of the file: https://github.com/pervasivenation/pn_seeed/blob/master/pn_seeed.ino

git clone https://github.com/pervasivenation/pn_seeed.git

 Start arduino if not already started


Open the pn_seeed.ino file 

Compile the file - using the "Verify" button


Use the "Upload" button to push the code to the board. 


Note, you can see debug information from the Serial Monitor


7. Install the Seeduino board

Open your Arudino IDE, click on File > Preferences, and copy below url to Additional Boards Manager URLs:


8. Install a board manager

Click on Toos > Board > Board Manager.

Now you can search the board by name "Seeduino" and install Seed SAMD Boards


9. Set a board

After Step 3 was successful, a board named SeeeduinoLoraWan will show up at the boards list. Select it.

Click on Tools > BoardSeeeduinoLoraWan is available now.


Troubleshooting / Debugging

a. Install Arduino IDE [Note these steps should already have been run on the base Seeeduino image

- Skip to Step 8]

Open up a terminal window and use the snap command to install Arduino IDE on your Ubuntu 20.04 server. To do so execute the command below:

sudo apt-get update
sudo apt-get dist-upgrade
##to support remote viewing over ssh install xorg on remote server
sudo apt-get install xorg 
sudo apt-get install -y xorg-dev

You now need to download the Arduino IDE from https://www.arduino.cc/en/software

You need to download this library locally, and scp it to the VM using jFed scp tool.

When available on the VM run the following commands:

tar -xf arduino-1.8.13-linux64.tar.xz
cd arduino-1.8.13
sudo ./install.sh 
Adding desktop shortcut and menu item for Arduino IDE...


Next, You can start the Arduino IDE from the Linux command line be executing:


The Arduino GUI should be visible. You will need X11 client locally to support viewing.

b. Setup Arudino IDE to support Seeeduino Board 

[Note these steps should already have been run on the base Seeeduino image - Skip to Step 8]

Open your Arudino IDE, click on File > Preferences, and copy below url to Additional Boards Manager URLs: [More info here: https://wiki.seeedstudio.com/Seeed_Arduino_Boards/]