Added statemachine mapping - not done completely yet