Boost MSM: No transition from submachine to external state
Using the following example as a template: http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/examples/CompositeTut... http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/examples/CompositeTut... I am trying to create a state machine that consists of an alarm state and a composite state (submachine). When an alarm event is posted while in the composite state, the state machine is supposed to transition to the Alarm state; however, the machine complains that no transition from the composite state on the alarm event exists. This is similar to the example where the player is in playing and a stop event is received. Below is a dumbed-down version of my state machine: http://boost.2283326.n4.nabble.com/file/n4300991/StateMachine.gif Here is the implementation: Here is the output: See anything that could be causing my problem? -- View this message in context: http://boost.2283326.n4.nabble.com/Boost-MSM-No-transition-from-submachine-t... Sent from the Boost - Users mailing list archive at Nabble.com.
----- Original Message -----
From: stetkas
Newsgroups: gmane.comp.lib.boost.user
To: boost-users@lists.boost.org
Sent: Monday, January 16, 2012 7:37 PM
Subject: Boost MSM: No transition from submachine to externalstate
Using the following example as a template:
http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/examples/CompositeTut...
I am trying to create a state machine that consists of an alarm state and a composite state (submachine). When an alarm event is posted while in the composite state, the state machine is supposed to transition to the Alarm state; however, the machine complains that no transition from the composite state on the alarm event exists. This is similar to the example where the player is in playing and a stop event is received.
Below is a dumbed-down version of my state machine:
Here is the implementation:
// File: StateMachine.cpp
#include <iostream>
// back-end
#include
----- Original Message -----
From: stetkas
Newsgroups: gmane.comp.lib.boost.user
To: boost-users@lists.boost.org
Sent: Monday, January 16, 2012 7:37 PM
Subject: Boost MSM: No transition from submachine to externalstate
Using the following example as a template:
http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/examples/CompositeTut...
I am trying to create a state machine that consists of an alarm state and a composite state (submachine). When an alarm event is posted while in the composite state, the state machine is supposed to transition to the Alarm state; however, the machine complains that no transition from the composite state on the alarm event exists. This is similar to the example where the player is in playing and a stop event is received.
Below is a dumbed-down version of my state machine:
Hi again,
ah I remember now. I changed the example last june because of a problem with exit points.
If you write:
typedef boost::msm::back::state_machine
Thanks Christophe. I will make the change to see it work; but based on your comments, I'll probably switch to one of the other front-ends. Thanks, Steve -- View this message in context: http://boost.2283326.n4.nabble.com/Boost-MSM-No-transition-from-submachine-t... Sent from the Boost - Users mailing list archive at Nabble.com.
Thanks Christophe. I will make the change to see it work; but based on your comments, I'll probably switch to one of the other front-ends.
Thanks,
Steve
What I mean is that eUML is not used as long as other front-ends and therefore less tested. But there has been so far no bug I haven't been able to fix within a few days. In the case you reported, I have a fix which seems to be working (and reduces the syntax needed), I just need to play with it a bit more before committing it. Christophe
Oh I know; but I just cannot put something listed as experimental in production code that's all. Thanks for your help! Steve -- View this message in context: http://boost.2283326.n4.nabble.com/Boost-MSM-No-transition-from-submachine-t... Sent from the Boost - Users mailing list archive at Nabble.com.
Thanks Christophe. I will make the change to see it work; but based on your comments, I'll probably switch to one of the other front-ends.
Thanks,
Steve
What I mean is that eUML is not used as long as other front-ends and therefore less tested. But there has been so far no bug I haven't been able to fix within a few days. In the case you reported, I have a fix which seems to be working (and reduces the syntax needed), I just need to play with it a bit more before committing it.
Hi,
as promised, I fixed this problem (trunk rev. 76655). It even requires less
typing. You define a submachine with front-end like always and use it in
another state machine. In your case, you'd have:
typedef boost::msm::back::state_machine
participants (2)
-
Christophe Henry
-
stetkas