private void CheckTrack401(double xPoint, double yPoint)
        {
            if (ModbusProtocol.GetDataCoils(4) == false && xPoint < 500 && xPoint != 0 && direction == 0)
            {
                storyboard.Pause();
                timer.Stop();
                TrainViewModel.queueTrainTo401Track.Add(trainNumber);
            }

            TrackSensorsViewModel.Track408(xPoint, yPoint);
            TrackSensorsViewModel.Track411(xPoint, yPoint);
            TrackSensorsViewModel.Track401a(xPoint, yPoint);
            TrackSensorsViewModel.Track401b(xPoint, yPoint);
            TrackSensorsViewModel.Track401c(xPoint, yPoint);
            TrackSensorsViewModel.Track401d(xPoint, yPoint);
            TrackSensorsViewModel.Track401e(xPoint, yPoint);
            TrackSensorsViewModel.Track440(xPoint, yPoint);
            TrackSensorsViewModel.Track441(xPoint, yPoint);
            TrackSensorsViewModel.Track444(xPoint, yPoint);
        }
        private void CheckTrack404(double xPoint, double yPoint)
        {
            if (ModbusProtocol.GetDataCoils(2) == false && xPoint < 500 && xPoint != 0)
            {
                TrainViewModel.queueTrainTo404Track.Add(trainNumber);
                storyboard.Pause();
                timer.Stop();
            }


            TrackSensorsViewModel.Track408(xPoint, yPoint);
            TrackSensorsViewModel.Track411(xPoint, yPoint);
            TrackSensorsViewModel.Track412(xPoint, yPoint);
            TrackSensorsViewModel.Track404a(xPoint, yPoint);
            TrackSensorsViewModel.Track404b(xPoint, yPoint);
            TrackSensorsViewModel.Track404c(xPoint, yPoint);
            TrackSensorsViewModel.Track404d(xPoint, yPoint);
            TrackSensorsViewModel.Track404e(xPoint, yPoint);
            TrackSensorsViewModel.Track441(xPoint, yPoint);
            TrackSensorsViewModel.Track444(xPoint, yPoint);
        }
        private void CheckTrack402(double xPoint, double yPoint)
        {
            if (ModbusProtocol.GetDataCoils(3) == false && xPoint < 500 && xPoint != 0)
            {
                storyboard.Pause();
                timer.Stop();
                TrainViewModel.trainWait = true;
                TrainViewModel.queueTrainTo402Track.Add(trainNumber);
            }

            TrackSensorsViewModel.Track408(xPoint, yPoint);
            TrackSensorsViewModel.Track411(xPoint, yPoint);
            TrackSensorsViewModel.Track412(xPoint, yPoint);
            TrackSensorsViewModel.Track402a(xPoint, yPoint);
            TrackSensorsViewModel.Track402b(xPoint, yPoint);
            TrackSensorsViewModel.Track402c(xPoint, yPoint);
            TrackSensorsViewModel.Track402d(xPoint, yPoint);
            TrackSensorsViewModel.Track402e(xPoint, yPoint);
            TrackSensorsViewModel.Track440(xPoint, yPoint);
            TrackSensorsViewModel.Track441(xPoint, yPoint);
            TrackSensorsViewModel.Track444(xPoint, yPoint);
        }