Method and apparatus for interaction of a device simulator with an internet of things platform

By configuring target product information on the IoT platform, the device simulator generates device parameters and simulates device message processing, solving the problem that the device simulator cannot connect to third-party IoT devices. This improves the flexibility and practicality of IoT device testing and reduces development costs.

CN116028240BActive Publication Date: 2026-07-31SHENZHEN KONKA ELECTRONIC TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHENZHEN KONKA ELECTRONIC TECH CO LTD
Filing Date
2022-12-13
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

Existing device simulators cannot access third-party IoT devices by configuring product information in the cloud, which affects the flexibility and practicality of IoT device testing.

Method used

By configuring the product information of the target product on the IoT platform, the device simulator synchronizes the target product information and generates device parameters based on the target product and target device information. It then simulates the target device sending device messages to the message gateway. The device management module of the IoT platform processes the device messages and returns the processing results to the device simulator.

Benefits of technology

It improves the flexibility and practicality of IoT device testing, reduces the manpower cost for developers to redevelop simulators, and realizes the need for one-click configuration and immediate simulation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116028240B_ABST
    Figure CN116028240B_ABST
Patent Text Reader

Abstract

This disclosure provides a method and apparatus for interaction between a device simulator and an IoT platform. The method includes: the device simulator acquiring product information of a target product configured on the IoT platform; acquiring device information of a target device to be simulated; generating device parameters for the target device based on the product information of the target product and the device information of the target device; sending a device message to a message gateway, the device message carrying the device parameters of the target device; the message gateway forwarding the device message to the corresponding device management module in the IoT platform for message processing based on the type of the device message; and receiving the message processing result returned by the IoT platform. This disclosure solves the problem in related technologies where device simulators cannot access third-party IoT devices by configuring product information in the cloud, thereby improving the flexibility and practicality of IoT device testing and reducing the manpower cost for developers to redevelop simulators.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of Internet of Things (IoT) technology, and in particular to a method and apparatus for interaction between a device simulator and an IoT platform. Background Technology

[0002] Every smart product project requires a complete process: requirements confirmation -> product definition -> profile generation -> platform product data generation -> hardware completion of electronic control development -> device access to the platform according to the protocol -> functional and stability testing -> completion of access. However, in the process from the developers completing hardware electronic control development to the device undergoing functional testing, the device simulator can first generate device data based on the product definition, simulating a perfect device. This allows developers to develop and improve functions, enabling real devices to access the platform more quickly and shortening the launch cycle of new devices.

[0003] Existing device simulators simulate vendors' IoT devices via edge-to-cloud and cloud-to-cloud interfaces. The simulator processes device data, converting it into corresponding device messages using edge-to-cloud and cloud-to-cloud protocols. The cloud then reads and responds to these messages. However, existing device simulators cannot connect to third-party vendors' IoT devices by configuring product information in the cloud. First, the third-party vendor needs to be integrated into the device simulator, and relevant cloud products need to be added to the cloud product library. Only after adaptation development and testing between the device simulator and the cloud can the corresponding IoT device be simulated, which impacts the flexibility and practicality of IoT device testing.

[0004] Currently, no effective solution has been proposed to address the issue that device simulators in related technologies cannot access third-party IoT devices by configuring product information in the cloud, thus affecting the flexibility and practicality of IoT device testing. Summary of the Invention

[0005] The purpose of this disclosure is to address the shortcomings of the prior art by providing a method, apparatus, electronic device, and computer-readable storage medium for interaction between a device simulator and an Internet of Things (IoT) platform, so as to at least solve the problem in the related art that the device simulator cannot access the IoT devices of third-party manufacturers by configuring product information in the cloud, which affects the flexibility and practicality of IoT device testing.

[0006] According to one aspect of this disclosure, a method for interaction between a device simulator and an Internet of Things (IoT) platform is provided, comprising:

[0007] The device simulator obtains product information of the target product configured on the IoT platform;

[0008] The device simulator acquires the device information of the target device to be simulated;

[0009] The device simulator generates the device parameters of the target device based on the product information of the target product and the device information of the target device.

[0010] The device simulator sends a device message to the message gateway, wherein the device message carries the device parameters of the target device, and the message gateway is used to forward the device message to the corresponding device management module in the IoT platform for message processing according to the type of the device message;

