About: Implementation overview
µPCN is built upon a set of parallel tasks either mapped to tasks of the real-time operating system FreeRTOS or to POSIX threads. In order to get an overview of the implementation, a very brief overview of the µPCN task structures is provided. The following figure shows the core tasks used within the implementation.
In summary, the following steps are taken by the implementation in the case of receiving a bundle:
- The bundle is parsed by the Input Task which encapsulates a set of parsers for the bundle protocol, configuration information and IPND beacons.
- The bundle is handed over to the Router Task. In a first step, a simple lookup to a hashtable is done to identify ground stations offering contacts with the destination node. This initial routing decision is potentially improved by a background task (Router Optimizer Task) taking bundle priorities into account.
Technically spoken, routing a bundle via a ground station means to add the bundle to a contact data structure associated with the ground station.
- The Contact Manager Task is woken up as soon as a contact with a ground station encounters. It checks the bundles associated with this contact and hands over the bundles to a task associated to the specific ground station (Ground Station Task).
- The Ground Station Task serializes the bundle and transfers it to the communication system taking care for the link layer communication to the physical ground stations.
Besides the Bundle Protocol implementation, µPCN offers an implmentation of the IPND protocol with extensions to reduce the risk of Denial-of-Service (DoS) attacks. The core part of the neighbor discovery mechanism used to dynamically add ground stations to the router data structures is provided within the Contact Manager Task.