GL DEV BOARD¶
In order to give users a more intuitive experience of the thread network functions, we have developed a set of Thread development boards. The GL DEV BOARD is a page dedicated to controlling the Thread development board for GL development and displaying relevant data.
The TDB(GL Thread DEV Board) can join the network by using thread Commissioning, but you need to know the EUI64 of the TDB and the device pre-shared key PSKd. To simplify the configuration process, we have pre-built fixed keys in the firmware, which can be added quickly as follows.
Add TDB to the network¶
Click on Add Devices.
Click on Allow New Devices To Join and Click on Apply.
Power up the TDB, press and hold SW2 for three seconds or more to restore the factory settings, then press SW2 briefly. You can see the green light flashing.
When the green light of the development board is always on, it means that it successfully joins the network.
The first time a device is successfully added, the web page will automatically pop up New Devices to prompt for configuration Type/Name information
- Type: If theTDB comes with an A0 board, please select "A0+A1".
- Name: User defined names.
You can see that the development board was successfully added to the Online card.
You can view the current data of the TDB on the Device Detail page.
You can view a graph of the TDB's historical data on the View Records page.
You can edit the settings of the TDB on the Edit Device page.
We have prepared some sample code to control the TDB. You can run them in the S200 backend, or write your own applications by referring to these examples.
If you want to remove the TDB from the network, use the reset device function.
Note: This will restore the TDB to its factory settings.
To enable users to better test the thread network in real-life situations, we offer some simple, restricted device linkage functions.
Add an automation with device action¶
As an example, create an automation example: press a button on either board and the RGB lights on/off on both boards.
Create a name
Select type of trigger conditions
Select the device(s) to be used as an trigger.
Select trigger conditions
Select the type of operation
Select the device(s) to be used as an actuator
Select actuator's actions
You can see the automation cards that have been created.
Add an automation with webhook¶
A webhook in web development is a method of augmenting or altering the behavior of a web page or web application with custom callbacks.
As an example, I need TDB for home security alarms. When someone enters, send a message to Discord via webhook.
Create a webhook url from Discord
Please refer to the official Discord documentation. Please copy the url of the webhook, the next steps need to use.
Fellow the steps below to create an automation.
Give it a name for the automation.
Select Sensor trigger.
Select trigger condition.
Paste the url you got when you created the webhook.
Enter the message you wish to send to Discord. Discord specifies that the message sent provide a value for at least one of content, embeds, components, or file.
Note: Different Internet applications have their own definitions for the content and format of messages, please refer to the relevant documentation.
Finally, an Automation that triggers the webhook is successfully created.
When the TDB's pyroelectric infrared sensor is triggered, the GL-S200 sends the specified message to the webhook that is set up.
Still have questions? Visit our Community Forum.