Cable Loss Compensation Tutorial

RFID SDK for Android 2.0.2.124

Applicable Devices : FXR90.

Overview

This Tutorial provides a walk-through of the steps to perform get and set cable loss compensation operations using RFID3 API

Create The Project

  • Start by creating a new project in Android Studio. For help, see the Android Studio tutorial.
  • Refer Hello RFID to prepare basic setup to work with RFID Reader and then follow this guide

Details

This tutorial will describe the apis for setting and getting the cable loss compensation.

Setting it up

The following are the steps to get and set cable loss compensation to the reader

  • Creating a RFIDReader Object
  • Perform get and set cable loss compensationoperations.

// create and initialize the Reader Management object.
    mReader = new RFIDReader(hostName,ZIOTCport, timeoutMilliSeconds, "ZIOTC", "ZIOTC");

                                               

Performing operation

Get Cable Loss Compensation.


// Get Cable Loss Compensation.
    try {
        CableLossCompensation cableLossCompensation = readerManagement.getCableLossCompensation(1);
    } catch (InvalidUsageException e) {
        e.printStackTrace();
    } catch (OperationFailureException e) {
        e.printStackTrace();
    }



Set Cable Loss Compensation.


// Set Cable Loss Compensation.
    try {
        CableLossCompensation cableLossCompensation = readerManagement.getCableLossCompensation(1);
        CableLossCompensation[] cableLossCompensationInfo = new CableLossCompensation[0];
        cableLossCompensationInfo[0] = cableLossCompensation;
        readerManagement.setCableLossCompensation(cableLossCompensationInfo);
    } catch (InvalidUsageException e) {
        e.printStackTrace();
    } catch (OperationFailureException e) {
        e.printStackTrace();
    }


Closer look

Antenna id of the reader