示例#1
0
        public AudioPlayer()
        {
            InitializeComponent();

            ///////////////////////////////////////////////////////////////////////////
            // Constructor inits

            abo.setCpm(cpm);
            abo.setStorage(storage);

            asva.setChecks(checks);
            asva.setLeds(leds);
            asva.setStorage(storage);

            answersSerial.setAsva(asva);
            answersSerial.setGsr(gsr);
            answersSerial.setLeds(leds);
            answersSerial.setStorage(storage);

            bcc.setCpm(cpm);
            bcc.setGsr(gsr);
            bcc.setChecks(checks);
            bcc.setStorage(storage);

            cpm.setLeds(leds);
            cpm.setStorage(storage);

            gsr.setCpm(cpm);
        }
示例#2
0
        public InputSettings()
        {
            InitializeComponent();

            ///////////////////////////////////////////////////////////////////////////
            // Constructor inits

            abo.setCpm(cpm);
            abo.setStorage(storage);
            abo.setTimerClass(tc);

            asva.setChecks(checks);
            asva.setLeds(leds);
            asva.setStorage(storage);

            answersSerial.setAsva(asva);
            answersSerial.setGsr(gsr);
            answersSerial.setLeds(leds);
            answersSerial.setStorage(storage);

            bcc.setCpm(cpm);
            bcc.setGsr(gsr);
            bcc.setTc(tc);
            bcc.setChecks(checks);
            bcc.setStorage(storage);

            cpm.setLeds(leds);
            cpm.setStorage(storage);

            gsr.setCpm(cpm);

            tc.setCpm(cpm);
            tc.setGsr(gsr);
            tc.setChecks(checks);
            tc.setStorage(storage);
        }
示例#3
0
        // Main window - methods run on startup
        private void MainWindow_OnLoaded(object sender, RoutedEventArgs e)
        {
            DispatcherTimer timerGuiRefresh = new DispatcherTimer();

            // Network initialization
            _client = new ipClient(host, port);
            TcpClientRun();
            udpServerDiscoverer            = new UdpDiscovery();
            udpServerDiscoverer.NewLogMsg += UdpServerDiscoverer_NewLogMsg;

            ///////////////////////////////////////////////////////////////////////////
            // Constructor inits

            abo.setCpm(cpm);
            abo.setStorage(storage);
            abo.setTimerClass(tc);

            asva.setChecks(checks);
            asva.setLeds(leds);
            asva.setStorage(storage);
            asva.setGamePlayers(gamePlayers);

            answersSerial.setAsva(asva);
            answersSerial.setGsr(gsr);
            answersSerial.setLeds(leds);
            answersSerial.setStorage(storage);

            bcc.setCpm(cpm);
            bcc.setGsr(gsr);
            bcc.setTc(tc);
            bcc.setChecks(checks);
            bcc.setStorage(storage);

            cpm.setLeds(leds);
            cpm.setStorage(storage);
            cpm.setIpClient(_client);

            gpi.setPlayer(gamePlayers);
            gpi.setLedb(ledb);
            gpi.setLidb(lidb);

            gsr.setCpm(cpm);
            gsr.setStorage(storage);

            ledb.setValuePlayers(gamePlayers);
            lidb.setPlayers(gamePlayers);
            lidb.setGpi(gpi);

            tc.setCpm(cpm);
            tc.setGsr(gsr);
            tc.setChecks(checks);
            tc.setStorage(storage);

            ///////////////////////////////////////////////////////////////////////////

            relayStates_get();

            // Set initial default value
            gamePlayers.allowedPPT = 12;
            // Summon lists
            gamePlayers.plInfoGuests = new string[gamePlayers.allowedPPT];
            gamePlayers.plInfoHome   = new string[gamePlayers.allowedPPT];

            // Proceed to program
            commandslogs.ItemsSource = _logs;
            _logsCount            = 0;
            checks.VSTimerStarted = false;
            tc.OnShotTimer        = null;
            tc.timer_Run();
            LEDConnection.Focusable = true;
            LEDConnection.Focus();
            //gameEnteredColorChange();
            elipseFillCheck();

            GTIMEOUT.Content = "TIME" + "\n" + "OUT";
            HTIMEOUT.Content = "TIME" + "\n" + "OUT";
            START.Content    = "START/" + "\n" + "STOP";

            // Timer dispatcher thread
            timerGuiRefresh.Interval = new TimeSpan(0, 0, 0, 0, 20);
            timerGuiRefresh.Tick    += TimerTick;
            timerGuiRefresh.Start();
        }