Skip to content

Commit c8e3207

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

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
@@ -375,7 +375,7 @@ if (rc != RCL_RET_OK) {
375375
```
376376
The option `ON_NEW_DATA` selects the execution semantics of the spin-method. In this example, the callback of the subscription `my_sub`is only called if new data is available.
377377

378-
Note: Another execution semantics is `ALWAYS`, which means, that the subscription callback is always executed when the spin-method of the executor is called. This option might be useful in cases in which the callback shall be executed at a fixed rate irrespective of new data is available or not. If you choose this option, then the callback will be executed with message argument `NULL`, if no new data is available. Therefore you need to make sure, that your callback can also accept `NULL` as message argument.
378+
Note: Another execution semantics is `ALWAYS`, which means, that the subscription callback is always executed when the spin-method of the executor is called. This option might be useful in cases in which the callback shall be executed at a fixed rate irrespective of new data is available or not. If you choose this option, then the callback will be executed with message argument `NULL` if no new data is available. Therefore you need to make sure, that your callback also accepts `NULL` as message argument.
379379

380380

381381
Likewise, you can add the timer `my_timer` with the function `rclc_c_executor_add_timer`:

0 commit comments

Comments
 (0)