Added mode controls and appropriate switching between them, though other modes aren't implemented