Esempio n. 1
0
        public CarWithFakeRegulators(DefaultCarController parent)
        {
            Controller = parent;
            CarInfo    = new CarInformations();

            SteeringWheelAngleRegulator = new FakeSteeringWheelRegulator();
            SpeedRegulator = new FakeSpeedRegulator();
            BrakeRegulator = new FakeBrakeRegulator();

            CarComunicator = new RealCarCommunicator(this);
        }
Esempio n. 2
0
        public CarWithFakeRegulators(DefaultCarController parent)
        {
            Controller = parent;
            CarInfo = new CarInformations();

            SteeringWheelAngleRegulator = new FakeSteeringWheelRegulator();
            SpeedRegulator = new FakeSpeedRegulator();
            BrakeRegulator = new FakeBrakeRegulator();

            CarComunicator = new RealCarCommunicator(this);
        }
Esempio n. 3
0
        public CarWithFakeCommunicator(DefaultCarController parent)
        {
            Controller = parent;
            CarInfo = new CarInformations();

            CarComunicator = new FakeCarCommunicator(this);

            SteeringWheelAngleRegulator = new PIDSteeringWheelAngleRegulator(this);
            SpeedRegulator = new PIDSpeedRegulator(this);
            BrakeRegulator = new PIDBrakeRegulator(this);

            CarComunicator.InitRegulatorsEventsHandling();
        }
Esempio n. 4
0
        public CarWithFakeCommunicator(DefaultCarController parent)
        {
            Controller = parent;
            CarInfo    = new CarInformations();

            CarComunicator = new FakeCarCommunicator(this);

            SteeringWheelAngleRegulator = new PIDSteeringWheelAngleRegulator(this);
            SpeedRegulator = new PIDSpeedRegulator(this);
            BrakeRegulator = new PIDBrakeRegulator(this);

            CarComunicator.InitRegulatorsEventsHandling();
        }
Esempio n. 5
0
        /// <summary>
        /// constructor which is initializing CarController on itself
        /// </summary>
        public MainWindow()
        {
            System.Threading.Thread.CurrentThread.Priority = System.Threading.ThreadPriority.AboveNormal;
            Controller = new DefaultCarController();

            InitializeComponent();

            ExternalEventsHandlingInit();

            this.KeyDown += new KeyEventHandler(MainWindow_KeyDown);

            //initialize timer
            mTimer.Elapsed += mTimer_Elapsed;
            mTimer.Start();
        }
Esempio n. 6
0
        /// <summary>
        /// constructor which is initializing CarController on itself
        /// </summary>
        public MainWindow()
        {
            System.Threading.Thread.CurrentThread.Priority = System.Threading.ThreadPriority.AboveNormal;
            Controller = new DefaultCarController();
            
            InitializeComponent();

            ExternalEventsHandlingInit();
            
            this.KeyDown += new KeyEventHandler(MainWindow_KeyDown);

            //initialize timer
            mTimer.Elapsed += mTimer_Elapsed;
            mTimer.Start();
        }
Esempio n. 7
0
        public ViewForm()
        {
            InitializeComponent();

            carController = new CarController.DefaultCarController();
            steeringWindow = new CarController.MainWindow(carController);
            steeringWindow.Show();
            steeringWindow.Activate();
        }
Esempio n. 8
0
 public JurekServer(int port)
     : base(port) {
         carController = new DefaultCarController();
 }