- 13 Jan 2004
is responsible for matching marker events to a context change. This means if a marker with a certain ID is detected, the StateMachine
has to checked which transition it has to trigger out of the current state.
Example: User is in the kitchen and detects marker with ID 5. Now the StateMachine
receives an event with markerID 5 and now looks into a map showing with ID 5 you will get to the main hall. The transition is triggered and now the StateMachine
must configure itself with the new map.
The configuration of this map is done in a certain way. If a context change occurs, the StateMachine
is shut down (instead of getting reconfigured). A new StateMachine
is started that now carries the wished configuration. This is done while interacting with the MarkerConfiguration
(DWARF: startOnDemand and stopOnNoUse).
If a transition is triggered by the StateMachine
the new context is set in the MarkerConfiguration
. The MarkerConfiguration
now knows that it has to configure the MarkerDetection
again and that the old StateMachine
is of no use anymore. Please look into my thesis for further information (sequence diagrams, etc).
Needs & Abilities
As stated in the StateMachine.xml
file, the service has the following Needs and Abilities.
- Ability: name="Room" type="RoomInfo"
This is needed to have a reference on the MarkerConfiguration
to set the new global context. Please not that we use a special DWARF mechanism here: the *-attributes. This is done to have only the requested StateMachine
to be initialized.
- Need: name="MarkerEvent" type="MarkerID"
It shows the need for marker events. It receives events in order to trigger a context change.
- Need: name="SMConfig" type="Configuration"
Here the StateMachine
pulls its configuartion (the hash-map of the current state) from the Configuration Service. The Configuration has implemented by Marcus Toennis.
Please look at Asa´s paper "Decentralized Coordination of Distributed Interdependent Services" and my thesis available in the dwarfdoc cvs where the *-stuff is explained.
Interaction with other Services
If a context change occurs the new context is set in the MarkerConfiguration
are recieved by the MarkerDetection
Configuration of the current state is done while interaction with the Configuration
Note that the using of the StateMachine
is only useful if you want to set up the whole system (with VideoGrabber
Set up the whole system. Otherwise you have to hardcode the map and test it with the MarkerDetection
and the VideoGrabber
Configuration is done by the Configuration service. If you want to configure it all to a new environment you will first have to model a set of rooms as a state machine. The you have to partition each room with its transitions (accepted markerID´s) and put it in the Configuration database.
- 3 Feb 2004