[0011] The device simulator receives the message processing results returned by the IoT platform.

[0012] According to another aspect of this disclosure, a method for interaction between a device simulator and an Internet of Things (IoT) platform is provided, comprising:

[0013] The IoT platform sends the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device.

[0014] The IoT platform receives a device message sent by the device simulator and forwarded by the message gateway, wherein the device message carries the device parameters of the target device;

[0015] The IoT platform forwards the device message to the corresponding device management module for message processing based on the type of the device message.

[0016] The IoT platform sends the result of the message processing to the device simulator.

[0017] According to another aspect of this disclosure, an interaction device for a device simulator and an Internet of Things (IoT) platform is provided, comprising:

[0018] The first acquisition unit is used for the device simulator to acquire product information of the target product configured on the Internet of Things platform;

[0019] The second acquisition unit is used for the device simulator to acquire device information of the target device to be simulated;

[0020] A generation unit is used for the device simulator to generate device parameters for the target device based on the product information of the target product and the device information of the target device.

[0021] The first sending unit is used for the device simulator to send a device message to the message gateway, wherein the device message carries the device parameters of the target device, and the message gateway is used to forward the device message to the corresponding device management module in the Internet of Things platform for message processing according to the type of the device message;

[0022] The first receiving unit is used for the device simulator to receive the result of message processing returned by the Internet of Things platform.

[0023] According to another aspect of this disclosure, an interaction device for a device simulator and an Internet of Things (IoT) platform is provided, comprising:

[0024] The second sending unit is used by the Internet of Things platform to send the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device.

[0025] The second receiving unit is used for the IoT platform to receive device messages sent by the device simulator forwarded by the message gateway, wherein the device messages carry device parameters of the target device;

[0026] The processing unit is used by the IoT platform to forward the device message to the corresponding device management module for message processing according to the type of the device message;

[0027] The third sending unit is used by the IoT platform to send the result of the message processing to the device simulator.

[0028] According to another aspect of this disclosure, an electronic device is provided, comprising:

[0029] Processor; and

[0030] Stored program memory,

[0031] The program includes instructions that, when executed by the processor, cause the processor to perform the interaction method between the device simulator and the Internet of Things platform as disclosed herein.

[0032] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions for causing the computer to perform the interaction method between the device simulator and the Internet of Things platform described in this disclosure.

[0033] One or more technical solutions provided in this disclosure, by configuring product information of the target product on an IoT platform, synchronizing the target product information with a device simulator, and generating device parameters of the target device based on the product information of the target product and the device information of the target device set by the user, simulate the target device sending device messages to a message gateway. The corresponding device management module in the IoT platform processes the device messages and then returns the message processing results to the device simulator. This can solve the problem in related technologies where the device simulator cannot access third-party manufacturers' IoT devices by configuring product information in the cloud, which affects the flexibility and practicality of IoT device testing. It improves the flexibility and practicality of IoT device testing, reduces the manpower cost for developers to redevelop the simulator, and realizes the need for one-click configuration and instant simulation. Attached Figure Description

[0034] Further details, features, and advantages of this disclosure are disclosed in the following description of exemplary embodiments in conjunction with the accompanying drawings, in which:

[0035] Figure 1 A flowchart illustrating a method for interaction between a device simulator and an Internet of Things (IoT) platform according to an exemplary embodiment of the present disclosure is shown;

[0036] Figure 2 A flowchart illustrating a method for interaction between a device simulator and an Internet of Things (IoT) platform according to another exemplary embodiment of this disclosure is shown;

[0037] Figure 3 A schematic diagram of the architecture of an Internet of Things (IoT) platform according to a preferred embodiment of the present disclosure is shown;

[0038] Figure 4 A schematic diagram illustrating the interaction flow between an IoT device and an IoT platform according to a preferred embodiment of the present disclosure is shown.

[0039] Figure 5 A schematic diagram illustrating the interaction flow between a device simulator and an Internet of Things platform according to a preferred embodiment of the present disclosure is shown.

[0040] Figure 6 A schematic block diagram of an interaction device between a device simulator and an Internet of Things platform according to exemplary embodiments of the present disclosure is shown;

[0041] Figure 7 A schematic block diagram of an interaction device between a device simulator and an Internet of Things platform according to another exemplary embodiment of the present disclosure is shown;

