How to send SMS
Sending SMS dialogue
To send an SMS, the following must be configured:
- At least one system device (device type: Advantech router) with working SIM card must be present.
- Authentication profile with valid certificates must be defined and assigned to that device.
For documentation on how to configure the above points please refer below. As for sending the SMS itself, there are basically two use cases covered:
- Sending Configuration SMS to Advantech router device.
- To target the device, it must have a SIM card inserted and the MSISDN of that SIM card must be known.
- Sending SMS with arbitrary text to any MSISDN.
Both use cases are covered by the Send SMS dialogue. To send SMS you need:
- Select SMS type (any of the supported configuration SMSes or arbitrary text SMS).
- (Optional) specify SMS text if arbitrary text SMS has been selected.
- Select target
- Device ID (for configuration SMS) - NOTE it must have a SIM card inserted and MSISDN of this SIM card must be filled.
- MSISDN - you can provide any MSISDN as target.
- Select system device, to which an SSH connection is opened and where the SMS sending command is executed.
Configuration elements
System Device
The system device needs to be an Advantech router and to send an SMS it must be reachable from the DWARFG_LONG server so that the server can connect via SSH to that device.
Once you have such device ready (the DWARFG_LONG agent is running on the device), assign the system label sms to that device. You can do that in the Device Details.
Authentication Profile
Next you need to provide credentials to access the chosen device. If you don't have a suitable Authentication Profile, you need to create one:
-
Go to Tools -> Auth Management You need to provide either SSH password or SSH key together with a username to an account on the device that is allowed to execute the SMS command (Command: sms on Advantech cellular routers).
-
Click on + Add Auth Profile button.
-
Choose some Name that is descriptive enough so that later on you recognize the purpose of this profile.
-
As for username, you need some user that is allowed to send SMS on the Router device. For Advantech routers, that is typically the root user.
-
You need to provide only one of SSH Password and SSH Key. This will be used when connecting to the router device via ssh to execute the sms sending command (sms for Advantech routers).
Once the proper Authentication Profile is available, assign the profile to the selected system device in its Device Details under Auth Profile
Connection Interface
The system needs to recognize which of the router Network Interfaces should it connect to - more in general, which IP address out of all the Router IP addresses is the one it should connect to using SSH.
-
Go to Device Details of the system device.
-
Under Network Interfaces, select exaclty one of the interfaces as Linkable
-
Confirm by clicking Update Settings under the table.