public HornViewModel() { mRobot = RobotFactory.GetRobotInstance(); SendOnCommand = new RelayCommand(TurnOn); SendOffCommand = new RelayCommand(TurnOff); }
// Sends Commands Msg to robot, if Verification is True protected void SendCommandsToRobot() { if (VerifyReadyToSendMsg()) { RobotFactory.GetRobotInstance().SendMsg(GetMsg(), true); } }
public RobotFigureViewModel() { robot = RobotFactory.GetRobotInstance(); robot.HeadingUpated += Robot_HeadingUpated; EventManager.OnRobotPathChanged += OnRobotPathUpdated; }
public RGBViewModel() { mRobot = RobotFactory.GetRobotInstance(); SendOnCommand = new RelayCommand(TurnOn); SendOffCommand = new RelayCommand(TurnOff); SendLoopCommand = new RelayCommand(TurnLoop); SetColorCommand = new RelayCommand(SetColor); }
public LedViewModel(Light type) { mType = type; mRobot = RobotFactory.GetRobotInstance(); SendOnCommand = new RelayCommand(TurnOn); SendOffCommand = new RelayCommand(TurnOff); SendLoopCommand = new RelayCommand(TurnLoop); }
public HeadingCalibrationViewModel() { robot = RobotFactory.GetRobotInstance(); SetNorthCommand = new RelayCommand(SetNorth); SetEastCommand = new RelayCommand(SetEast); SetSouthCommand = new RelayCommand(SetSouth); SetWestCommand = new RelayCommand(SetWest); }
public DirectControlViewModel() { robot = RobotFactory.GetRobotInstance(); MoveFWDCommand = new RelayCommand(MoveFWD); MoveBCKCommand = new RelayCommand(MoveBCK); TurnLeftCommand = new RelayCommand(TurnLeft); TurnRightCommand = new RelayCommand(TurnRight); StopMovementCommand = new RelayCommand(Stop); }
public ConnectionSettingsViewModel() { robot = RobotFactory.GetRobotInstance(); IsConnected = robot.IsConnected(); ComPorts = new List <string>(); ComPorts.AddRange(SerialPort.GetPortNames()); robot.ConnectionStatusChanged += Robot_ConnectionStatusChanged; ConnectCommand = new RelayCommand(ConnectToRobot); DisconnectCommand = new RelayCommand(DisconnectToRobot); }