update state machine
update state machine