Issue in getting current status with Zebra.Printer SDK


I am using the latest version of Zebra.Printer SDK 2.15 with Zebra ZD420 with firmware version V84.20.15Z and Link-OS Version 5.2, on a Xamarin Forms iOS app. While trying to get the current status using

ZebraPrinter printer = ZebraPrinterFactory.GetInstance(connection);

   string errorMessage = GetPrinterStatusErrorMessage(printer.GetCurrentStatus());

I get the following error though not everytime.

  • Zebra.Sdk.Printer.InternalZebraPrinterFactoryHelper.GetLanguage (Zebra.Sdk.Comm.Connection connection, System.String[] cpclFwVersionPrefixes)
  • Zebra.Sdk.Printer.InternalZebraPrinterFactoryHelper.GetInstance (System.String[] cpclFwVersionPrefixes, Zebra.Sdk.Comm.Connection connection)
  • Zebra.Sdk.Printer.InternalZebraPrinterFactoryHelper.GetInstance (Zebra.Sdk.Comm.Connection connection)
  • Zebra.Sdk.PrinterZebraPrinterFactory.GetInstance (Zebra.Sdk.Comm.Connection connection)

Also sometime I get this error also, very random and goes off if I rebuild the solution.

Zebra.Sdk.Comm.ConnectionException: Could not connect to device: Could not initialize an instance of the type 'ExternalAccessory.EASession': the native 'initWithAccessory:forProtocol:' method returned nil.

Can you please help ?