works with Einars fsm