Introduction: This paper will take TDA-04D8 transmitter as the acquisition object, use Haichuang micro-link acquisition and control system to collect TDA-04D8 transmitter, and then upload the data collection of gross weight, net weight and tare weight on the equipment to Ali Cloud Iot platform, which will real-time visualization of data.

The article is divided into three parts:

  • Tda-04d8 transmitter configuration

  • This section describes how to configure hardware parameters and cable connections.

  • The data collection

  • Control deployment and data acquisition are carried out by using haichuang Microlink acquisition and control system.

  • Data upload

  • Alibaba Cloud platform Creation and data visualization of products and devices on the Internet of Things platform.

A TDA-04D8 transmitter configuration

1.1 Product Appearance

1.2 Keys on the PANEL of the HANDHELD Terminal

1.3 Setting Serial Port Communication Parameters (RS485&RS232)

Set the baud rate of TDA-04D8 transmitter to 9600 and the mailing address to 1.

1.4 Connecting Devices

This case uses RS485 wiring to connect TDA-04D8 transmitter to the 485 serial port of Haicuang Edge gateway equipment, and then collects gross weight, net weight and tare weight data on haicuang micro-link acquisition and control system through Ethernet communication. The terminal description of TDA-04D8 transmitter is as follows:

Ii. Data Collection

Enter the Acquisition and control system of Haichuang Microlink, and select Modbus control, timer, Ali Cloud IOT and debugger in sequence from the acquisition engine on the left. The connection is shown as follows:

Modbus configuration is as follows, the protocol type is moudbus-serial, and the Serial port is configured according to the Serial port connected to the haituangmicro-link edge Gateway box. Now we are connected to the second port, the Serial port configuration is /dev/ttys1, the communication mode is RTU-bffered, and the baud rate is 9600. Unit ID address 1.

If the function code is FC3, add three collection quantities, namely T80 (gross weight), T82 (net weight) and T84 (tare weight). For the function code, unit ID, collection address and algorithm, you need to refer to the instruction of the device.

The timer is configured to send a request every 10 seconds.

After the configuration, click Deploy.

The T80, T82, and T84 collected every 10 seconds are displayed on the debugging screen.

The T80, T82 and T84 values of TDA-04D8 transmitter are collected successfully.

3 Data Upload

Alicloud Iot platform can interact with Haichuang micro-connected acquisition and control system to visualize the collected data.

3.1 Product Creation

Log in to Aliyun iot platform, choose Device Management > Product in the left navigation bar, and click Create Product.

On the New Product TAB page, set the parameters as prompted, and click OK.

3.2 Device Creation

In the navigation tree, choose Device Management > Device. On the Device page, click Add device.

In the add device dialog box, enter device information and click CONFIRM.

Return to Choose Device Management > Device to view device details.

3.3 Definition of collection quantity

To go back to the product you just created, in the feature definition, click Edit Draft.

Click Add Custom features.

Note: The identifier must match the field in the debug window.

Create the data identifier that needs to be uploaded to the cloud in the function definition, and click “Publish online” in the lower left corner after creation.

Go back to view the created device, click the view button in the following figure, and copy the three identifiers of the device, namely ProductKey (product id), DeviceKey (device id), and DeviceSecret (DeviceKey).

3.4 Data Visualization

Go to haichuang Micro-link acquisition and control system and enter 3 unique identifiers in Ali Cloud IOT.

Click Deploy, alibaba Cloud IOT connection is successful.

Back to Alibaba Cloud iot platform, device display online.

T80 (gross weight), T82 (net weight) and T84 (tare weight) are displayed in real time in the object model data of the equipment, and the data is collected successfully.

The original link

This article is the original content of Aliyun and shall not be reproduced without permission.