From fc74865c5bfd46244253ce85b2140a7dc1bd11a2 Mon Sep 17 00:00:00 2001 From: Drew Tingen Date: Wed, 27 May 2020 11:25:14 -0400 Subject: [PATCH 1/3] feat: Use CrestronEnvironment.SystemInfo.SerialNumber to retrieve the serial number, instead of trying to convert TSID from console. --- ICD.Common.Utils/ProcessorUtils.SimplSharp.cs | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/ICD.Common.Utils/ProcessorUtils.SimplSharp.cs b/ICD.Common.Utils/ProcessorUtils.SimplSharp.cs index 032ec33..ee16c91 100644 --- a/ICD.Common.Utils/ProcessorUtils.SimplSharp.cs +++ b/ICD.Common.Utils/ProcessorUtils.SimplSharp.cs @@ -1,7 +1,8 @@ -using System.Globalization; +#if SIMPLSHARP +using System.Globalization; +using Crestron.SimplSharp; using ICD.Common.Utils.Services; using ICD.Common.Utils.Services.Logging; -#if SIMPLSHARP using System; using System.Text.RegularExpressions; using ICD.Common.Properties; @@ -117,19 +118,7 @@ namespace ICD.Common.Utils { get { - Regex regex = new Regex(VER_REGEX); - Match match = regex.Match(VersionResult); - - if (!match.Success) - { - ServiceProvider.TryGetService() - .AddEntry(eSeverity.Warning, "Unable to get serial number from \"{0}\"", VersionResult); - - return string.Empty; - } - - int decValue = int.Parse(match.Groups["serial"].Value, System.Globalization.NumberStyles.HexNumber); - return decValue.ToString(); + return CrestronEnvironment.SystemInfo.SerialNumber; } } From dd3c0f530b3afa308229e595c5a9feebd0b72089 Mon Sep 17 00:00:00 2001 From: Drew Tingen Date: Wed, 27 May 2020 11:28:12 -0400 Subject: [PATCH 2/3] chore: Changelog --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2ea21a1..a783400 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] +### Changed + - Changed ProcessorUtils to use CrestronEnvironment to retrive serial number - this fixes issues with new serial numbers that aren't deciaml TSIDs ## [8.9.0] - 2020-04-30 ### Changed From 62f54f1213a080ac8f2a0bc8e0d3b7b9c4888d86 Mon Sep 17 00:00:00 2001 From: Chris Cameron Date: Wed, 27 May 2020 15:56:22 -0400 Subject: [PATCH 3/3] chore: Updating changelog, incrementing patch version --- CHANGELOG.md | 2 ++ ICD.Common.Utils/Properties/AssemblyInfo.cs | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a783400..1247123 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] + +## [8.9.1] - 2020-05-27 ### Changed - Changed ProcessorUtils to use CrestronEnvironment to retrive serial number - this fixes issues with new serial numbers that aren't deciaml TSIDs diff --git a/ICD.Common.Utils/Properties/AssemblyInfo.cs b/ICD.Common.Utils/Properties/AssemblyInfo.cs index 1a01e43..7f9dce7 100644 --- a/ICD.Common.Utils/Properties/AssemblyInfo.cs +++ b/ICD.Common.Utils/Properties/AssemblyInfo.cs @@ -4,4 +4,4 @@ using System.Reflection; [assembly: AssemblyCompany("ICD Systems")] [assembly: AssemblyProduct("ICD.Common.Utils")] [assembly: AssemblyCopyright("Copyright © ICD Systems 2020")] -[assembly: AssemblyVersion("8.9.0.0")] +[assembly: AssemblyVersion("8.9.1.0")]