uleroboticsgroup / yasmin

YASMIN (Yet Another State MachINe)
GNU General Public License v3.0
130 stars 25 forks source link

Practical example #3

Closed fzoric8 closed 1 year ago

fzoric8 commented 2 years ago

Hi,

I'm checking yasmin as simple state manager for ROS2 purposes. Besides simple_demo.py there's no clear example on how to use it.

I'm wondering if it would be possible to implement following in State class.

I've figured out demo script, however, I'm not sure how to properly use current State implementation.

I can initialize ROS node with certain publishers/subscribers. However, if i pass certain values I want to monitor during state execution (robot pose), they remain unchanged during state execution. Execute function is used, however, state runs alongside ROS node and it's not possible to continuously update robot pose value in State class.

You can see modified demo here.

My question is following:

Thank you for your answer.

fzoric8 commented 1 year ago

Inactive repo, don't use it.

mgonzs13 commented 1 year ago

Hi @fzoric8, sorry for the delay. I've just created a MonitorState for Python and C++. Here you can see an example of how to use this new state to monitor the odom topic.