Updated on 2022-02-24 GMT+08:00

Device Testing

Overview

Online test supports device simulation and application simulation. It offers scenarios such as data reporting and command delivery to test devices, profiles, and plug-ins.

Developers can use physical or virtual devices for online test.

  • When the device development is complete but the application development is not, developers can add physical devices and use the application simulator to test devices, profiles, and plug-ins. The structure of physical device testing interface is as follows:

  • When both device development and application development are not completed, developers can create virtual devices and use the application simulator and device simulator to test profiles and plug-ins. The structure of virtual device testing interface is as follows:

Using a Physical Device for Online Test

  1. In the product development space, click Perform Online Test.

  2. Click Add at the row where Device List resides.

  3. In the Add Test Device dialog box displayed, select Yes, set the parameters, and click OK.

    • Device Name can contain only letters, digits, and underlines (_) and must be unique in the product.
    • Device Indentity must be set to a unique value, such as the IMEI or MAC address of the device.
    • Choose Unencrypt or Encrypt based on site requirements.

      After the device is added, Device ID and PSK are returned. Keep the PSK securely as it is required when the device uses DTLS to connect to the IoT platform.

  4. In the device list, select the newly added physical device to enter the Online Test page.

  5. Connect the device to the IoT platform and report data. View the data reporting result in Application Simulator and processing logs of the IoT platform in Message Tracking.

  6. Deliver a command in Application Simulator. View processing logs of the IoT platform in Message Tracking and check the received command on the device.

Using a Virtual Device for Online Test

  1. In the product development space, click Perform Online Test.

  2. Click Add at the row where Device List resides.

  3. In the Add Test Device dialog box displayed, select No and click OK.

  4. In the device list, select the newly added virtual device to enter the Online Test page. The name of the virtual device is in the format of Product Name+Simulator. Only one virtual device can be added for each product.

  5. In Device Simulator, enter a hexadecimal code stream or JSON data (for example, enter a hexadecimal code stream) and click Send. Then, view the data reporting result in Application Simulator and processing logs of the IoT platform in Message Tracking.

  6. Deliver a command in Application Simulator. View the received command (for example, a hexadecimal code stream) in Device Simulator and processing logs of the IoT platform in Message Tracking.