arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2606.09203cs.RO
收藏

通过Lingua Franca实现ROS 2应用的确定性执行

Deterministic Execution of ROS 2 Applications via Lingua Franca

TU Dortmund University(多特蒙德工业大学);University of California, Berkeley(加州大学伯克利分校);RWTH Aachen University(亚琛工业大学)

Harun Teper, Shaokai Lin, Shulu Li, Edward A. Lee, Jian-Jia Chen

AI总结:

提出框架将未修改的ROS 2应用转换为Lingua Franca程序,利用逻辑时间实现确定性执行,解决ROS 2中回调执行顺序和消息交织的非确定性问题。

摘要:

机器人操作系统2(ROS 2)是一种广泛用于机器人系统的中间件,其特点是发布-订阅(pub-sub)通信机制,计算结构为由ROS 2执行器调度的回调。尽管很流行,但ROS 2中的pub-sub模式本质上是不确定的:即使在单个执行器内,这些回调的运行顺序也是不确定的,分布式部署由于节点间消息的交织和网络延迟进一步增加了不确定性。这种不确定性常常导致并发问题,使得几乎不可能分析安全性并提供保证。我们提出了一个框架,能够将未修改的ROS 2应用程序转换并在Lingua Franca(LF)下运行,LF是一种使用逻辑时间进行确定性执行的协调语言,使得相同的输入总是产生相同的确定性执行顺序。我们首先描述了哪些ROS 2特性可以在逻辑时间下确定性执行。这些特性使得建立自动转换框架成为可能,该框架从ROS 2应用程序中提取信息并直接将其转换为LF程序。然后可以应用LF的丰富特性,如逻辑时间延迟、跨进程的联邦执行和故障处理,使ROS 2应用程序以确定性和时序可预测的方式执行,而无需更改ROS 2代码。我们在一个合成示例和Autoware参考系统上评估了该框架。我们表明,在默认ROS 2中,回调的执行顺序不同,同时端到端延迟在不同执行中也有所变化。相比之下,我们由LF控制的ROS 2系统产生了确定的执行顺序和一致的端到端延迟。

英文摘要:

The Robot Operating System 2 (ROS 2) is a widely used middleware for robotic systems, characterized by a publish-subscribe (pub-sub) communication mechanism in which computation is structured as callbacks dispatched by ROS 2 executors. Despite its popularity, the pub-sub pattern in ROS 2 is inherently nondeterministic: the order in which these callbacks run is nondeterministic even within a single executor, and distributed deployments add further nondeterminism from the interleaving of messages across nodes and from network latency. Such nondeterminism often leads to concurrency issues and makes it virtually impossible to analyze for safeness and provide guarantees. We present a framework that is able to convert an unmodified ROS 2 application and run it under Lingua Franca (LF), a coordination language for deterministic execution using logical time, so that the same input always produces the same deterministic execution order. We first describe which ROS 2 features can be executed deterministically under logical time. Such features enable the possibility to establish an automatic conversion framework to extract information from a ROS 2 application and directly convert it into an LF program. The rich features of LF, such as logical-time delays, federated execution across processes, and fault handling, can then be applied to make the ROS 2 application be executed in a deterministic and timing-predictable manner without changing the ROS 2 code. We evaluate the framework on a synthetic example and on the Autoware reference system. We show that the order in which callbacks are executed differs in default ROS 2, while also having end-to-end latencies that vary across executions. In contrast, our LF-controlled ROS 2 system produces a deterministic execution order and consistent end-to-end latencies.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