From 368f0b99df7f5efd64d58f82aabb98232d9ce7ee Mon Sep 17 00:00:00 2001 From: Eveldee Date: Wed, 24 Apr 2019 23:14:57 +0200 Subject: [PATCH] Update Protocol, parsing errors --- PlantBox.Shared/Communication/Commands/CaptorValue.cs | 4 ++++ PlantBox.Shared/Communication/Commands/HistoricResponse.cs | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/PlantBox.Shared/Communication/Commands/CaptorValue.cs b/PlantBox.Shared/Communication/Commands/CaptorValue.cs index a760d66..7819177 100644 --- a/PlantBox.Shared/Communication/Commands/CaptorValue.cs +++ b/PlantBox.Shared/Communication/Commands/CaptorValue.cs @@ -13,6 +13,10 @@ namespace PlantBox.Shared.Communication.Commands public double Max { get; set; } public double Value { get; set; } + public CaptorValue() + { + + } public CaptorValue(string argument) { string[] arguments = argument.Split(ValueSeparator); diff --git a/PlantBox.Shared/Communication/Commands/HistoricResponse.cs b/PlantBox.Shared/Communication/Commands/HistoricResponse.cs index b3bbcf3..d62b16f 100644 --- a/PlantBox.Shared/Communication/Commands/HistoricResponse.cs +++ b/PlantBox.Shared/Communication/Commands/HistoricResponse.cs @@ -58,7 +58,7 @@ namespace PlantBox.Shared.Communication.Commands { string Join(double[] values) { - return string.Join(ValueSeparator.ToString(), values); + return string.Join(ValueSeparator.ToString(), values.Select(x => x.ToArgument())); } return new[]