Implementing applications using hierarchical state machines.

This forum can be used to talk about general design strategies, new ideas and questions in general related to wxWidgets. If you feel your questions doesn't fit anywhere, put it here.
Post Reply
jamesrf
Earned a small fee
Earned a small fee
Posts: 14
Joined: Fri Sep 03, 2004 11:26 am
Location: Oxford, UK
Contact:

Implementing applications using hierarchical state machines.

Post by jamesrf » Wed Sep 29, 2004 11:09 am

Hi guys,

In the last couple of years I got into the practice of implementing custom widgets and views with a finite state machine (FSM) controlling each one. It is definitely the way forward to separate behaviour from drawing (presentation) from management.

The limitation with this approach is twofold. Firstly, finite state machines can be limited and suffer from state and transition explosions. Secondly the FSM is limited to controlling the internals of a single view (in my code).

What I want is to look at ways of controlling an entire application with a single hierarchical state machine (HSM). This addresses both of the problems and in addition forces one to spec the application behaviour much more rigourously.

I'd like to hear from anyone who has any views or experience in this area.

By the way, a reasonable book on the subject is "Constructing the User Interface With Statecharts" by Ian Horrocks, although it hardly touches on implementation issues. If anyone knows any other good books...

Cheers,
James

Jorg
Moderator
Moderator
Posts: 3971
Joined: Fri Aug 27, 2004 9:38 pm
Location: Delft, Netherlands
Contact:

Post by Jorg » Wed Sep 29, 2004 4:33 pm

Hi,

I am very interested in the concept itself, because I see myself using more and more statemachines myself as well in UI design. Do you have more online links about it ?

Regards,
- Jorgen
Forensic Software Engineer
Netherlands Forensic Insitute
http://english.forensischinstituut.nl/
-------------------------------------
Jorg's WasteBucket
http://www.xs4all.nl/~jorgb/wb

jamesrf
Earned a small fee
Earned a small fee
Posts: 14
Joined: Fri Sep 03, 2004 11:26 am
Location: Oxford, UK
Contact:

Post by jamesrf » Wed Sep 29, 2004 5:03 pm

Jorg wrote:Hi,

I am very interested in the concept itself, because I see myself using more and more statemachines myself as well in UI design. Do you have more online links about it ?

Regards,
- Jorgen
Have a look at http://www.smartstatestudio.com/. Download SmartState and have a look at the samples. Other than that I don't have much to go on at the moment. There's also a book by Miro Samek that I'd like a look at but its focused on embedded systems so I'm not sure how useful it would be.

Jorg
Moderator
Moderator
Posts: 3971
Joined: Fri Aug 27, 2004 9:38 pm
Location: Delft, Netherlands
Contact:

Post by Jorg » Wed Sep 29, 2004 6:56 pm

Thanks :-) If it is something we can use I will recommend it on work as well.

- Jorgen
Forensic Software Engineer
Netherlands Forensic Insitute
http://english.forensischinstituut.nl/
-------------------------------------
Jorg's WasteBucket
http://www.xs4all.nl/~jorgb/wb

Post Reply