ADTRAN 7310-8 Getting Started Manual page 24

Lorawan gateway with aws iot core
Hide thumbs Also See for 7310-8:
Table of Contents

Advertisement

To add a new rule to send an Amazon SNS notification when certain conditions are met in a decoded message,
follow these steps:
Navigate to the
1.
In the navigation pane, choose Act. Then, choose Rules.
2.
On the Rules page, choose Create.
3.
Enter the Name as text_alert, and provide an appropriate Description.
4.
Under Rule query statement, enter the following query:
5.
SELECT DevEUI as device_id, "Temperature exceeded 80" as message,
Alert_Temp as temp, Humidity as humidity, Timestamp as time FROM
'project/sensor/decoded' where Alert_Temp > 80
Choose Add action.
6.
Choose Send a message as an SNS push notification.
7.
Choose Configure action.
8.
Under SNS target, select text_topic from the drop-down.
9.
Select RAW under Message format.
10.
Under Choose or create a role to grant AWS IoT access to perform this action, choose Create role.
11.
Enter a name for the role and choose Add action.
12.
Choose Create rule. You should see a "Success" message, indicating that the rule has been created.
13.
8.5 Configuring IoT Analytics
We will use IoT Analytics to visually display data via graphs if there is a need in the future to do further analysis. To
configure IoT analytics, you will need to create an IoT analytics rule, configure AWS IoT analytics, and configure
Amazon QuickSight. The steps required to perform this configuration are provided in the following sections.
8.5.1 Creating an IoT Analytics Rule
To create an IoT analytics rule, follow these steps:
Navigate to the
1.
In the navigation pane, choose Act. Then, choose Rules.
2.
On the Rules page, choose Create.
3.
Enter the Name as Visualize, and provide an appropriate Description.
4.
Under Rule query statement, enter the following query:
5.
SELECT * FROM 'project/sensor/decoded'
Choose Add action.
6.
Select Send a message to IoT Analytics.
7.
Choose Configure Action.
8.
Choose Quick Create IoT Analytics Resources.
9.
Under Resource Prefix, enter an appropriate prefix for your resources, such as LoRa.
10.
Choose Quick Create.
11.
Once the Quick Create Finished message is displayed, choose Add action.
12.
Choose Create rule. You should see a "Success" message, indicating that the rule has been created.
13.
8.5.2 Configuring AWS IoT Analytics
To configure AWS IoT Analytics, follow these steps:
Go to the
AWS IoT Analytics
1.
In the navigation panel, choose Data sets.
2.
Select the data set that was generated by the Quick Create in
3.
In the Details section, Edit the SQL query.
4.
Replace the query with:
5.
select Alert_Temp as temp, Humidity as humidity, DevEUI as device_id,
Timestamp as time from LoRa_datastore
Under Schedule, choose Add schedule.
6.
© 2020, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS IoT
console.
AWS IoT
console.
console.
Creating an IoT Analytics
Rule.

Advertisement

Table of Contents
loading

Table of Contents