public static void WriteParams(string portName, SmlComServiceClient proxy, Guid clientGuid)
 {
     Console.WriteLine("Writing parameters...");
     //proxy.WriteClearBilling(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName));
     //proxy.WriteClearEvent(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName));
     //proxy.WriteMeasurementMode(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), "MM2");
     proxy.WriteIsPinProtectionActive(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), false);
     proxy.WriteIsManipulationDetectionActive(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), true);
     proxy.WriteDisplaySpecialText(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), "abc");
 }
 private static void WriteSetPinActive(string portName, SmlComServiceClient proxy, Guid clientGuid, bool isActive)
 {
     Console.WriteLine("Setting PIN active to: " + isActive);
     proxy.WriteIsPinProtectionActive(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), isActive);
     Console.WriteLine("PIN activation state was set.");
     Console.WriteLine();
 }