====== Differences ====== This shows you the differences between two versions of the page.

Link to this comparison view

content:meshextender:me2.0_quality_assurance [17/03/2017 12:36]
Paul Gardner-Stephen created
content:meshextender:me2.0_quality_assurance [03/10/2019 15:42] (current)
Thomas Wade [Mesh Observer] Add image
Line 1: Line 1:
 === Quality Assurance & Related Matters === === Quality Assurance & Related Matters ===
  
 +===== Provisioning Procedure =====
 +Complete the following sections in order to build and flash both the Serval U-Boot and OpenWRT forks to the mesh extender. This section assumes you are running Ubuntu 16.04.
 +
 +==== Building the OpenWRT-based Firmware ====
 +=== Prerequisites ===
 +The following tools are required to build the firmware:
 +  * G++
 +  * GCC
 +  * Git
 +  * ncurses
 +  * OpenSSL libraries (use 'libssl1.0-dev', newer versions are unsupported)
 +  * zlib
 +  * Make
 +  * Python 2.x
 +  * Subversion
 +  * Unzip
 +
 +These can be installed in one fell swoop with apt: <code>sudo apt install csh g++ gawk gcc git libncurses-dev libssl1.0-dev libz-dev make python subversion unzip</code>
 +
 +=== Build process ===
 +  - Clone the Serval Project fork of OpenWRT (https://github.com/servalproject/openwrt/tree/MeshExtender2.0)
 +  - Checkout the 'MeshExtender2.0' branch
 +  - Run the './update' script to collect and compile the firmware
 +
 +**NOTES**
 +  * An internet connection is required throughout the build process, as some parts may download additional repositories.
 +  * You may get persistent errors about missing 'git' despite having it installed. A dirty fix to get past that is to edit 'include/prereq-build.mk' and comment out lines 147-148.
 +  * If you have Perl 5.26+, you will encounter an issue while compiling Automake due to a change in how Perl handles regular expressions (discovered here: [[https://github.com/raspberrypi/noobs/issues/470#issuecomment-376256295]]). To get around it, open 'build_dir/host/automake-1.15/bin/automake.in', go to line 3883, and replace <code>$text =~ s/\${</code> with <code>$text =~ s/\$\{</code>
 +  * Make sure you are using `libssl1.0-dev` and not a newer version, as the 'tools/mkimage' make target requires an old version
 +
 +==== Building U-Boot ====
 +=== Prerequisites ===
 +U-Boot relies on both the prerequisite packages and toolchain installed when compiling the OpenWRT-based firmware.
 +The following additional tools are required to build U-Boot:
 +  * Java JRE
 +
 +These can be installed with apt: <code>sudo apt install default-jre</code>
 +
 +=== Build process ===
 +  - Clone the Serval U-Boot fork (https://github.com/servalproject/u-boot_mod)
 +  - Checkout the 'MeshExtender2.0' branch
 +  - Enter the 'u-boot-domino-2015' directory
 +  - Open 'Makefile' in a text editor and replace line 4 with <code>export TOOLPATH=<toolchain_path></code> where '<toolchain_path>' is the absolute path to the toolchain provided in the Serval OpenWRT repository ('staging_dir/toolchain-mips_34kc_gcc-4.8-linaro_uClibc-0.9.33.2/' at the time of writing)
 +  - Compile U-Boot with 'make'
 +  - Copy the U-Boot binary from 'bin/uboot_for_domino.bin' to '/srv/tftp/'
 +
 +**NOTES**
 +  * If the build process fails on 'fsdata.c' with an error like: <code>fsdata.c:333:1: error: expected expression before ',' token</code> Open 'u-boot/httpd/fsdata.c' with a text editor, scroll to the line in question (line 333 in this case), and remove the comma before '0 };'.
 +
 +==== Flashing the Firmware ====
 +  - Clone the Serval OpenWRT packages repository (https://github.com/servalproject/openwrt-packages)
 +  - Enter the 'auto-flash' directory
 +  - Compile the auto-flash utility with 'make'
 +  - Setup a TFTP server to serve files from '/srv/tftp' by following the procedure at https://askubuntu.com/questions/201505/how-do-i-install-and-run-a-tftp-server
 +  - From the Serval OpenWRT directory, run the './update' script to compile the latest Serval-DNA, LBARD and related binaries, and have them automatically copied into '/srv/tftp'
 +  - Configure an Ethernet port on your computer to have the manually allocated IP address 192.168.1.2, and a netmask of 192.168.1.2
 +  - Connect a Mesh Extender Programming Cable to your computer. This will cause a USB serial port to appear, possibly '/dev/ttyUSB0' if you have no others connected
 +  - From the 'auto-flash' directory, run './auto-flash <serial_device>', where '<serial_device>' is the device you found in the previous step
 +
 +You can now connect a Mesh Extender via Ethernet to your computer, and then connect the programming cable to the Mesh Extender. This should automatically flash the Mesh Extender with the new firmware and U-Boot if required.  The process takes about 3 minutes. 
 +You can program as many Mesh Extenders as you wish in this way by simply moving first the Ethernet and second the Mesh Extender programming cable to the next Mesh Extender to be flashed. 
 +If you modify alert.a3u and have VLC installed, it will play the audio or video file you specify in the .m3u file when the process is complete, so that you don't have to watch the screen intently the whole time.
 +
 +===== Mesh Extender Programming Cable =====
 +
 +To provision or debug Mesh Extenders, it is helpful to have a Mesh Extender programming cable. This consists simply of a setup that provides the 5V DC power required for the core functions of the Mesh Extender, as well as routing the serial console to an FTDI or similar serial adapter.
 +
 +The cable requires only four connections:
 +
 +  * FTDI red (Vcc) - DB25 female pin 22 (5V in)
 +  * FTDI black (GND) - DB25 female pin 1 (GND)
 +  * FTDI orange (TXD) - DB25 female pin 19 (Mesh Extender serial console RX)
 +  * FTDI yellow (RXD) - DB25 female pin 5 (Mesh Extender serial console TX)
 +
 +Here is an example cable built using a DB25 break-out board:
 +
 +{{:content:meshextender:meshextenderprogrammingcable2.jpg?300|}} {{:content:meshextender:meshextenderprogrammingcable1.jpg?300|}}
 +
 +There is also a variant which directly connects a USB-to-UART adaptor to a DB25 parallel cable:
 +
 +{{:content:meshextender:newprogrammingcable.jpg?300|}} {{:content:meshextender:newprogrammingcablecloseup.jpg?300|}}
 ===== Mesh Extender PCB Test & Programming Rig ===== ===== Mesh Extender PCB Test & Programming Rig =====
  
-To be designed and implemented with Theo.  Test rig that will allow flash programming and testing of all functions of the PCB.+A test rig that will allow flash programming and testing of all functions of the PCB is under development with Ryan, an honours student as of 2018It is intended to test the following functions:
  
   * Super-cap safe shutdown   * Super-cap safe shutdown
Line 26: Line 107:
   * ...   * ...
  
 +===== Mesh Observer =====
  
-===== Power/Radio Cable Test & Programming Rig =====+{{ :content:meshobserver:observersetuphighlighted.jpg?300|}}
  
-To be designed and implemented with Ryan.  Largely based on our flash-rfd900 utility to probe and program cablecombined with functional indication through a set of LEDs.+The [[content:meshobserver:main_page|Mesh Observer]] is a monitoring device that attaches to a Mesh Extender and sniffs Wi-Fi and UHF packetsforwarding them to another machine for analysis. It is useful for mapping out traffic through a Serval mesh network and diagnosing issues with [[content:tech:rhizome_bundle|bundle]] movements. 
 + 
 +As of Late 2019, 13 Mesh Extender + Observer kits are being deployed as a test network to diagnose outstanding issues.
  
 ===== Informal IP/Environmental Testing of Enclosures ===== ===== Informal IP/Environmental Testing of Enclosures =====
Line 47: Line 131:
   * No condensation or dust ingress at conclusion of testing.   * No condensation or dust ingress at conclusion of testing.
   * ... ?   * ... ?
-==== Certifications ====+ 
 +===== Certifications =====
  
 The ME2.0 has not yet been subjected to any certifications.  We intend to pursue Australian/New Zealand, EU and US certifications of the electronics, and IP65 or IP66 certification of the hardware. The ME2.0 has not yet been subjected to any certifications.  We intend to pursue Australian/New Zealand, EU and US certifications of the electronics, and IP65 or IP66 certification of the hardware.

Login