Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Problem changing the system modes when there are rules

未关闭
#94 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
25/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
停滞
技术栈
cpp
领域
robotics

调研方向

首先查看 issue 中描述的系统模式规则和自顶向下重新配置行为。确定在 guard 规则仍然生效时,命令是否可以将系统从 COMPROMISED 转为 DEFAULT;当受支持的行为或其限制已记录在案并由适当的测试覆盖时,即视为完成。

由索引模型根据 Issue 内容生成。

描述

Hi all

I am trying to use system modes for a system composed of these nodes: {nav2, manipulator, camera, guard}. guard is a special node that detects if the system has been compromised. In this case, all the nodes should be in mode COMPROMISED and camera in the inactive state. The specification is:

# system modes safety benchmark
---

safety:
  ros__parameters:
    type: system
    parts:
      manipulator
      nav2
      camera
      guard
    modes:
      __DEFAULT__:
        manipulator: active.__DEFAULT__
        nav2: active.__DEFAULT__
        camera: active.__DEFAULT__
        guard: active.__DEFAULT__
      COMPROMISED:
        manipulator: active.COMPROMISED
        nav2: active.COMPROMISED
        camera: inactive.COMPROMISED
        guard: active.COMPROMISED
    rules:
      guard_detect_compomise_in_default:
        if_target: active.__DEFAULT__
        if_part: [guard, active.COMPROMISED]
        new_target: active.COMPROMISED
      guard_detect_default_in_compromise:
        if_target: active.COMPROMISED
        if_part: [guard, active.__DEFAULT__]
        new_target: active.__DEFAULT__

manipulator:
  ros__parameters:
    type: node
    modes:
      __DEFAULT__:
        ros__parameters:
          max_torque: 0.5
      COMPROMISED:
        ros__parameters:
          max_torque: 0.1

nav2:
  ros__parameters:
    type: node
    modes:
      __DEFAULT__:
        ros__parameters:
          forbidden_areas: false
      COMPROMISED:
        ros__parameters:
          forbidden_areas: true

guard:
  ros__parameters:
    type: node
    modes:
      __DEFAULT__:
        ros__parameters:
          compromised_system: false
      COMPROMISED:
        ros__parameters:
          compromised_system: true

camera:
  ros__parameters:
    type: node
    modes:
      __DEFAULT__:
        ros__parameters:
          use_sim_time: false
      COMPROMISED:
        ros__parameters:
          use_sim_time: false

If I change the mode of guard, all the system reacts as I want. BUT if I want to command all the system to go from COMPROMISED to __DEFAULT__ I can't do it because guard is COMPROMISED, and that doesn't let the system reconfigure to __DEFAULT__.

Is there any way to combine the bottom-up rules with the possibility of changing the system mode (an up-bottom reconfiguration)?

Thanks!!

主要语言
C++
星标
45
派生
13
PR 合并指标
30 天内没有已合并 PR

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

micro-ROS/system_modes 的其他 Issue

查看 micro-ROS/system_modes 的全部 Issue

相似的 Issue

更多 C++ Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。