Members
(static) LockUnlockMaskAndAction
Definitions for value passed to lockUnlockTag choosing what banks to change the locked status for and what to change them to
- Source:
(static) NO_PASSWORD
Tag does not need a password
- Source:
(static, readonly) TagAccessReturnValues :Number
Values returned by programTag, writeTag, lockUnlockTag and readTag
Type:
- Number
Properties:
Name | Type | Description |
---|---|---|
OK |
Number | Access was successful |
WRONG_PASSWORD |
Number | Incorrect password passed |
PASSWORD_REQUIRED |
Number | No password passed, but a password is required |
MEMORY_OVERRUN |
Number | Read/write to a memory locaion that does not exist on tht tag |
TAG_NOT_FOUND |
Number | Tag not found |
GENERAL_ERROR |
Number | General error |
INVENTORY_STOPPED |
Number | Inventory stopped |
REQUIRES_AUTHENTICATION |
Number | Grokker must be authenticated |
- Source:
(readonly) isPaused :Boolean
True if inventory is temporarily stopped
Type:
- Boolean
- Source:
(readonly) isScanning :Boolean
True if inventory is actively scanning
Type:
- Boolean
- Source:
(readonly) startTime :Date
Time the inventory was started
Type:
- Date
- Source:
tagsByEpc
Map of EPCs to tags
- Source:
Methods
changePower(initialPowerLevel, minPowerLevel, maxPowerLevel, completion)
Change power
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
initialPowerLevel |
Initial power level | |
minPowerLevel |
Minimum power level | |
maxPowerLevel |
Maximum power level | |
completion |
Completion code after the custom command is executed |
- Source:
customCommandToTag(epc, command, commandBits, responseBitLengthNoHeaderBit, responseBitLengthWithHeaderBit, receiveTimeoutUsec, completion)
Send a custom command to a tag
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
epc |
EPC of tag to read | |
command |
Command bytes to send | |
commandBits |
Number of command bits to send | |
responseBitLengthNoHeaderBit |
Number of response bits to expect, if header bit is not set in the response | |
responseBitLengthWithHeaderBit |
Number of response bits to expect, if header bit is set in the response (if 0 then do not expect a header bit at all) | |
receiveTimeoutUsec |
Response timeout in uSec (some tags require more than the standard for custom commands) | |
completion |
Completion code after the custom command is executed |
- Source:
getBatteryInfo(successCallback)
Get battery information
Parameters:
Name | Type | Description |
---|---|---|
successCallback |
Called with one parameter of type UgiBatteryInfo |
- Source:
killTag(epc, password, completion)
Kill a tag
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
epc |
EPC of tag to kill | |
password |
Kill password | |
completion |
Completion code after tag is killed |
- Source:
lockUnlockTag(epc, maskAndAction, password, completion)
Lock/unlock a tag
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
epc |
EPC of tag to lock/unlock | |
maskAndAction |
Description for which protection bits to change and what to change them to (UgiLockUnlockMaskAndAction) | |
password |
Password to use (UGI_NO_PASSWORD for not password protected) | |
completion |
Completion code after tag is locked/unlocked |
- Source:
pauseInventory()
Stop running inventory temporarily (such as while a dialog box is displayed)
- Source:
programTag(oldEpc, newEpc, password, completion)
Program a tag.
This must be called while inventory is running.
The delegate object is informed of the success or failure of the programming.
Parameters:
Name | Type | Description |
---|---|---|
oldEpc |
EPC of tag to change (string of hex digits) | |
newEpc |
EPC to write to the tag (string of hex digits) | |
password |
Password to use (UGI_NO_PASSWORD for not password protected) | |
completion |
Completion code after tag is written |
- Source:
readTag(epc, memoryBank, offset, minNumBytes, maxNumBytes, completion, password)
Read a tag
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
epc |
EPC of tag to read | |
memoryBank |
Memory bank to read | |
offset |
Byte offset to read at (must be a multiple of 2) | |
minNumBytes |
Minimum number of bytes to read (must be a multiple of 2) | |
maxNumBytes |
Maximum number of bytes to read (must be a multiple of 2) | |
completion |
Completion code after tag is read | |
password |
Password to use (UGI_NO_PASSWORD for not password protected), only relavant for the ACESS and KILL passwords. Password is only supported in Grokkers with firmware 1.12.2 and above |
- Source:
resumeInventory()
Restart inventory after a temporarily stop
- Source:
stopInventory()
Stop running inventory
- Source:
writeTag(epc, memoryBank, offset, data, previousData, password, completion)
Write memory.
This must be called while inventory is running. This method call returns immediately,
the completion is called when the operation is finished
Parameters:
Name | Type | Description |
---|---|---|
epc |
EPC of tag to write to (string of hex digits) | |
memoryBank |
Memory bank to write to (Ugi.MemoryBanks.xxx) | |
offset |
Byte offset to write at (must be a multiple of 2) | |
data |
Data to write (hex string) | |
previousData |
Previous value for this data (hex string), or null if unknown or not available | |
password |
Password to use (UGI_NO_PASSWORD for not password protected) | |
completion |
Completion code after tag is written |
- Source: