public MorseInterpeter(Arduino i_Arduino) { initOperationsDictionary(); m_PreviousEyeState = EyeState.Open; m_Stopwatch = new Stopwatch(); m_Arduino = i_Arduino; }
public EyeState(Arduino i_Arduino) { initOperationsDictionary(); m_Arduino = i_Arduino; Closed += eyeState_Closed; Open += eyeState_Open; m_StopwatchBuffer = new Stopwatch(); }
/* */ public MainForm(PXCMSession session) { InitializeComponent(); InitializeTextBoxes(); m_faceTextOrganizer = new FaceTextOrganizer(); m_deviceMenuItem = new ToolStripMenuItem("Device"); m_moduleMenuItem = new ToolStripMenuItem("Module"); Session = session; CreateResolutionMap(); PopulateDeviceMenu(); PopulateModuleMenu(); PopulateProfileMenu(); InitializeUserSettings(); InitializeCheckboxes(); DisableUnsupportedAlgos(); RestoreUserSettings(); FormClosing += MainForm_FormClosing; Panel2.Paint += Panel_Paint; m_Util = Util.Instance; fetchOperations(); m_Arduino = new Arduino(new ArduinoManager()); m_CurrentFaceExpression = new Dictionary<PXCMFaceData.ExpressionsData.FaceExpression, int>(); m_FaceExpressions = new List<ExpressionOperation>(); morseInterpeter = new MorseInterpeter(m_Arduino); eyeState = new EyeState(m_Arduino); // eyeState.EyesClosed += EyeState.eyeState_Closed; // eyeState.EyesClosed += EyeState.eyeState_Closed; // eyeState.Closed += new EyeState.MyDelegate(EyeState.eyeState_Closed); // eyeState.Open += new EyeState.MyDelegate(EyeState.eyeState_Open); }