simple fsm lock example.