Configure and Command Tags
Tag configurations and temporary commands allow you to control the behaviour of the tags in your Quuppa system. Tag configurations define the standard operation of the tags in your project, for example, how often the tag transmits data and how quickly it changes between states. Temporary commands allow you to trigger certain behaviours in a tag for a certain time, for example blinking the tag LED when entering certain geofencing areas such as zones.
For most cases, the preliminary tag configurations and temporary commands will be set using the Quuppa Site Planner (QSP) during the project planning phase (for more information, please see the Tag Configurations section of the QSP User Manual). However, once your system is up and running, it is possible to apply these same tag configurations using the Quuppa API. This is done using the Quuppa BackChannel.
For the tags to be configurable remotely, they need to be active (i.e. in the Default, Triggered or Temporary state) and within the communication range of the Locators. Also, the desired configuration or temporary command needs to be saved into the project file using the QSP tool. The default options available in the QSP are 9Hz_for_30s (the tag transmits at 9Hz for 30 seconds) and QT1_LED_BLINK (triggers the tags LED to blink for 30 seconds). If needed, you can create your own temporary commands using the QSP's Temporary Command Editor.
localhost:8080/qpe/configureTag?tag=a4da22e080d3&id=ASSET_TAG&channel=37
.Apply Tag Configurations
Tag Configurations allow you to define the behaviour of the tags in your project. To apply tag configurations remotely using the QPE, follow these steps:
- Check that the QPE is running in tracking mode. For example by using the
Get Positioning Engine Information API request.
/gpe/getPEInfo?humanReadable=true
- Edit the Configure Tag API request URL to include the
data fields that are relevant.
/qpe/configureTag?id=configuration[&mode=mode][&tag=tag1,...,tagn][&group=groupid][&time=retryTimeMs][&channel=channel]
Check the available parameters from the API Documentation (available via the QPE Web Console or the Quuppa Customer Portal's Downloads section) as needed.
For example, to configure a tag with the ID a4da22e080d3 into an ASSET_TAG using the BLE channel, edit the request as follows:
/qpe/configureTag?tag=a4da22e080d3&id=ASSET_TAG&channel=37
. - Send the request to the QPE using the edited URL.
- The response to this method only informs whether the command request was
accepted by the QPE or not. For example:
{ "commanded":["a4da22e080d3"], "code":0, "responseTS":1610980253741, "message":"Commanding 1 tag(s), skipped 0 Tag(s)", "version":"1.0", "command":"http://localhost:8080/qpe/configureTag?tag=a4da22e080d3&id=ASSET_TAG&channel=37", "status":"Ok" }
- The desired configuration will be applied. For example, the tag will behave according to the configurations set of ASSET_TAG and operate on the BLE channel.
Apply Temporary Commands
Temporary commands allow you to trigger certain behaviours in a tag for a defined duration. To apply temporary command using the Positioning Engine Web Console, follow these steps:
- Check that the QPE is running in tracking mode. For example by using the
Get Positioning Engine Information API request.
/gpe/getPEInfo?humanReadable=true
- Edit the Command Tag API request URL to include the data
fields that are relevant.
/qpe/commandTag?tag=tag_1,...,tag_n&id=commandId[&time=timeOutMs]
Check the available parameters from the API Documentation (available via the QPE Web Console or the Quuppa Customer Portal's Downloads section) as needed.
For example, the apply the temporary command QT1_LED_BLINK for a tag with the ID a4da22e080d3, edit the request as follows:
/qpe/commandTag?tag=a4da22e080d3&id=QT1_LED_BLINK
. - The response to this method only informs whether the temporary command request
was accepted by the QPE or not. For example:
{ "commanded":["a4da22e080d3"], "code":0, "responseTS":1610979781740, "message":"Commanding 1 Tag(s), skipped 0 Tag(s)", "version":"1.0", "command":"http://localhost:8080/qpe/commandTag?tag=a4da22e080d3&id=QT1_LED_BLINK", "status":"Ok" }
- The desired temporary command will be initiated. For example, the tag's LED will blink for 30 seconds.