public class RFIDWithUHFA4 extends RFIDWithUHFAxBase_qcom implements IRFIDWithUHFA4, IUHFOfAndroidUart
init(Context context) 连接读写器。init(Context context)setInventoryCallback(IUHFInventoryCallback inventoryCallback)设置标签回调接口,有标签数据就会回调这个接口。
然后在调用startInventoryTag()函数开始执行盘点。
注意: 在盘点标签的时候rfid模块只能响应stopInventory()函数。setInventoryCallback(IUHFInventoryCallback inventoryCallback) first to set the label callback interface, this interface will be called back when there is label data.
* Then call the startInventoryTag() function to start the inventory.
* Note: The rfid module can only respond to the stopInventory() function when inventorying tags.free()断开连接,如果断开之前正在盘点,请先停止盘点,在断开连接。free() to disconnect. If you are taking inventory before disconnecting, please stop the inventory first and then disconnecting.UhfBase.ErrorCodeBank_EPC, Bank_RESERVED, Bank_TID, Bank_USER, LockBank_ACCESS, LockBank_EPC, LockBank_KILL, LockBank_TID, LockBank_USER, LockMode_LOCK, LockMode_OPEN, LockMode_PLOCK, LockMode_POPEN, UPDATE_UHF| Modifier and Type | Method and Description |
|---|---|
void |
buzzer()
成功的通知提示(发出提示音)
Success Notification Sound (Play Sound) |
boolean |
free()
关闭UHF模块
Switch off UHF module |
java.util.List<AntennaState> |
getANT()
获取当前设置的天线
Acquire current antenna |
static RFIDWithUHFA4 |
getInstance() |
boolean |
init()
初始化UHF模块,适应所有模块
Initialize UHF module(Support all modules) |
boolean |
init(Context context)
初始化UHF模块
|
java.util.List<GPIStateEntity> |
inputStatus()
input status
|
void |
led()
成功的通知提示(指示灯闪烁)
Success Notification Sound (flashing light) |
boolean |
output1Off()
gpio 3 off
|
boolean |
output1On()
gpio 3 on
|
boolean |
output2Off()
gpio 4 off
|
boolean |
output2On()
gpio 4 on
|
boolean |
output3Off()
gpio OptoCoupler3 off
|
boolean |
output3On()
gpio OptoCoupler3 on
|
boolean |
output4Off()
gpio OptoCoupler4 off
|
boolean |
output4On()
gpio OptoCoupler4 on
|
boolean |
outputWgData0Off()
gpio WgData0 off
|
boolean |
outputWgData0On()
gpio WgData0 on
|
boolean |
outputWgData1Off()
gpio WgData1 off
|
boolean |
outputWgData1On()
gpio WgData1 on
|
boolean |
setANT(java.util.List<AntennaState> antStatus)
设置天线号
Setup antenna number |
void |
setInventoryCallback(IUHFInventoryCallback inventoryCallback)
设置盘点回调接口,接收循环盘点到的标签数据
Set the inventory callback interface to receive the label data from the cyclic inventory 备注:需要在开始循环盘点 IUHF.startInventoryTag()之前调用此方法。Note: This method needs to be called before starting the loop inventory IUHF.startInventoryTag(). |
boolean |
startInventoryTag()
开始循环识别标签。
|
boolean |
stopInventory()
停止循环识别,在调用此函数之后应当退出循环获取缓冲区的标签信息的子线程
Stop auto reading, after call this function to exit sub threads of tag data of buffer. |
void |
successNotify()
成功的通知提示(指示灯闪烁同时发出提示音)
Success Notification Sound (Play notification tune when light flashing) |
buzzerOn, getAntennaConnectState, getAntennaPower, getAntennaPower, init_R2000, readTagFromBuffer, readTcpServiceState, setAntennaPowerblockWriteData, eraseData, eraseData, generateLockCode, getConnectStatus, getCW, getEPCAndTIDUserMode, getEPCAndTIDUserModeEx, getErrCode, getFrequencyMode, getGen2, getHardwareVersion, getPower, getProtocol, getRFLink, getTemperature, getVersion, inventorySingleTag, isInventorying, isPowerOn, killTag, killTag, lockMem, lockMem, readData, readData, setConnectionStatusCallback, setCW, setEPCAndTIDMode, setEPCAndTIDUserMode, setEPCAndTIDUserModeEx, setEPCAndUserReservedModeEx, setEPCMode, setFastID, setFilter, setFreHop, setFrequencyMode, setGen2, setGen2, setPower, setPowerOnBySystem, setPowerOnDynamic, setProtocol, setRFLink, setTagFocus, setUart, startInventoryTag, startInventoryTag, startLocation, startRadarLocation, stopLocation, stopRadarLocation, uhfBlockPermalock, uhfJump2Boot, uhfJump2Boot, uhfStartUpdate, uhfStopUpdate, uhfUpdating, UHFVerifyVoltage, writeData, writeData, writeDataToEpc, writeDataToEpcequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAntennaPower, getAntennaPower, setAntennaPowergetErrCode, getHardwareVersion, init_R2000, isPowerOn, setEPCAndUserReservedModeEx, setPowerOnBySystem, setUartblockWriteData, eraseData, eraseData, generateLockCode, getConnectStatus, getCW, getEPCAndTIDUserMode, getFrequencyMode, getGen2, getProtocol, getRFLink, getTemperature, getVersion, inventorySingleTag, isInventorying, killTag, killTag, lockMem, lockMem, readData, readData, readTagFromBuffer, setConnectionStatusCallback, setCW, setEPCAndTIDMode, setEPCAndTIDUserMode, setEPCMode, setFastID, setFilter, setFreHop, setFrequencyMode, setGen2, setProtocol, setRFLink, setTagFocus, uhfBlockPermalock, uhfJump2Boot, uhfJump2Boot, uhfStartUpdate, uhfStopUpdate, uhfUpdating, writeData, writeData, writeDataToEpc, writeDataToEpcpublic static RFIDWithUHFA4 getInstance() throws ConfigurationException
ConfigurationExceptionpublic boolean init()
RFIDWithUHFUART_qcominit in class RFIDWithUHFAxBase_qcompublic boolean init(Context context)
RFIDWithUHFUART_qcom初始化UHF模块
Initialize UHF module
init in interface IUHFinit in class RFIDWithUHFAxBase_qcomcontext - contextpublic boolean free()
RFIDWithUHFUART_qcomfree in interface IUHFfree in class RFIDWithUHFAxBase_qcompublic boolean startInventoryTag()
开始循环识别标签。
Begin looping through the identification labels.
通过 setInventoryCallback(IUHFInventoryCallback inventoryCallback) 这个回调接口获取标签数据,需要在开始盘点之前调用setInventoryCallback方法。
Get the label data through the callback interface setInventoryCallback(IUHFInventoryCallback inventoryCallback), you need to call the setInventoryCallback method before starting the inventory.
备注:开启循环识别标签后模块只能响应stopInventory()函数 。
Note: The module can only respond to the stopInventory() function after the loop identification tag is turned on.
startInventoryTag in interface IUHFstartInventoryTag in class RFIDWithUHFAxBase_qcompublic boolean stopInventory()
IUHFstopInventory in interface IUHFstopInventory in class RFIDWithUHFUART_qcompublic void setInventoryCallback(IUHFInventoryCallback inventoryCallback)
IUHFIUHF.startInventoryTag()之前调用此方法。IUHF.startInventoryTag().setInventoryCallback in interface IUHFsetInventoryCallback in class RFIDWithUHFUART_qcominventoryCallback - 盘点回调接口(inventory callback interface)public java.util.List<AntennaState> getANT()
getANT in interface IMultipleAntennagetANT in class RFIDWithUHFAxBase_qcompublic boolean setANT(java.util.List<AntennaState> antStatus)
setANT in interface IMultipleAntennasetANT in class RFIDWithUHFAxBase_qcomantStatus - 下标索引加1表示天线号;下标元素的值如果是1表示设置该天线,0反之;(Return antenna status that has been setup, index will display antenna number.)public boolean output2Off()
output2Off in interface IRFIDWithUHFA4public boolean output2On()
output2On in interface IRFIDWithUHFA4public boolean output1Off()
output1Off in interface IRFIDWithUHFA4public boolean output1On()
output1On in interface IRFIDWithUHFA4public java.util.List<GPIStateEntity> inputStatus()
inputStatus in interface IRFIDWithUHFA4public boolean output3On()
output3On in interface IRFIDWithUHFA4public boolean output3Off()
output3Off in interface IRFIDWithUHFA4public boolean output4On()
output4On in interface IRFIDWithUHFA4public boolean output4Off()
output4Off in interface IRFIDWithUHFA4public boolean outputWgData0On()
outputWgData0On in interface IRFIDWithUHFA4public boolean outputWgData0Off()
outputWgData0Off in interface IRFIDWithUHFA4public boolean outputWgData1On()
outputWgData1On in interface IRFIDWithUHFA4public boolean outputWgData1Off()
outputWgData1Off in interface IRFIDWithUHFA4public void successNotify()
successNotify in interface IURAxOfAndroidUartsuccessNotify in class RFIDWithUHFAxBase_qcompublic void led()
led in interface IURAxOfAndroidUartled in class RFIDWithUHFAxBase_qcompublic void buzzer()
buzzer in interface IURAxOfAndroidUartbuzzer in class RFIDWithUHFAxBase_qcom