Added the base implementation of an asynchronous state machine