diff options
| author | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2024-05-05 18:40:15 +0300 |
|---|---|---|
| committer | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2024-05-05 18:40:15 +0300 |
| commit | 700a9ea9e2c9d95f0c5739c58974eafaff2ebeb9 (patch) | |
| tree | e6e6d2d1870f8115c7e740576367b97c27a75742 /Software/Visual_Studio/Tango.PMR | |
| parent | 2e752ce186fc34f5530841bdac7537ee775ed3f6 (diff) | |
| download | Tango-700a9ea9e2c9d95f0c5739c58974eafaff2ebeb9.tar.gz Tango-700a9ea9e2c9d95f0c5739c58974eafaff2ebeb9.zip | |
Support for 64 Bit Dispenser Levels.
Diffstat (limited to 'Software/Visual_Studio/Tango.PMR')
| -rw-r--r-- | Software/Visual_Studio/Tango.PMR/Connection/ConnectRequest.cs | 37 | ||||
| -rw-r--r-- | Software/Visual_Studio/Tango.PMR/MachineStatus/IDSPackLevel.cs | 40 |
2 files changed, 69 insertions, 8 deletions
diff --git a/Software/Visual_Studio/Tango.PMR/Connection/ConnectRequest.cs b/Software/Visual_Studio/Tango.PMR/Connection/ConnectRequest.cs index d62d5dbc5..27d5d6cb2 100644 --- a/Software/Visual_Studio/Tango.PMR/Connection/ConnectRequest.cs +++ b/Software/Visual_Studio/Tango.PMR/Connection/ConnectRequest.cs @@ -23,16 +23,17 @@ namespace Tango.PMR.Connection { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( "ChRDb25uZWN0UmVxdWVzdC5wcm90bxIUVGFuZ28uUE1SLkNvbm5lY3Rpb24a", - "EkpvYlNwb29sVHlwZS5wcm90bxoRTWFjaGluZVR5cGUucHJvdG8inQEKDkNv", + "EkpvYlNwb29sVHlwZS5wcm90bxoRTWFjaGluZVR5cGUucHJvdG8iwgEKDkNv", "bm5lY3RSZXF1ZXN0EhAKCFBhc3N3b3JkGAEgASgJEhAKCFVuaXhUaW1lGAIg", "ASgDEjMKCVNwb29sVHlwZRgDIAEoDjIgLlRhbmdvLlBNUi5QcmludGluZy5K", "b2JTcG9vbFR5cGUSMgoLTWFjaGluZVR5cGUYBCABKA4yHS5UYW5nby5QTVIu", - "Q29tbW9uLk1hY2hpbmVUeXBlQiAKHmNvbS50d2luZS50YW5nby5wbXIuY29u", - "bmVjdGlvbmIGcHJvdG8z")); + "Q29tbW9uLk1hY2hpbmVUeXBlEiMKG1N1cHBvcnRzNjRCaXREaXNwZW5zZXJM", + "ZXZlbBgFIAEoCEIgCh5jb20udHdpbmUudGFuZ28ucG1yLmNvbm5lY3Rpb25i", + "BnByb3RvMw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Tango.PMR.Printing.JobSpoolTypeReflection.Descriptor, global::Tango.PMR.Common.MachineTypeReflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { - new pbr::GeneratedClrTypeInfo(typeof(global::Tango.PMR.Connection.ConnectRequest), global::Tango.PMR.Connection.ConnectRequest.Parser, new[]{ "Password", "UnixTime", "SpoolType", "MachineType" }, null, null, null) + new pbr::GeneratedClrTypeInfo(typeof(global::Tango.PMR.Connection.ConnectRequest), global::Tango.PMR.Connection.ConnectRequest.Parser, new[]{ "Password", "UnixTime", "SpoolType", "MachineType", "Supports64BitDispenserLevel" }, null, null, null) })); } #endregion @@ -67,6 +68,7 @@ namespace Tango.PMR.Connection { unixTime_ = other.unixTime_; spoolType_ = other.spoolType_; machineType_ = other.machineType_; + supports64BitDispenserLevel_ = other.supports64BitDispenserLevel_; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -118,6 +120,17 @@ namespace Tango.PMR.Connection { } } + /// <summary>Field number for the "Supports64BitDispenserLevel" field.</summary> + public const int Supports64BitDispenserLevelFieldNumber = 5; + private bool supports64BitDispenserLevel_; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Supports64BitDispenserLevel { + get { return supports64BitDispenserLevel_; } + set { + supports64BitDispenserLevel_ = value; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override bool Equals(object other) { return Equals(other as ConnectRequest); @@ -135,6 +148,7 @@ namespace Tango.PMR.Connection { if (UnixTime != other.UnixTime) return false; if (SpoolType != other.SpoolType) return false; if (MachineType != other.MachineType) return false; + if (Supports64BitDispenserLevel != other.Supports64BitDispenserLevel) return false; return true; } @@ -145,6 +159,7 @@ namespace Tango.PMR.Connection { if (UnixTime != 0L) hash ^= UnixTime.GetHashCode(); if (SpoolType != 0) hash ^= SpoolType.GetHashCode(); if (MachineType != 0) hash ^= MachineType.GetHashCode(); + if (Supports64BitDispenserLevel != false) hash ^= Supports64BitDispenserLevel.GetHashCode(); return hash; } @@ -171,6 +186,10 @@ namespace Tango.PMR.Connection { output.WriteRawTag(32); output.WriteEnum((int) MachineType); } + if (Supports64BitDispenserLevel != false) { + output.WriteRawTag(40); + output.WriteBool(Supports64BitDispenserLevel); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -188,6 +207,9 @@ namespace Tango.PMR.Connection { if (MachineType != 0) { size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) MachineType); } + if (Supports64BitDispenserLevel != false) { + size += 1 + 1; + } return size; } @@ -208,6 +230,9 @@ namespace Tango.PMR.Connection { if (other.MachineType != 0) { MachineType = other.MachineType; } + if (other.Supports64BitDispenserLevel != false) { + Supports64BitDispenserLevel = other.Supports64BitDispenserLevel; + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -234,6 +259,10 @@ namespace Tango.PMR.Connection { machineType_ = (global::Tango.PMR.Common.MachineType) input.ReadEnum(); break; } + case 40: { + Supports64BitDispenserLevel = input.ReadBool(); + break; + } } } } diff --git a/Software/Visual_Studio/Tango.PMR/MachineStatus/IDSPackLevel.cs b/Software/Visual_Studio/Tango.PMR/MachineStatus/IDSPackLevel.cs index a11341386..917fa5304 100644 --- a/Software/Visual_Studio/Tango.PMR/MachineStatus/IDSPackLevel.cs +++ b/Software/Visual_Studio/Tango.PMR/MachineStatus/IDSPackLevel.cs @@ -23,16 +23,17 @@ namespace Tango.PMR.MachineStatus { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( "ChJJRFNQYWNrTGV2ZWwucHJvdG8SF1RhbmdvLlBNUi5NYWNoaW5lU3RhdHVz", - "ItcBCgxJRFNQYWNrTGV2ZWwSDQoFSW5kZXgYASABKAUSFgoORGlzcGVuc2Vy", + "IvEBCgxJRFNQYWNrTGV2ZWwSDQoFSW5kZXgYASABKAUSFgoORGlzcGVuc2Vy", "TGV2ZWwYAiABKAUSFAoMTWlkVGFua0xldmVsGAMgASgBEhcKD0plcnJpY2Fu", "UHJlc2VudBgEIAEoCBIbChNGaWxsaW5nVGltZW91dEVycm9yGAUgASgIEhQK", "DE1pZFRhbmtFbXB0eRgGIAEoCBIfChdNaWRUYW5rUmVmaWxsUHVtcEFjdGl2", - "ZRgHIAEoCBIdChVUaW1lclJlbWFpbmluZ1NlY29uZHMYCCABKAVCIwohY29t", - "LnR3aW5lLnRhbmdvLnBtci5tYWNoaW5lc3RhdHVzYgZwcm90bzM=")); + "ZRgHIAEoCBIdChVUaW1lclJlbWFpbmluZ1NlY29uZHMYCCABKAUSGAoQRGlz", + "cGVuc2VyTGV2ZWw2NBgJIAEoA0IjCiFjb20udHdpbmUudGFuZ28ucG1yLm1h", + "Y2hpbmVzdGF0dXNiBnByb3RvMw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { }, new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { - new pbr::GeneratedClrTypeInfo(typeof(global::Tango.PMR.MachineStatus.IDSPackLevel), global::Tango.PMR.MachineStatus.IDSPackLevel.Parser, new[]{ "Index", "DispenserLevel", "MidTankLevel", "JerricanPresent", "FillingTimeoutError", "MidTankEmpty", "MidTankRefillPumpActive", "TimerRemainingSeconds" }, null, null, null) + new pbr::GeneratedClrTypeInfo(typeof(global::Tango.PMR.MachineStatus.IDSPackLevel), global::Tango.PMR.MachineStatus.IDSPackLevel.Parser, new[]{ "Index", "DispenserLevel", "MidTankLevel", "JerricanPresent", "FillingTimeoutError", "MidTankEmpty", "MidTankRefillPumpActive", "TimerRemainingSeconds", "DispenserLevel64" }, null, null, null) })); } #endregion @@ -71,6 +72,7 @@ namespace Tango.PMR.MachineStatus { midTankEmpty_ = other.midTankEmpty_; midTankRefillPumpActive_ = other.midTankRefillPumpActive_; timerRemainingSeconds_ = other.timerRemainingSeconds_; + dispenserLevel64_ = other.dispenserLevel64_; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -166,6 +168,20 @@ namespace Tango.PMR.MachineStatus { } } + /// <summary>Field number for the "DispenserLevel64" field.</summary> + public const int DispenserLevel64FieldNumber = 9; + private long dispenserLevel64_; + /// <summary> + ///Used only for X4 + /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public long DispenserLevel64 { + get { return dispenserLevel64_; } + set { + dispenserLevel64_ = value; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override bool Equals(object other) { return Equals(other as IDSPackLevel); @@ -187,6 +203,7 @@ namespace Tango.PMR.MachineStatus { if (MidTankEmpty != other.MidTankEmpty) return false; if (MidTankRefillPumpActive != other.MidTankRefillPumpActive) return false; if (TimerRemainingSeconds != other.TimerRemainingSeconds) return false; + if (DispenserLevel64 != other.DispenserLevel64) return false; return true; } @@ -201,6 +218,7 @@ namespace Tango.PMR.MachineStatus { if (MidTankEmpty != false) hash ^= MidTankEmpty.GetHashCode(); if (MidTankRefillPumpActive != false) hash ^= MidTankRefillPumpActive.GetHashCode(); if (TimerRemainingSeconds != 0) hash ^= TimerRemainingSeconds.GetHashCode(); + if (DispenserLevel64 != 0L) hash ^= DispenserLevel64.GetHashCode(); return hash; } @@ -243,6 +261,10 @@ namespace Tango.PMR.MachineStatus { output.WriteRawTag(64); output.WriteInt32(TimerRemainingSeconds); } + if (DispenserLevel64 != 0L) { + output.WriteRawTag(72); + output.WriteInt64(DispenserLevel64); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -272,6 +294,9 @@ namespace Tango.PMR.MachineStatus { if (TimerRemainingSeconds != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(TimerRemainingSeconds); } + if (DispenserLevel64 != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(DispenserLevel64); + } return size; } @@ -304,6 +329,9 @@ namespace Tango.PMR.MachineStatus { if (other.TimerRemainingSeconds != 0) { TimerRemainingSeconds = other.TimerRemainingSeconds; } + if (other.DispenserLevel64 != 0L) { + DispenserLevel64 = other.DispenserLevel64; + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -346,6 +374,10 @@ namespace Tango.PMR.MachineStatus { TimerRemainingSeconds = input.ReadInt32(); break; } + case 72: { + DispenserLevel64 = input.ReadInt64(); + break; + } } } } |
