public List <string> CommandRestart() { var output = new List <string>(); output.Add("Restarting device, all current data will be lost..."); this.State = SecurityCameraState.Online; this.PollTime = 0.5f; this._recording = 0f; return(output); }
private Color ColorForStatus(SecurityCameraState s) { switch (s) { case SecurityCameraState.Offline: return(this.OfflineColor); case SecurityCameraState.Online: return(this.OnlineColor); case SecurityCameraState.Playback: return(this.PlaybackColor); default: return(this.UnknownColor); } }
public List <string> CommandPoweroff() { var output = new List <string>(); switch (this.State) { case SecurityCameraState.Offline: output.Add("Camera is already off"); break; case SecurityCameraState.Online: output.Add("Powering off camera..."); this.State = SecurityCameraState.Offline; output.Add("Powered off"); break; case SecurityCameraState.Playback: output.Add("Cannot power off during playback"); break; } return(output); }