public void DownloadData() { acqTimeUTC = DateTime.UtcNow; // get local acq time TimeZoneInfo turkeyTZ; try { turkeyTZ = TimeZoneInfo.FindSystemTimeZoneById("Turkey Standard Time"); } catch { turkeyTZ = TimeZoneInfo.FindSystemTimeZoneById("Turkey"); } // TimeZoneInfo utcOffset = turkeyTZ.GetUtcOffset(acqTimeUTC); acqTimeLocal = acqTimeUTC.Add(utcOffset); sensorData = SpeedSensorData.ParseSpeedData(TKM.DownloadTrafficData()); trafficIndex = TKM.DownloadTrafficIndex(); }
public async Task <SpeedSensorData> Create(SpeedSensorData data) { return(await _repository.Create(data)); }