[0042] Figure 8 A structural block diagram of an exemplary electronic device that can be used to implement embodiments of the present disclosure is shown. Detailed Implementation

[0043] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.

[0044] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.

[0045] The term "comprising" and its variations as used herein are open-ended, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below. It should be noted that the concepts of "first", "second", etc., used in this disclosure are only used to distinguish different devices, modules, or units, and are not intended to limit the order of functions performed by these devices, modules, or units or their interdependencies.

[0046] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".

[0047] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.

[0048] First, let's explain the following technical terms:

[0049] IOT is short for Internet of Things.

[0050] Device simulator: An application used to simulate data from IoT devices.

[0051] The present disclosure is described below with reference to the accompanying drawings.

[0052] This disclosure provides an exemplary embodiment of a method for interaction between a device simulator and an Internet of Things (IoT) platform. This method can be used in a device simulator. Figure 1 A flowchart illustrating a method for interaction between a device simulator and an Internet of Things (IoT) platform according to an exemplary embodiment of this disclosure is shown, such as... Figure 1 As shown, the method includes the following steps:

[0053] Step S101: The device simulator obtains the product information of the target product configured on the IoT platform;

[0054] Step S102: The device simulator acquires the device information of the target device to be simulated;

[0055] Step S103: The device simulator generates the device parameters of the target device based on the product information of the target product and the device information of the target device;

[0056] In step S104, the device simulator sends a device message to the message gateway, wherein the device message carries the device parameters of the target device, and the message gateway is used to forward the device message to the corresponding device management module in the IoT platform for message processing according to the type of the device message.

[0057] Step S105: The device simulator receives the message processing result returned by the IoT platform.

[0058] In this embodiment, developers can configure new product information on a cloud-based IoT platform. The target product can be any of the new products, and its information may include, but is not limited to, product ID, product name, product service items, and product attribute items. Users can select the target product automatically synchronized from the IoT platform in the device simulator and set the device information of the target device for that product. The target device can be any device of the target product. The device information of the target device may include, but is not limited to, device name and device ID. The device simulator can generate default device parameters for the target device based on the product information of the target product and the device information of the target device.

[0059] In some embodiments, the device parameters of the target device can be displayed on the device simulator's interface. The device simulator simulates the target device sending device messages to the IoT platform, wherein the device messages carry the device parameters of the target device. The device messages first arrive at the message gateway, which forwards the device messages to the corresponding device management module in the IoT platform for message processing based on the message type. After processing the device messages, the device management module returns the processing result to the device simulator. The types of device messages include: device registration messages and device control messages; the corresponding device management module in the IoT platform may include: a device registration center and a device control center.

[0060] In some embodiments, when the device message type is a device registration message, the message gateway is used to forward the device message to the device registration center in the IoT platform for message processing, wherein the device registration center processes the device message by:

[0061] Determine whether the target device is a new device;

[0062] If the target device is determined not to be a new device, an error message is output.

[0063] If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

[0064] In some embodiments, when the device message is a device control message, the message gateway forwards the device message to the device control center in the IoT platform for message processing. The device control center processes the device message by:

[0065] The device control commands and the device status of the target device are detected from the device messages;

[0066] The device status of the target device is changed according to the device control command;

[0067] Store the modified device state of the target device.

[0068] In some embodiments, after the corresponding device management module in the IoT platform processes the device message, it further includes:

[0069] The results of the message processing are synchronized to the business management center in the IoT platform for storage. The business management center is used to synchronize the results of the message processing to the device simulator and the third-party control platform. The third-party control platform is bound to the target device, and uses this binding relationship to control the target device and display its device parameters and status.

[0070] This exemplary embodiment provides another method for interaction between a device simulator and an Internet of Things (IoT) platform. This method can be used with an IoT platform. Figure 2 A flowchart illustrating a method for interaction between a device simulator and an Internet of Things (IoT) platform according to another exemplary embodiment of this disclosure is shown, such as... Figure 2 As shown, the method includes the following steps:

[0071] Step S201: The IoT platform sends the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device.

[0072] Step S202: The IoT platform receives a device message sent by the device simulator forwarded by the message gateway, wherein the device message carries the device parameters of the target device;

