public FgfsClient(FgfsDataHelper Helper, TcpClient client, int OutputPort) : this("127.0.0.1", OutputPort) { _dataObject = Helper.DataObject; _dataHelper = Helper; mTCPClientOutput = client; }
public FgfsClient(TcpClient client,int OutputPort) : this("127.0.0.1",OutputPort) { _dataObject = new FgfsDataObject(); _dataHelper = new FgfsDataHelper(_dataObject); mTCPClientOutput = client; }
public FgfsDataHelper(FgfsDataObject dataObject) { Console.WriteLine("Constructor: FgfsDataHelper"); this.DataObject = dataObject; }
public void UpdateObserver(FgfsDataObject dataObject) { if (this.InvokeRequired == false) { DataObject = dataObject; DisplayData(); } else { UpdateObserverDelegate updateDelegate = new UpdateObserverDelegate(UpdateObserver); this.BeginInvoke(updateDelegate, new object[] { dataObject }); } }
private void InitializePrivates() { Console.WriteLine("Init the privates ..."); //init the privates _dataObject = new FgfsDataObject(); _dataHelper = new FgfsDataHelper(_dataObject); _registredDisplays = new ArrayList(); //_display = new FgfsDisplay(); #if USING_MS_SAPI // MS Speech SDK //SpeechVoiceSpeakFlags SpFlags = SpeechVoiceSpeakFlags.SVSFlagsAsync; SpFlags = SpeechVoiceSpeakFlags.SVSFlagsAsync; ms_Voice = null; //this._speechObj = null; #else this._soundCheckBox.Enabled = false; #endif this._sPort = null; this._swLog = null; //prepare the gui IpComboBox.DataSource = FgfsServer.DeterminePossibleIPs(); // initialize pitch/roll max/min _max_pitch = -1; _min_pitch = 999999; _max_roll = -1; _min_roll = 999999; pitch_max = this.PitchBar.Maximum; pitch_min = this.PitchBar.Minimum; roll_max = this.RollBar.Maximum; roll_min = this.RollBar.Minimum; pitch_scale = pitch_max - pitch_min; roll_scale = roll_max - roll_min; pitch_scale2 = pitch_scale / 2; roll_scale2 = roll_scale / 2; Console.WriteLine("pitch {0} {1} {2} {3} roll {4} {5} {6} {7}", pitch_min, pitch_max, pitch_scale, pitch_scale2, roll_min, roll_max, roll_scale, roll_scale2); }