COM port

This example demonstrate the ability of Avior to forward messages received from the network through the COM port (RJ45 connector) and viceversa.
This open the oppurtunity to connect an external device (such as PLC or other instrument).
The COM port must not already be in use for other purposes.

Configuration

To send and receive SMS, PLMN must be active and a valid SIM card inserted.
To send and receive emails the SMM server must be active and reachable through a WiFi or PLMN connection.

Users

No users.
But if you want you can restrict incoming messages to users only.

Rules

Rule 001 is triggered if a text is received from the console.
Condition: the text "sms" is received from the console.
An SMS is sent to specified phone number.

COMportSMS
↯ Test received from closed console
✛ Device - Last string from closed console = sms
✛
✛
✛
✛
> AT+SMS=+3922334455,"external device requested SMS"
>
>
>
>

Rule 002 is triggered if a text is received from the console.
Condition: the text "email" is received from the console.
An email is sent to specific address.

COMportEMAIL
↯ Test received from closed console
✛ Device - Last string from closed console = email
✛
✛
✛
✛
> AT#EMAIL=admin@email.com,"external device requested EMAIL"
>
>
>
>

Rule 003 triggered at any incoming SMS from unknown user.
No conditions are set.
Text of received SMS (N24) is forwarded to COM port.

ForwardSMS
↯ SMS from unknown
✛
✛
✛
✛
✛
> AT#COM=$N24
>
>
>
>

Rule 003 triggered at any incoming email message from unknown user.
No conditions are set.
Subject of received email (S10) is forwarded to COM port.

ForwardEmail
↯ Email from unknown
✛
✛
✛
✛
✛
> AT#COM=$S10
>
>
>
>