[0073] Step S203: The IoT platform forwards the device message to the corresponding device management module for message processing according to the type of the device message;

[0074] In step S204, the IoT platform sends the result of the message processing to the device simulator.

[0075] In some embodiments, the device message type includes a device registration message. The IoT platform forwards the device message to a device registration center for message processing. The device management module includes the device registration center, wherein the device registration center processes the device message by:

[0076] Determine whether the target device is a new device;

[0077] If the target device is determined not to be a new device, an error message is output.

[0078] If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

[0079] In some embodiments, the device message type includes a device control message. The IoT platform forwards the device message to a device control center for message processing. The device management module includes the device control center, wherein the device control center processes the device message by:

[0080] The device control commands and the device status of the target device are detected from the device messages;

[0081] The device status of the target device is changed according to the device control command;

[0082] Store the modified device state of the target device.

[0083] In some embodiments, after the IoT platform forwards the device message to the corresponding device management module for message processing according to the type of the device message, it further includes:

[0084] The IoT platform synchronizes the message processing results to the business management center within the IoT platform for storage. The business management center is used to synchronize the message processing results to the device simulator and a third-party control platform. The third-party control platform is bound to the target device, and uses this binding relationship to control the target device and display its device parameters and status.

[0085] The device simulator and IoT platform interaction method provided in the above-disclosed embodiments synchronizes the product information of the target product configured on the IoT platform with the device simulator, and generates device parameters of the target device based on the product information of the target product and the device information of the target device set by the user. This simulates the target device sending device messages to the message gateway. The message gateway forwards the device messages to the corresponding device management module in the IoT platform. The device management module processes the device messages and then returns the processing results to the device simulator. This solves the problem in related technologies where the device simulator cannot access third-party manufacturers' IoT devices by configuring product information in the cloud, which affects the flexibility and practicality of IoT device testing. It improves the flexibility and practicality of IoT device testing, reduces the manpower cost for developers to redevelop the simulator, and realizes the need for one-click configuration and immediate simulation.

[0086] The embodiments of this application will be described and illustrated below through preferred embodiments.

[0087] The technical solution adopted in this preferred embodiment includes:

[0088] 1) A basic overview of the entire project built using the Spring Boot framework;

[0089] 2) The communication method between the device simulator and the cloud-based IoT platform is constructed using MQTT message components, NAT's message components, and the HTTP protocol;

[0090] 3) Optimize the overall project response speed and performance by using local caching, and store local device data;

[0091] 4) A thread pool is used to provide control and registration for multiple simulated devices;

[0092] 5) Use Java GUI technology to build a user interface for operation.

[0093] The preferred embodiment is used in the following scenarios:

[0094] (1) Suitable for testing departments to quickly test the functions of IoT devices and ensure that the devices can be quickly launched to users after being connected to the cloud.

[0095] (2) A solution suitable for rapid access, testing and linkage of equipment.

[0096] Figure 3 A schematic diagram of the architecture of an Internet of Things (IoT) platform according to a preferred embodiment of the present disclosure is shown, such as... Figure 3 As shown, the IoT platform in this preferred embodiment mainly includes the following components:

[0097] Service layer: includes management backend, device simulator, device monitoring service and message push service.

[0098] Management layer: includes device management, message configuration management, user management, and rule engine management.

[0099] Data layer: includes historical / real-time device data, system / device log data, data forwarding, and data storage.

[0100] Business Management Center: Includes modules such as system management, device management, log management, notification management, system monitoring, and rule engine management.

[0101] In addition, it may include: authentication, system monitoring services, monitoring management, security firewalls, etc.

[0102] Figure 4 A schematic diagram illustrating the interaction flow between an IoT device and an IoT platform according to a preferred embodiment of this disclosure is shown, such as... Figure 4 As shown, the device simulator can simulate virtual devices based on device data from the device itself, and then send device messages to the cloud-based internet platform. These device messages can include, but are not limited to, event reporting, device online / offline status, device registration, and device deletion. Device registration messages are authenticated and managed through the device gateway, and processed by the device registration center. Other device messages are forwarded through the message gateway, device control messages are processed by the device control center, and device log messages are processed by the persistent storage module. Data from the device registration center, device control center, and persistent storage module are synchronized to the device management module, rule engine management module, and log management module of the business management center, respectively. The system management module in the business management center can be used to manage data from third-party IoT platforms communicating through the cloud-to-cloud interface center. Users can control devices and link scenes through user-end apps and TVs, and can also view device data and device status synchronized by the business management center.

