Beispiel #1
0
        public DeployerConsole()
        {
            var appDataDir = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData);
            var rootDir = Path.Combine(appDataDir, "DeployerOfCodes");
            if (!Directory.Exists(rootDir))
                Directory.CreateDirectory(rootDir);

            var factory = new TextDeployerFactory();
            _runner = new ModeRunner(factory, rootDir);
            _runner.Start();

            _timer = new Timer {Interval = 1000.0};
            _timer.Elapsed += Tick;
            _timer.Start();
        }
Beispiel #2
0
        private void ProgramStarted()
        {
            var memory = Debug.GC(true);
            Debug.Print("Memory at startup = " + memory);

            SetupPersistence();
            SetupInputs();

            var factory = new RealDeployerFactory(Mainboard.Ethernet,
                                                  Mainboard.SDCardStorageDevice,
                                                  breakoutTB10,
                                                  characterDisplay,
                                                  tunes);
            factory.Initialize();
            _modeRunner = new ModeRunner(factory, _rootDir);
            _modeRunner.Start();

            SetupInterrupts();
            SetupTimers();
        }