User Tools

Site Tools


wiki:interfaces:smsma

This is an old revision of the document!


Table of Contents

SMS interface

Introduction

  • Manage end-devices fleet
  • Manage gateway fleet
  • Receive frames from end-devices
  • Send frames to end-devices
  • Configure the gateway
  • Add license

Its configuration is available in Configuration ⇒ Interfaces ⇒ SMS utils menu.

SMS utils

Help

Inline help is available in web user interface in Configuration ⇒ Interfaces ⇒ SMS utils ⇒ Help.

An extract of this help is available below:

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

Help
# Common parameters
 
## SMS request
 
```
[spn:spnpwd] [cmdid1] flow/command
```
 
- *spn:* SPN user, always *spn*.
- *spnpwd:* SPN password.
- *cmdid1:* command identifier used for response. Must be alphanumeric characters in lower case, 6 digits.
- *flow:* group of command (*end_device*, *gateway*, *rx_data*, *tx_data*, *configuration*, *update* or *status*).
- *command:* command to run, depending on *flow*.
 
## SMS answer
 
**Correct request:**
```
[cmdid1:ok] answer
```
 - *cmdid1:* command identifier passed in request.
 - *answer:* the answer of the request, format depends on the request.
 
**Not correct request:**
```
[cmdid1:error] error message
```
- *cmdid1:* command identifier passed in request.
- *error message:* error message indicating what goes wrong.
 
# Flow syntax
 
## End-device fleet flow
 
**Add ABP end-device:**
```
[spn:spnpwd] [endadd] end_device/add_end_device end_device_csv
```
- *end_device_csv:* syntax is described through **DOWNLOAD** button.
 
Example:
```
[spn:spnpwd] [endadd] end_device/add_end_device ABP,C,,,,11223344,11112222333344445555666677778888,11112222333344445555666677778888,255,869525000,0
```
 
**Add OTAA end-device:**
```
[spn:spnpwd] [endadd] end_device/add_end_device end_device_csv
```
- *end_device_csv:* syntax is described through **DOWNLOAD** button.
 
Example:
```
[spn:spnpwd] [endadd] end_device/add_end_device OTAA,C,1122334455667788,1122334455667788,11112222333344445555666677778888,,,,255,869525000,0
```
 
**Delete ABP end-device:**
```
[spn:spnpwd] [enddel] end_device/delete_end_device dev_addr
```
- *dev_addr:* ABP device address (8 hexadecimal digits in upper case).
 
Example:
```
[spn:spnpwd] [enddel] end_device/delete_end_device 11223344
```
 
**Delete OTAA end-device:**
```
[spn:spnpwd] [enddel] end_device/delete_end_device dev_eui
```
- *dev_eui:* OTAA device EUI (16 hexadecimal digits in upper case).
 
Example:
```
[spn:spnpwd] [enddel] end_device/delete_end_device 1122334455667788
```
 
**Delete end-device fleet:**
```
[spn:spnpwd] [enddef] end_device/delete_fleet
```
 
## Gateway fleet flow
 
**Add gateway:**
```
[spn:spnpwd] [gatadd] gateway/add_gateway gateway_csv
```
- *gateway_csv:* syntax is described through **DOWNLOAD** button.
 
Example:
```
[spn:spnpwd] [gatadd] gateway/add_gateway 7276FF0039020003
```
 
**Delete gateway:**
```
[spn:spnpwd] [gatdel] gateway/delete_gateway gateway_id
```
- *gateway_id:* gateway identifier  (16 hexadecimal digits in upper case).
 
Example:
```
[spn:spnpwd] [gatdel] gateway/delete_gateway 7276FF0039020003
```
**Delete gateway fleet:**
```
[spn:spnpwd] [gatdef] gateway/delete_fleet
```
 
## Rx data flow
 
**Get Rx data from ABP end-device:**
```
[spn:spnpwd] [rxdget] rx_data/get_rx_data dev_addr
```
- *dev_addr:* ABP device address (8 hexadecimal digits in upper case).
 
Example:
```
[spn:spnpwd] [rxdget] rx_data/get_rx_data 11223344
```
SMS answer contains Rx data in CSV, syntax is described though this **DOWNLOAD** button.
 
