LTKCPP-- LLRP Toolkit C Plus Plus Library
Functions
docsample2.cpp File Reference

LLRP Examples Implementing Use case docSample2 of the LTK programmers guide. More...

#include <stdio.h>
#include "ltkcpp.h"
#include "impinj_ltkcpp.h"
#include "time.h"

Go to the source code of this file.

Functions

int main (int ac, char *av[])
 Command main routine. More...
 
void usage (char *pProgName)
 Print usage message and exit. More...
 

Detailed Description

LLRP Examples Implementing Use case docSample2 of the LTK programmers guide.

The steps:

  1. Initialize Library
  2. Connect to Reader
  3. Enable Impinj Extensions
  4. Factory Default LLRP configuration to ensure that the reader is in a known state (since we are relying on the default reader configuration for this simple example)
  5. GET_READER_CAPABILITIES to learn the maximum power supported by this reader, as well as its regulatory region. Also, learn the model #
  6. GET_READER_CONFIG to learn the current channelIndex and hopTable
  7. SET_READER_CONFIG with the appropriate InventorySearchMode, LowDutyCycleMode, TransmitPower, and AutoSet values.
  8. ADD_ROSPEC to tell the reader to perform an inventory.
  9. ENABLE_ROSPEC
  10. START_ROSPEC start the inventory operation
  11. Process RFID Data (EPC, RSSI, Timestamp)

This program can be run with zero, one, or two verbose options (-v). no -v – Only prints the tag report and errors -v – Also prints one line progress messages -vv – Also prints all LLRP messages as XML text

Definition in file docsample2.cpp.

Function Documentation

◆ main()

int main ( int  ac,
char *  av[] 
)

Command main routine.

Command synopsis:

example1 [-v[v]] READERHOSTNAME

0 Everything seemed to work. 1 Bad usage 2 Run failed

Definition at line 206 of file docsample2.cpp.

References usage().

◆ usage()

void usage ( char *  pProgName)

Print usage message and exit.

Parameters
[in]nProgNameProgram name string
Returns
none, exits

Definition at line 288 of file docsample2.cpp.

References CAISpec::addInventoryParameterSpec(), CROSpec::addSpecParameter(), CGET_READER_CONFIG_RESPONSE::beginAntennaConfiguration(), CSET_READER_CONFIG::beginAntennaConfiguration(), CRO_ACCESS_REPORT::beginTagReportData(), LLRP::CConnection::closeConnectionToReader(), CGET_READER_CONFIG_RESPONSE::endAntennaConfiguration(), CSET_READER_CONFIG::endAntennaConfiguration(), CRO_ACCESS_REPORT::endTagReportData(), CUHFBandCapabilities::endTransmitPowerLevelTableEntry(), enrollImpinjTypesIntoRegistry(), CReaderEventNotificationData::getAntennaEvent(), CAntennaEvent::getAntennaID(), CRFTransmitter::getChannelIndex(), LLRP::CConnection::getConnectError(), CReaderEventNotificationData::getConnectionAttemptEvent(), CGeneralDeviceCapabilities::getDeviceManufacturerName(), CEPCData::getEPC(), CEPC_96::getEPC(), CTagReportData::getEPCParameter(), CLLRPStatus::getErrorDescription(), CAntennaEvent::getEventType(), CGET_READER_CAPABILITIES_RESPONSE::getGeneralDeviceCapabilities(), CRFTransmitter::getHopTableID(), CTransmitPowerLevelTableEntry::getIndex(), CIMPINJ_ENABLE_EXTENSIONS_RESPONSE::getLLRPStatus(), CGET_READER_CAPABILITIES_RESPONSE::getLLRPStatus(), CADD_ROSPEC_RESPONSE::getLLRPStatus(), CSTART_ROSPEC_RESPONSE::getLLRPStatus(), CSTOP_ROSPEC_RESPONSE::getLLRPStatus(), CENABLE_ROSPEC_RESPONSE::getLLRPStatus(), CGET_READER_CONFIG_RESPONSE::getLLRPStatus(), CSET_READER_CONFIG_RESPONSE::getLLRPStatus(), CReaderExceptionEvent::getMessage(), CGeneralDeviceCapabilities::getModelName(), CREADER_EVENT_NOTIFICATION::getReaderEventNotificationData(), CReaderEventNotificationData::getReaderExceptionEvent(), LLRP::CConnection::getRecvError(), CGET_READER_CAPABILITIES_RESPONSE::getRegulatoryCapabilities(), LLRP::CConnection::getSendError(), CConnectionAttemptEvent::getStatus(), CLLRPStatus::getStatusCode(), LLRP::CConnection::getTransactError(), CTransmitPowerLevelTableEntry::getTransmitPowerValue(), CRegulatoryCapabilities::getUHFBandCapabilities(), LLRP::llrp_u96_t::m_aValue, LLRP::CErrorDetails::m_eResultCode, LLRP::llrp_u1v_t::m_nBit, LLRP::llrp_utf8v_t::m_nValue, LLRP::CTypeDescriptor::m_pName, LLRP::CFieldDescriptor::m_pName, LLRP::CErrorDetails::m_pRefField, LLRP::CErrorDetails::m_pRefType, LLRP::CTypeDescriptor::m_pResponseType, LLRP::CElement::m_pType, LLRP::llrp_u16v_t::m_pValue, LLRP::llrp_u1v_t::m_pValue, LLRP::llrp_utf8v_t::m_pValue, LLRP::CErrorDetails::m_pWhatStr, LLRP::CConnection::openConnectionToReader(), LLRP::RC_OK, LLRP::RC_RecvTimeout, LLRP::CConnection::recvMessage(), LLRP::CConnection::sendMessage(), CAISpec::setAISpecStopTrigger(), CAISpecStopTrigger::setAISpecStopTriggerType(), CAISpec::setAntennaIDs(), CRFTransmitter::setChannelIndex(), CROSpec::setCurrentState(), CAISpecStopTrigger::setDurationTrigger(), CROSpecStopTrigger::setDurationTriggerValue(), CRFTransmitter::setHopTableID(), CInventoryParameterSpec::setInventoryParameterSpecID(), CROSpec::setPriority(), CInventoryParameterSpec::setProtocolID(), CGET_READER_CAPABILITIES::setRequestedData(), CGET_READER_CONFIG::setRequestedData(), CSET_READER_CONFIG::setResetToFactoryDefault(), CROSpec::setROBoundarySpec(), CADD_ROSPEC::setROSpec(), CSTART_ROSPEC::setROSpecID(), CSTOP_ROSPEC::setROSpecID(), CENABLE_ROSPEC::setROSpecID(), CROSpec::setROSpecID(), CROBoundarySpec::setROSpecStartTrigger(), CROSpecStartTrigger::setROSpecStartTriggerType(), CROBoundarySpec::setROSpecStopTrigger(), CROSpecStopTrigger::setROSpecStopTriggerType(), CRFTransmitter::setTransmitPower(), LLRP::CElement::toXMLString(), and LLRP::CConnection::transact().

Referenced by main().