BradyCorp.Xamarin.SDK 1.2.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package BradyCorp.Xamarin.SDK --version 1.2.1                
NuGet\Install-Package BradyCorp.Xamarin.SDK -Version 1.2.1                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="BradyCorp.Xamarin.SDK" Version="1.2.1" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add BradyCorp.Xamarin.SDK --version 1.2.1                
#r "nuget: BradyCorp.Xamarin.SDK, 1.2.1"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install BradyCorp.Xamarin.SDK as a Cake Addin
#addin nuget:?package=BradyCorp.Xamarin.SDK&version=1.2.1

// Install BradyCorp.Xamarin.SDK as a Cake Tool
#tool nuget:?package=BradyCorp.Xamarin.SDK&version=1.2.1                

BradyCorp.Xamarin.SDK

The official Xamarin wrapper for the Brady SDK allows development in C# to integrate both the iOS and Android functionalities supported by the Brady SDK's.


Setup

To start, you must add this package to both the iOS and Android native projects if you are using a Xamarin.Forms application. To access the library's API, use the following using statements:

- Android: "using BradySdkBindings.Droid"
- iOS: "using BradySdkBindings.iOS"

Next, intialize a BradySdk object using the constructors:

- Android: "new BradySdk(Context)"
- iOS: "new BradySdk()"

NOTE: The Xamarin Binding MUST be implemented for both iOS and Android separately in both native projects. This is due to different constructors for each platform and alternative threading methods that need to be dealt with differently.

NOTE: Usable templates MUST be embedded in the Xamarin app's Resources and marked as an "AndroidResource" in the files "build properties". Currently, we do not support users retrieving files from their device's file system at runtime. This is due to a data conversion issue between languages in the back-end.


For both Android and iOS, you must call the .connectToPrinter(String) and .print() methods from a different thread. That might look like this:

Thread connectThread = new Thread(() =>
{
    bool status = BradySdk.connectToPrinter(printer).Result;
    if (status)
    {
       Debug.WriteLine("Connection Status: " + status);
    }
});
connectThread.Start();
Product Compatible and additional computed target framework versions.
MonoAndroid monoandroid12.0 is compatible. 
Xamarin.iOS xamarinios is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.7.0 132 4/25/2024
1.3.4 950 1/23/2024
1.3.2 1,793 12/5/2023
1.3.1 1,555 11/14/2023
1.3.0 996 10/11/2023
1.2.4 1,389 8/21/2023
1.2.3 1,415 8/9/2023
1.2.2 1,588 8/8/2023
1.2.1 1,350 8/4/2023
1.2.0 1,715 8/1/2023
1.1.0 1,607 7/18/2023
1.0.4 1,358 7/14/2023
1.0.3 1,653 7/6/2023

1.2.1
- Fixed edge-case where ASCII characters would be trimmed off of a Barcode's value.
- Made PrinterDetail attributes public. 18 Getter methods added to the API.

1.2.0
- Changed the print() API to take an integer representing the amount of copies to print.
- Fixed multiple Data Matrix, QR Code, and Code128 encoding and rendering bugs.
- Fixed an issue where the back end could not notify the front end of a unexpected disconnection.
- Added LZ4 compression for connecting to the M611 Latimer (10 second faster connection on average).

1.1.0

- Added a new getTemplate method that allows a user to pass in a file name instead of data to retrieve a Template.
- The first functional version used by a customer

1.0.4

- Fixed internal auto-connection issues with Bluetooth Classic and Wifi connections.
- Fixed bug where the ConnectionType was not accurate.
- Fixed a typo in the returned PrinterDetails.
- Added 3 exceptions that are thrown when failing to connect to a printer.
- Now includes Debug version and .pdb for debugging.

1.0.3

- This version is consistent with the Brady SDK Flutter plugin's API and contains the same capabilities such as:
- Discovering, connecting, and printing to the M211, M611, and M511 via Bluetooth Low Energy.
- Discovering, connecting, and printing to the M611 via wireless internet (Wifi).
- Deserealizing and printing any Brady Workstation objects in a BWT file referenced at https://sdk.bradyid.com/supported_objects/
- Feeding, cutting, and disconnecting.
- Supports a version of auto connecting to your previously connected to printer via the getLastConnectedPrinterName API method.

1.0.2, 1.0.1, and 1.0.0
All versions of the Xamarin Bindings that were created, used, and tested locally.
This was done by generating a .nupkg and manually adding the package to a test project.