-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prepare features before integration week #26
Conversation
Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> Signed-off-by: Christian Henkel <christian.henkel2@de.bosch.com>
Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com>
Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com>
…hreads Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com>
Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com>
Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This example involves real values, that are currently not supported by STORM.
Use modest for testing this, as in the following:
scxml_to_jani main.xml
modest modes main.jani -R Uniform -T -TF file.csv
-R Uniform
is used to resolve non-determinism in the resulting state machine, and is required.
-T -TF file.csv
is used to generate a file collecting all the generated traces (in case debugging is required), and can be omitted.
Workarounds to make smc_storm able to deal with this kind of model will be implemented.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the amazing work @MarcoLm993. I did not find any blockers. Just some things we can discuss in our next Wednesday hackathon.
from scxml_converter.scxml_entries.utils import SCXML_DATA_STR_TO_TYPE | ||
|
||
|
||
class RosCommunicationHandler: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💓
# Additional self-loop in the waiting state, allowing the global timer to tick | ||
# only if all events have been processed | ||
event_automaton.add_edge(JaniEdge({ | ||
"location": "waiting", | ||
"destinations": [{ | ||
"location": "waiting", | ||
"probability": {"exp": 1.0}, | ||
"assignments": [] | ||
}], | ||
"action": "global_timer_enable" | ||
})) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is used to ensure we do not have any unprocessed event (that means, there are no event-automata in the "received" state) before advancing the global timer / processing the timer callbacks. In a way, we can say it gives priority to events over timers
@@ -33,31 +33,39 @@ | |||
|
|||
|
|||
def convert_scxml_root_to_jani_automaton( | |||
scxml_root: ScxmlRoot, jani_automaton: JaniAutomaton, events_holder: EventsHolder | |||
scxml_root: ScxmlRoot, jani_automaton: JaniAutomaton, events_holder: EventsHolder, | |||
max_array_size: int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if this should be defined globally. We should think about making this per array
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we need a mix of both: ROS interfaces might contain unbounded arrays, and there we would definitely need to enforce a bound ourselves (e.g. in the Fibonacci example)
@ste93 The reason for adding you to the PR was mostly to make you aware of the ROS-SCXML format updates in the various examples. Sorry for not mentioning it explicitly earlier. |
* Add support to BT Input Ports Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> Signed-off-by: Christian Henkel <christian.henkel2@de.bosch.com> * Implement scxml action interface. No conversion to Jani yet Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> * Add array support in scxml and jani Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> * Complete action implementation with fibonacci test with one and two threads Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> * Update basic ROS example Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> * Introduce robot controller example, fixing issues with real numbers Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> --------- Signed-off-by: Marco Lampacrescia <marco.lampacrescia@de.bosch.com> Signed-off-by: Christian Henkel <christian.henkel2@de.bosch.com>
Features in this PR:
To be implemented in a next PR: