Bryans Finite State Machine