This is NOT a summary of today’s call (Kalyan may post one later) but an illustration to go with what I said.
Say, we have an airspeed sensor. Per v1 design, its messages have no fixed port-ID, so when a new sensor is connected to the network, it just sits there silent until configured. Suppose that ArduPilot defines a table that goes like this:
Function | Subject-ID |
---|---|
Airspeed sensor #0 pressure | 1000 |
Airspeed sensor #0 temperature | 1001 |
Airspeed sensor #1 pressure | 1002 |
Airspeed sensor #1 temperature | 1003 |
… | … |
(whether pressure and temperature have to be separated is irrelevant at this moment, either approach is fine)
This table does not necessarily have to be part of the standard. For instance, PX4 may manage without any predefined ranges at all (which it probably will considering @PetervdPerk’s work on DS-015 so far). ArduPilot may be able to implement a trivial mapping between port-IDs from the table and its internal device-ID via bitfield manipulations.
So in order to connect a new sensor, we have to configure the subject-IDs appropriately. Suppose that initially, in the early days of UDRAL, we expect the human to do that manually. The user experience is terrible and the potential for misconfiguration is huge. However:
- Automation for non-critical setups will arrive later (see my PoC).
- High-integrity setups are expected to prefer manual configuration.
- The effects of misconfiguration are contained at the initial commissioning stage and under reasonable assumptions cannot manifest in-flight. Hence, the overall operational safety of the vehicle is not affected.
When ArduPilot receives a message from subject 1002, it handles it exactly the same way as if it received a v0 message like 1027.RawAirData
with a sensor-ID field in it (well, the one we use in this example doesn’t have a sensor-ID, but suppose that it does). The node-ID is irrelevant and is not expected to be used in this design except for RPC calls (a detailed explanation of why reliance on node-IDs at the application layer is evil is given in the Interface Design Guidelines; tldr: anonymous DCPS abstracts the origin/destination away, reaching to the node-ID constitutes a leaky abstraction). The remote register lookup that Andrew mentioned does not occur at any point (it was never part of the design).
If a node contains several sensors, then it will publish on multiple subjects concurrently. The integrator will have the option to manage bandwidth utilization by selectively enabling only those subjects that are of relevance for the system at hand.
ArduPilot’s own log analysis software will know how to interpret sensor messages correctly since it will use the aforementioned table as a reference. Other systems (e.g. PX4) may approach this entirely differently, I don’t suppose we need to discuss this at this moment but we can do it later if there is interest.
I see how this can be perceived as a somewhat unconventional way of attaining the same goals as v0 did. The critical advantage offered by this architecture is its ability to accommodate new functionality without the need to change data type definitions and introduce modifications into existing components (which is of paramount importance for high-integrity deployments). Recall the two examples I introduced at the call: a gimbal with geotagging and a servo with its position feedback loop closed through the network. As I attempted to illustrate during the call, the v0-style approach does not allow one to address these use cases sensibly, forcing one to either introduce highly specialized ad-hoc data types (which is disastrous for the ecosystem in the long term) or to force high logical coupling between independent components of the system. Note that I don’t want us to spend too much time assessing practical usage scenarios where v0 falls short thinking how to improve it, because we will end up overfitting our solution only for those scenarios we can come up with. Instead, the preferred strategy is to rely on the well-known principles of SOA, where the same problems have been addressed long before us.
Vendors of compliant hardware are critically interested in the adoption of this enhanced, more abstract architecture, because it allows them to significantly expand the target market from only UAV to adjacent domains such as certain robotic systems. Anticipating objections, I don’t think relying on their direct input here would be wise, as the example of the old DS-015 thread we all remember indicated that many of the participants simply failed to grasp the topic of the conversation.
I am not sure yet what the next steps should be. I feel like we were making some progress at the call towards convergence. I think we should repeat that exercise again but @coder_kalyan, @tridge, and @dagar should post their notes/observations/feedback first.