[0103] based on Figure 3 and Figure 4 The interaction process between the device simulator and the IoT platform in this preferred embodiment can be as follows: Figure 5 As shown, it specifically includes:

[0104] (1) Developers edit product information (attributes, services, agreements, categories, etc.) in the cloud.

[0105] (2) The device simulator software synchronizes product information in the cloud. When the developer creates a new product in the cloud, the device simulator updates the list of products that can be simulated.

[0106] (3) In device control, the device simulator sends device messages according to the protocol of the simulated product, allowing the device messages to enter the message gateway.

[0107] (4) In the device addition process, the user selects the product to be simulated by the device simulator. The device simulator generates the default device data and device status based on the product information.

[0108] (5) The message gateway verifies the data format and forwards the message to the corresponding module for processing based on the protocol parameters carried.

[0109] (6) The device registration message will be received by the device registration center. The device registration center will verify the device data in the message body and the corresponding product information in the cloud. After verification, it will determine whether it is a new device added. If it is not a new device, an error message will be returned to prompt the user; if it is a new device, the new device will be added to the database and a device key will be generated according to the product information and device name. The device will be activated and put online first, and then synchronized to the database and the device management module of the business management center.

[0110] (7) Device control messages will be received by the device control center. The device control center will check the device control instructions and device status in the message body, change the device status according to the instruction parameters, and synchronize the device status to the cache and message components, as well as the third-party console (APP, TV, etc.).

[0111] (8) The corresponding module of the business management center receives the device data and synchronizes it to the user's APP, TV or device simulator based on the device data.

[0112] (9) Equipment control or equipment addition is successful.

[0113] The following is an application example (simulating a smart product - a colored light bulb):

[0114] 1) Users configure new product information on the cloud IoT platform, select Huawei as the manufacturer, and edit product ID, product name, product service items, and product attribute items. Through these configurations, the device simulator can identify that the product belongs to Huawei and communicate with the device through the cloud-to-cloud connection link.

[0115] 2) The user selects the newly created colored light bulb product in the device simulator and sets a device name and a unique device ID.

[0116] 3) The device simulator automatically synchronizes product data from the cloud, generates default device data for the device based on the cloud product data and the device information entered by the user, and checks whether the device name is duplicated. The user can then view the device data, such as brightness, on / off status, color, and color temperature, in the device simulator interface.

[0117] 4) Users can click the QR code button to bind the virtual device using the accompanying APP.

[0118] 5) Once the binding is complete, the status of the virtual device will appear in the APP. When the user clicks the Connect Device button, the virtual device on the APP will go online. At this time, the user can choose to operate the device control on the APP or control the device through the space of the emulator terminal.

[0119] 6) The user changes the device switch attribute data of the device simulator terminal and sends the device data switch=1. After data conversion and cloud processing, the device simulator displays a rendered screen showing that the light bulb is on on the APP.

[0120] 7) The user operates the device simulator terminal to send the color temperature attribute data, and sends the device data colorTemperature=4000K. The APP receives the processed device data and will display the corresponding warm-toned light and color temperature value of 4000K.

[0121] 8) When the user disconnects the device, the APP displays that the device is offline, and the user cannot control the device through the APP.

[0122] 9) Once the user removes the device, they will see that the colored light device has been deleted from the APP.

[0123] 10) When the user closes the entire emulator terminal, the emulator will send a message that all emulator devices are offline and save the user's operation data to the local machine.

[0124] This disclosed embodiment is based on MQTT, NATS and HTTP network communication protocols to forward and process device data. By acquiring data from various configuration items in the cloud, the device simulator can simulate a perfect device. This can reduce the impact of network, hardware and driver issues on test results of real devices, and can also simulate devices for rapid development of device functions.

[0125] This disclosure enables IoT devices to quickly connect to the device simulator and cloud architecture by dynamically configuring parameters such as the category, service, protocol, attributes and instructions of IoT device products in the cloud. This improves the flexibility and practicality of IoT device testing, reduces the manpower cost for developers to redevelop the simulator, and realizes the need for one-click configuration and instant simulation.

