A finite state machine micro framework