System Architecture - UBCSailbot/raye-network-table GitHub Wiki
Here is a diagram of all the software/systems for the boat, and how it's connected:
- The Intel NUC is a relatively powerful computer which runs pathfinding and simulation code.
Communication between software here is done via ROS. It is located on the boat.
Software which runs in the Intel NUC:- Local Pathfinding generates a heading given AIS data (data about other boats in the area), a list of GPS waypoints to follow (generated by global-pathfinding, and the boats current GPS position)
- Simulator takes in the heading from local pathfinding, as well as sensor data, and generates motor outputs to control the boat. Specifically, it generates a rudder angle and a winch angle.
- nuc_eth_listener handles communication with the BBB.
- The BBB (BeagleBone Black) is a relatively weaker computer. It is connected directly to many other hardware components
on the boat. It does not do any complex calculations, but is responsible for gathering information. It is located on the boat.
Communication between software here is done via 0mq.
Software which runs on the BBB:
- network_table_server acts as a database and central communication hub for all the data relevant to controlling the boat. Sensor data, AIS data, waypoints from global pathfinding are all stored inside the network table.
- bbb_eth_listener handles communication with the nuc
- bbb_canbus_listener handles communication with the CANbus sensor network
- bbb_ais_listener handles communication with AIS
- bbb_rockblock_listener handles communication with the rockblock satellite modem, and hence with the satellite connection
- CANbus Network connects all the sensors and motors to the BBB. It is located on the boat.
- Land Server is responsible for displaying diagnostic/sensor data from the boat on a webpage,
as well as running global pathfinding code and sending the generated waypoints to the boat
via satellite connection. The land server can be located anywhere,
but is not physically part of the boat. Software which runs on the Shore Server:
- land_satellite_listener listens for data coming from the boat over satellite, and also sends data to the boat via satellite.
- network_table contains a copy of the same data as the network table in the boat.
- global pathfinding produces GPS waypoints which are eventually sent to the boat.
- A database stores data from the network table in order to keep a record of historical data
- A web front end displays the contents of the database. Note that in the future, it may be possible to send commands to the boat from the front end website (in the case of an emergency). However this has not been implemented or planned yet.
The BBB also has an LTE connection and is a Wifi hotspot. This makes it easier to SSH into the BBB for debugging. The BBB, Intel NUC, and Land Server are all connected to a common VPN (using tinc). Therefore, as long as the Intel NUC or BBB have some sort of internet connection (for example, via LTE), it is possible to SSH into the server (which has a static public IP address), and from there SSH into the BBB or Intel NUC.
The Land Server also runs a Jenkins server, an automated build system. This is not relevant to the boat when it is on its final journey; however the automated build system will run tests on the real hardware during development. The Jenkins server connects to the BBB and Intel NUC using the VPN.
Here is the flow of data. The final goal is the get the winch/rudder outputs
into the CANbus. From there it's handled by the electrical team.