Automatic Bore Pump Controller

Created by: David Taylor, Tristan Stark & Andrew Greiner

This project contains the documentation and source code for an automatic bore pump control system.

The system is built upon ThingsBoard for the UI and control logic and an AdaFruit Feather for controlling the pump via an interface board. Either a WiFi or LoRaWAN Feather can be used.

The best way to start learning about the system is to read the Vision, User Manual, and Developers Guide documents. Together they explain all the functionality and a high level overview of how the system works.

Documentation

The docs directory has all the design and testing documentation:

  • Vision - the initial vision for the project - who it's for, what it does.
  • Requirements Model - the formal requirements of the project.
  • Architecture - the system architecture including a data flow diagram, message formats, and a description of the firmware logic.
  • User Manual - the user manual explaining how to configure the hardware and use the dashboard.
  • Developers Guide - a tour around the system for people wanting to work on it.
  • Test Scripts - a set of scripts that cover all use cases and some functionality that isn't covered by the use cases. Also a test coverage matrix to prove every use case is covered by at least one test. These are not unit tests or automated tests.

UI / business logic

The thingsboard directory contains the json definitions of thingsboard entities. They can be imported into a community edition ThingsBoard server.

  • dashboards - the dashboard and custom widgets definitions.
  • ruleschains - the rules chains that implement the business logic.
  • dataconverters - uplink and downlink data converters for use with LoRaWAN over The ThingsNetwork. These only work with the professional version of ThingsBoard and are not used in the current implementation which runs on the community edition. They are not up-to-date with the released version of the system and are included as a head start in case the system gets ported to the professional edition.

Firmware

The firmware directory contains the Feather firmware in the form of an Arduino sketch, and some shell scripts for faking various messages via The ThingsNetwork.

See the User Manual and Developers Guide for information on how to configure the firmware for your devices.

Simulator

The simulator directory contains the source for a simulator that can be used to test the dashboard via MQTT. The simulator can send messages as if it were an Ellenex PLD2-L sensor, and also simulates the WiFi Feather running the firmware. This allows all aspects of the dashboard to be tested with no tank level sensor or Feather hardware.