/// <summary>
        /// Апдейт показаний датчика, если новые пришли в десятичной системе
        /// </summary>
        /// <param name="s">JSON[1:Token;2:Текущие показания;3:Всего]</param>
        public void UpdateDecimal(string[] s)
        {
            //Количество тиков до объявления инцидента
            int maxOffCount = 600;
            //Текущее состояние датчика
            StateEnum curState;

            var token = s[0];

            Incident opIncident = null;
            var      sensor     = GetByToken(token);
            Shift    curShift;
            var      shifts = ShiftManager.GetByFactoryId(sensor.FactoryId, StateEnum.INPROCESS.ToString());

            if (shifts.Count == 0)
            {
                curShift = null;
            }
            else
            {
                curShift = shifts.First();
            }

            if (sensor != null)
            {
                if (curShift != null)
                {
                    opIncident = IncidentManager.GetIncident(curShift.Id, sensor.Id);
                }
                if (curShift == null)
                {
                    curState           = StateEnum.OFF;
                    sensor.NoLoadCount = 0;
                }
                else if (s[1].Contains("5TOP") || s[1] == "")
                {
                    curState = StateEnum.STOP;
                    if (curShift != null)
                    {
                        sensor.NoLoadCount++;
                        sensor.DownTime += 3;
                    }
                }
                else if (Math.Abs(sensor.TotalWeight - s[2].ToDouble()) <= 0.01)
                {
                    curState = StateEnum.NOLOAD;

                    if (curShift != null)
                    {
                        sensor.NoLoadCount++;
                        sensor.DownTime += 3;
                    }
                }

                else
                {
                    curState           = StateEnum.OK;
                    sensor.NoLoadCount = 0;
                }

                if (sensor.NoLoadCount > maxOffCount && opIncident == null)
                {
                    IncidentManager.AddIncident(curShift.Id, sensor.Id);
                }
                if (sensor.NoLoadCount != 0 && sensor.NoLoadCount % maxOffCount == 0 && opIncident != null)
                {
                    IncidentManager.Notify(IncidentManager.GetIncident(curShift.Id, sensor.Id));
                }

                sensor.StateEnum   = curState;
                sensor.CurWeight   = s[1];
                sensor.TotalWeight = s[2].ToDouble();
                sensor.Date        = DateTime.Now.ToString("MM/dd/yyyy HH:mm:ss",
                                                           CultureInfo.InvariantCulture);



                try
                {
                    var path = "\\sensor_" + sensor.Id + "_Log.txt";
                    FileManager.WrightData(path, sensor.ToString());
                }
                catch (Exception)
                {
                    throw;
                }

                SensorRepo.Update(sensor);
                SensorRepo.Save();
            }
            else
            {
                throw new Exception("Ошибка поиска смены или датчика");
            }
        }