Fully tested central controller code for state machine receiving input from both joystick and higher controller