**Get Rx data from OTAA end-device:**
```
[spn:spnpwd] [rxdget] rx_data/get_rx_data dev_eui
```
- *dev_eui:* OTAA device EUI (16 hexadecimal digits in upper case).
 
Example:
```
[spn:spnpwd] [rxdget] rx_data/get_rx_data 1122334455667788
```
SMS answer contains Rx data in CSV, syntax is described though this **DOWNLOAD** button.
 
## Tx data flow
 
**Add Tx data to ABP or OTAA end-device:**
```
[spn:spnpwd] [txdadd] tx_data/add_tx_data tx_data_csv
```
- *tx_data_csv:* syntax is described through **DOWNLOAD** button.
 
Example:
```
[spn:spnpwd] [txdadd] tx_data/add_tx_data 11223344,2,true,5,MDAyN2JkMDlkMGZlOWMzYTAwMDAwMDAwMDAwMGZmZmY=
```
 
## Configuration flow
 
 
> Whole configuration is described through **DOWNLOAD** button.
 
Sample of configuration file:
```
{
  "body": {
    "public": {
      "loftp": {
        "enable": false
      }
    }
  }
}
```
> In this sample, parameter path is *loftp.enable*.
 
**Get parameter:**
```
[spn:spnpwd] [conget] configuration/get_value parameter_path
```
- *parameter_path:* parameter path.
 
Example:
```
[spn:spnpwd] [conget] configuration/get_value loftp.enable
```
 
**Set boolean parameter:**
```
[spn:spnpwd] [coset1] configuration/set_value boolean_parameter_path value
```
- *boolean_parameter_path:* boolean parameter path.
- *value:* *true* of *false*.
 
Example:
```
[spn:spnpwd] [coset1] configuration/set_value loftp.enable true
```
 
**Set number parameter:**
```
[spn:spnpwd] [coset2] configuration/set_value number_parameter_path value
```
- *number_parameter_path:* number parameter path.
- *value:* a number.
 
Example:
```
[spn:spnpwd] [coset2] configuration/set_value csvlo.rotation_count 55
```
 
**Set string parameter**
```
[spn:spnpwd] [coset3] configuration/set_value string_parameter_path value
```
- *string_parameter_path:* string parameter path.
- *value:* a string in double quotes.
 
Example:
```
[spn:spnpwd] [coset3] configuration/set_value csvlo.rotation_time "hour"
```
 
**Reset configuration:**
```
[spn:spnpwd] [conres] configuration/reset_configuration
```
 
## Update flow
 
**Add license:**
```
[spn:spnpwd] [updadd] update/add_license license_content
```
- *license_content:* content of license file provided.
 
Example:
 
```
[spn:spnpwd] [updadd] update/add_license -----BEGIN SIGNATURE-----
smzmFH2J/tRteB62kkush427wKKE/ahM1ojCZukDlE2lGrR28QxPtKlBhoR9p0nc
wm8uk1xFBlgj+x/1TmkxaRIkXJkQTqkUbvzsoe4omcPvgfjfTu3FiAiN3NkixCHw
h6ehOilCNQvCiKTe8kWaO/Bx+jX+Pt4kmdpTMMch02dxisCNobAqPbzRq31ElH81
aa9nUgrcA4iqett5AowAcKfIPHIo6hTHvlGnmOhA7vN7IN9vdgtvTDEFclwxfbmU
PqmqOVlXHfaaLV/Crn/R7wfkKjOPmEp3vaK0u2GkELzw0sQUzpkEMhJF2sN67ovd
tDFUCNi54R5ziCmLMvko2A==
-----END SIGNATURE-----
-----BEGIN LICENSE-----
[license]
hardware_serial_number = 3903001D
expiration_date = 1540123200
gateways_max_number = 10
end_devices_max_number = 0
-----END LICENSE-----
```
 
**Restore:**
```
[spn:spnpwd] [updres] update/restore
```
 
**Reboot:**
```
[spn:spnpwd] [updreb] update/reboot
```
 
**Halt:**
```
[spn:spnpwd] [updhal] update/halt
```
 
## Status flow
 
**Get status:**
```
[spn:spnpwd] [staget] status/get_status
```
SMS answer contains status in CSV, syntax is described though this **DOWNLOAD** button.
wiki/interfaces/smsma.1601026857.txt.gz · Last modified: 2020/09/25 11:40 by hch