[0126] It should be noted that the steps shown in the above process or in the flowchart of the accompanying figures can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.

[0127] This disclosure also provides an exemplary embodiment of an interaction device between a device simulator and an Internet of Things (IoT) platform. This device is used to implement the above embodiments and preferred embodiments, and details already described will not be repeated. As used below, the terms "module," "unit," "subunit," etc., can refer to a combination of software and / or hardware that performs a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0128] Figure 6 A schematic block diagram of an interaction device between a device simulator and an Internet of Things (IoT) platform according to exemplary embodiments of the present disclosure is shown, such as... Figure 6 As shown, the device includes:

[0129] The first acquisition unit 61 is used for the device simulator to acquire product information of the target product configured on the Internet of Things platform;

[0130] The second acquisition unit 62 is used for the device simulator to acquire device information of the target device to be simulated;

[0131] The generation unit 63 is used by the device simulator to generate the device parameters of the target device based on the product information of the target product and the device information of the target device;

[0132] The first sending unit 64 is used for the device simulator to send a device message to the message gateway, wherein the device message carries the device parameters of the target device, and the message gateway is used to forward the device message to the corresponding device management module in the Internet of Things platform for message processing according to the type of the device message;

[0133] The first receiving unit 65 is used for the device simulator to receive the result of message processing returned by the Internet of Things platform.

[0134] In some embodiments, the device message type includes a device registration message, and the message gateway is used to forward the device message to a device registration center in the IoT platform for message processing. The device management module includes the device registration center, wherein the device registration center processes the device message by:

[0135] Determine whether the target device is a new device;

[0136] If the target device is determined not to be a new device, an error message is output.

[0137] If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

[0138] In some embodiments, the device message type includes a device control message, and the message gateway is used to forward the device message to the device control center in the IoT platform for message processing. The device management module includes the device control center, wherein the device control center processes the device message by:

[0139] The device control commands and the device status of the target device are detected from the device messages;

[0140] The device status of the target device is changed according to the device control command;

[0141] Store the modified device state of the target device.

[0142] In some embodiments, the device further includes:

[0143] The first storage unit is used to synchronize the message processing result of the device message to the business management center in the IoT platform for storage after the corresponding device management module in the IoT platform processes the message. The business management center is used to synchronize the message processing result to the device simulator and the third-party control platform. The third-party control platform has a binding relationship with the target device. Using the binding relationship, the third-party control platform is used to control the target device and display the device parameters and device status of the target device.

[0144] Figure 7 A schematic block diagram of an interaction device between a device simulator and an Internet of Things platform according to another exemplary embodiment of the present disclosure is shown, such as Figure 7 As shown, the device includes:

[0145] The second sending unit 71 is used by the Internet of Things platform to send the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device.

[0146] The second receiving unit 72 is used for the IoT platform to receive a device message sent by the device simulator forwarded by the message gateway, wherein the device message carries the device parameters of the target device;

[0147] Processing unit 73 is used by the Internet of Things platform to forward the device message to the corresponding device management module for message processing according to the type of the device message;

[0148] The third sending unit 74 is used by the Internet of Things platform to send the result of the message processing to the device simulator.

[0149] In some embodiments, the device message type includes a device registration message. The IoT platform forwards the device message to a device registration center for message processing. The device management module includes the device registration center, wherein the device registration center processes the device message by:

[0150] Determine whether the target device is a new device;

[0151] If the target device is determined not to be a new device, an error message is output.

[0152] If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

[0153] In some embodiments, the device message type includes a device control message. The IoT platform forwards the device message to a device control center for message processing. The device management module includes the device control center, wherein the device control center processes the device message by:

[0154] The device control commands and the device status of the target device are detected from the device messages;

[0155] The device status of the target device is changed according to the device control command;

[0156] Store the modified device state of the target device.

[0157] In some embodiments, the device further includes:

[0158] The second storage unit is used after the IoT platform forwards the device message to the corresponding device management module for message processing according to the type of the device message. The IoT platform then synchronizes the message processing result to the business management center in the IoT platform for storage. The business management center is used to synchronize the message processing result to the device simulator and the third-party control platform. The third-party control platform has a binding relationship with the target device. Using the binding relationship, the third-party control platform is used to control the target device and display the device parameters and device status of the target device.

