public ServerController()
 {
     CameraHeartbeat += async f => { await Task.Yield(); };
     _cameras = new ConcurrentDictionary<string, RemoteCameraModel>(StringComparer.OrdinalIgnoreCase);
     _ping = new PingUtility(50123);
     _sender = new CommandSender();
     _listener = new CommandListener();
     _listener.RegisterHandler<ReportingCommand, RemoteCameraModel>(HandleReporting);
     _uploader = new UploadListener();
     _heartbeat = new HeartBeatListener();
     _heartbeat.DataRecieved += async f => { await CameraHeartbeat(f); };
 }
 public CameraClientRemoteControl(CameraClientViewModel model, ClientController camera)
 {
     _model = model;
     _camera = camera;
     _heartbeat = new HeartbeatTimer(() => Task.FromResult(0));
     _ping = new PingUtility(50123);
     _ping.HandlePing += ReportCamera;
     _listener = new CommandListener();
     _listener.RegisterHandler<RecordCommand, RecordCommand>(RemoteRecord);
     _listener.RegisterHandler<EnableHeartbeatCommand, EnableHeartbeatCommand>(EnableHeartbeat);
     _listener.RegisterHandler<UpdateResolutionCommand, RemoteResolutionModel>(UpdateResolution);
 }