Skip to content

Commit da5cbb8

Browse files
Update _docs/tutorials/core/programming_rcl_rclc/index.md
Co-authored-by: Ralph Lange <ralph-lange@users.noreply.github.com>
1 parent 7c1f47f commit da5cbb8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • _docs/tutorials/core/programming_rcl_rclc

_docs/tutorials/core/programming_rcl_rclc/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ typedef struct
510510
rcl_subscription_t * sub2;
511511
} sub_trigger_object_t;
512512
```
513-
The executor for the publishers, shall publish when any of corresponding timers for the publishers is ready. That is the or-logic. You could also use the predefined `rclc_executor_trigger_any` trigger condition, but this example shows, how you can write your own trigger conditions.
513+
The executor for the publishers shall publish when any of corresponding timers for the publishers is ready. That is the or-logic. You could also use the predefined `rclc_executor_trigger_any` trigger condition, but this example shows how you can write your own trigger conditions.
514514

515515
In principle the condition gets a list of handles, the length of this list, and the pre-defined condition type, in this case we expect `pub_trigger_object_t`. First, the parameter `obj` is cased to this type (`comm_obj`). Then, each element of the handle list is checked for new data (or a timer is ready) by evaluating the field `handles[i].data_available` and its handle pointer is compared to the pointer of the communicatoin object. If at least one timer is ready, then the trigger condition returns true.
516516
```C

0 commit comments

Comments
 (0)