[0159] It should be noted that the above modules can be functional modules or program modules, and can be implemented through software or hardware. For modules implemented through hardware, the above modules can reside in the same processor; or the above modules can be located in different processors in any combination.

[0160] Exemplary embodiments of this disclosure also provide an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor. The memory stores a computer program executable by the at least one processor, the computer program being executed by the at least one processor to cause the electronic device to perform a method according to an embodiment of this disclosure.

[0161] Exemplary embodiments of this disclosure also provide a non-transitory computer-readable storage medium storing a computer program, wherein the computer program, when executed by a computer's processor, is used to cause the computer to perform a method according to embodiments of this disclosure.

[0162] Exemplary embodiments of this disclosure also provide a computer program product, including a computer program, wherein, when executed by a processor of a computer, the computer program is used to cause the computer to perform a method according to an embodiment of this disclosure.

[0163] refer to Figure 8 The present invention describes a structural block diagram of an electronic device 800 that can serve as a server or client of the present disclosure, which is an example of a hardware device that can be applied to various aspects of the present disclosure. The electronic device is intended to represent various forms of digital electronic computer devices, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0164] like Figure 8 As shown, the electronic device 800 includes a computing unit 801, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 802 or a computer program loaded from a storage unit 808 into a random access memory (RAM) 803. The RAM 803 may also store various programs and data required for the operation of the device 800. The computing unit 801, ROM 802, and RAM 803 are interconnected via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.

[0165] Multiple components in electronic device 800 are connected to I / O interface 805, including: input unit 806, output unit 807, storage unit 808, and communication unit 809. Input unit 806 can be any type of device capable of inputting information to electronic device 800. Input unit 806 can receive input digital or character information and generate key signal inputs related to user settings and / or function control of electronic device. Output unit 807 can be any type of device capable of presenting information and may include, but is not limited to, a display, speaker, video / audio output terminal, vibrator, and / or printer. Storage unit 808 may include, but is not limited to, disk and optical disk. Communication unit 809 allows electronic device 800 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers, and / or chipsets, such as Bluetooth devices, WiFi devices, WiMax devices, cellular communication devices, and / or the like.

[0166] The computing unit 801 can be a variety of general-purpose and / or dedicated processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 801 performs the various methods and processes described above. For example, in some embodiments, the interaction method between the device simulator and the Internet of Things (IoT) platform can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 808. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 800 via ROM 802 and / or communication unit 809. In some embodiments, the computing unit 801 can be configured to perform the interaction method between the device simulator and the IoT platform by any other suitable means (e.g., by means of firmware).

[0167] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0168] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0169] As used in this disclosure, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, device, and / or apparatus (e.g., disk, optical disk, memory, programmable logic device (PLD)) for providing machine instructions and / or data to a programmable processor, including machine-readable media that receive machine instructions as machine-readable signals. The term "machine-readable signal" refers to any signal for providing machine instructions and / or data to a programmable processor.

[0170] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0171] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with embodiments of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0172] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other.

Claims

1. A method for interaction between a device simulator and an Internet of Things (IoT) platform, characterized in that, include: The device simulator obtains product information of the target product configured on the IoT platform; The device simulator acquires the device information of the target device to be simulated; The device simulator generates the device parameters of the target device based on the product information of the target product and the device information of the target device. The device simulator sends device messages to the message gateway, wherein the device messages carry device parameters of the target device. The message gateway is used to forward the device messages to the corresponding device management module in the IoT platform for message processing according to the type of the device messages. The types of device messages include: device registration messages and device control messages. The device management module includes: a device registration center and a device control center. The message gateway is used to forward the device registration messages to the device registration center for message processing. The message gateway is also used to forward the device control messages to the device control center for message processing. The device simulator receives the message processing result returned by the IoT platform.

2. The device emulator interaction method with the Internet of Things platform according to claim 1, characterized in that, The device registration center processes the device registration message in the following ways: Determine whether the target device is a new device; If the target device is determined not to be a new device, an error message is output. If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

3. The device simulator interaction method with an IoT platform of claim 1, wherein, The device control center processes the device control messages, including: The device control commands and the device status of the target device are detected from the device messages; The device status of the target device is changed according to the device control command; Store the modified device state of the target device.

4. The device emulator interacting with an IoT platform method of any one of claims 1 to 3, wherein, After the corresponding device management module in the IoT platform processes the device message, it also includes: The result of the message processing is synchronized to the business management center in the IoT platform for storage. The business management center is used to synchronize the result of the message processing to the device simulator and the third-party control platform. The third-party control platform is bound to the target device. Using the binding relationship, the third-party control platform is used to control the target device and display the device parameters and device status of the target device.

5. A method for interaction of a device emulator with an Internet of Things platform, the method comprising: include: The IoT platform sends the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device. The IoT platform receives device messages sent by the device simulator, forwarded by a message gateway. These device messages carry device parameters of the target device. The message gateway forwards the device messages to the corresponding device management module in the IoT platform for message processing based on the message type. The device message types include: device registration messages and device control messages. The device management module includes: a device registration center and a device control center. The message gateway forwards the device registration messages to the device registration center for message processing. The message gateway also forwards the device control messages to the device control center for message processing. The IoT platform sends the result of the message processing to the device simulator.

6. The device emulator interaction method with the Internet of Things platform according to claim 5, characterized in that, The device registration center processes the device registration message in the following ways: Determine whether the target device is a new device; If the target device is determined not to be a new device, an error message is output. If the target device is determined to be a new device, then the target device is added to the database; a key for the target device is generated based on the device parameters of the target device and the product information of the target product; the target device is activated and brought online.

7. The device emulator interaction method with the Internet of Things platform according to claim 5, characterized in that, The device control center processes the device control messages, including: The device control commands and the device status of the target device are detected from the device messages; The device status of the target device is changed according to the device control command; Store the modified device state of the target device.

8. The device emulator interacting with the IoT platform method of any one of claims 5 to 7, wherein, After the IoT platform forwards the device message to the corresponding device management module for message processing according to the type of the device message, it also includes: The IoT platform synchronizes the message processing results to the business management center within the IoT platform for storage. The business management center is used to synchronize the message processing results to the device simulator and a third-party control platform. The third-party control platform is bound to the target device, and uses this binding relationship to control the target device and display its device parameters and status.

9. An interaction device between a device simulator and an Internet of Things (IoT) platform, characterized in that, include: The first acquisition unit is used for the device simulator to acquire product information of the target product configured on the Internet of Things platform; The second acquisition unit is used for the device simulator to acquire device information of the target device to be simulated; A generation unit is used for the device simulator to generate device parameters for the target device based on the product information of the target product and the device information of the target device. The first sending unit is used to send device messages from the device simulator to the message gateway. The device messages carry device parameters of the target device. The message gateway forwards the device messages to the corresponding device management module in the IoT platform for message processing based on the type of the device messages. The types of device messages include: device registration messages and device control messages. The device management module includes: a device registration center and a device control center. The message gateway forwards the device registration messages to the device registration center for message processing. The message gateway also forwards the device control messages to the device control center for message processing. The first receiving unit is used for the device simulator to receive the result of message processing returned by the Internet of Things platform.

10. An interaction device between a device simulator and an Internet of Things (IoT) platform, characterized in that, include: The second sending unit is used by the Internet of Things platform to send the configured product information of the target product to the device simulator, wherein the device simulator is used to generate the device parameters of the target device based on the product information of the target product and the device information of the target device. The second receiving unit is used for the IoT platform to receive device messages sent by the device simulator forwarded by the message gateway. The device messages carry device parameters of the target device. The message gateway is used to forward the device messages to the corresponding device management module in the IoT platform for message processing according to the type of the device messages. The types of device messages include: device registration messages and device control messages. The processing unit is used for the device registration center in the IoT platform to process the device registration message, and the device control center in the IoT platform to process the device control message. The third sending unit is used by the IoT platform to send the result of the message processing to the device simulator.

11. An electronic device, comprising: include: processor; as well as Stored program memory, The program includes instructions that, when executed by the processor, cause the processor to perform the interaction method between the device simulator and the Internet of Things platform according to any one of claims 1-8.

12. A non-transitory computer-readable storage medium having stored thereon computer instructions, wherein, The computer instructions are used to cause the computer to execute the interaction method between the device simulator and the Internet of Things platform according to any one of claims 1-8.