Data transmission method, apparatus, system, and electronic device

CN116418849BActive Publication Date: 2026-09-11ECOFLOW INC
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202310292131.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-17
Publication Date
2026-09-11
Estimated Expiration
2043-03-17

AI Technical Summary

Technical Problem

[0004]鉴于此,本申请提供一种数据传输方法、装置、系统及电子设备,可以解决个别接收设备接收不到数据时发送设备需要再次发送数据,导致通信资源浪费的问题

Benefits of technology

[0004] In view of this, this application provides a data transmission method, apparatus, system and electronic device, which can solve the problem that when individual receiving devices fail to receive data, the sending device needs to retransmit the data, resulting in a waste of communication resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116418849B_ABST
    Figure CN116418849B_ABST
Patent Text Reader

Abstract

The application provides a data transmission method, device, system and electronic equipment. The data transmission method comprises the following steps: when target data sent by a source device is received or feedback information sent by a first slave device is received, waiting for a preset time length; determining a second slave device in a local area network which does not send feedback information as a target device; sending the target data to the target device or sending a data sending instruction to the first slave device. The above method can realize that the source device only needs to send the target data once, the target data can be received by the master device and all the slave devices, the source device does not need to resend the target data due to the influence of the second slave device which does not receive the target data, and the waste of communication resources is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of data transmission, specifically to data transmission methods, apparatus, systems, and electronic devices. Background Technology

[0002] In some data transmission scenarios, such as when maintaining or updating multiple devices in a location, a master station or server is needed as the sending device to send maintenance or update data to multiple receiving devices (i.e., the aforementioned multiple devices). However, factors such as a large number of receiving devices or a long distance between the sending and receiving devices may cause significant instability during data transmission, potentially resulting in some receiving devices failing to receive the data sent by the sending device.

[0003] In related technologies, after a transmitting device sends data to multiple receiving devices, if there are receiving devices that have not received the data, the transmitting device needs to retransmit the data, resulting in a waste of communication resources. Summary of the Invention

[0004] In view of this, this application provides a data transmission method, apparatus, system and electronic device, which can solve the problem that when individual receiving devices fail to receive data, the sending device needs to retransmit the data, resulting in a waste of communication resources.

[0005] The first aspect of this application provides a data transmission method applied to a master device, comprising: waiting for a preset time after receiving target data sent by a source device, or receiving feedback information sent by a first slave device; the feedback information being information sent by the first slave device to the master device after receiving the target data; after waiting for the preset time, identifying a second slave device in the local area network that has not sent feedback information as the target device; wherein the master device, the first slave device, and the second slave device are in the same local area network, and the source device is not in the local area network; sending the target data to the target device, or sending a data transmission instruction to the first slave device; the data transmission instruction instructing the first slave device to send the target data to the target device.

[0006] In the above embodiments, when the master device receives the target data sent by the source device or receives feedback information sent by the first slave device, it can determine that the source device has sent the target data. After the source device has sent the target data, it waits for a preset time and counts the second slave devices in the local area network that have not sent feedback information, and designates the second slave devices as target devices that have not received the target data. Then, it sends the target data to the target device, or instructs the first slave device to send the target data to the target device, so that the second slave device can receive the target data. Therefore, the source device only needs to send the target data once, and the master device and all slave devices can receive the target data. The source device does not need to resend the target data due to the second slave device not receiving the target data, reducing the waste of communication resources.

[0007] In one embodiment, the method further includes: when receiving feedback information sent by the first slave device but not receiving target data sent by the source device, sending a data acquisition instruction to the first slave device, the data acquisition instruction being used to instruct the first slave device to send target data to the master device; and receiving the target data sent by the first slave device.

[0008] In one embodiment, sending target data to a target device includes: sending target data to the target device upon receiving target data sent by a source device or upon receiving target data sent by a first slave device.

[0009] In one embodiment, the method further includes: receiving target data sent by a source device via broadcast.

[0010] A second aspect of this application provides another data transmission method, which is applied to a first slave device and includes: receiving target data sent by a source device and sending feedback information to a master device; receiving a data transmission instruction sent by the master device; and sending the target data to a target device according to the data transmission instruction; wherein the target device is a second slave device in a local area network that has not sent feedback information to the master device, and the master device, the first slave device, and the second slave device are in the same local area network, while the source device is not in the local area network.

[0011] In the above embodiments, when the master device receives the target data sent by the source device or receives feedback information sent by the first slave device, it can determine that the source device has sent the target data. After the source device has sent the target data, it waits for a preset time and counts the second slave devices in the local area network that have not sent feedback information, and designates the second slave devices as target devices that have not received the target data. Then, it sends the target data to the target device, or instructs the first slave device to send the target data to the target device, so that the second slave device can receive the target data. Therefore, the source device only needs to send the target data once, and the master device and all slave devices can receive the target data. The source device does not need to resend the target data due to the second slave device not receiving the target data, reducing the waste of communication resources.

[0012] In one embodiment, the method further includes: receiving a data acquisition instruction sent by a master device; and sending target data to the master device according to the data acquisition instruction.

[0013] A third aspect of this application provides a data transmission apparatus applied to a master device, comprising: a receiving trigger module, configured to wait for a preset time after receiving target data sent by a source device, or receiving feedback information sent by a first slave device; the feedback information being information sent by the first slave device to the master device after receiving the target data; a target analysis module, configured to identify a second slave device in the local area network that has not sent feedback information as the target device after waiting for the preset time; wherein the master device, the first slave device, and the second slave device are in the same local area network, and the source device is not in the local area network; and a data sending module, configured to send the target data to the target device, or send a data sending instruction to the first slave device; the data sending instruction instructing the first slave device to send the target data to the target device.

[0014] A fourth aspect of this application provides an electronic device, including: a processor; and a memory for storing executable instructions of the processor; wherein the processor executes the executable instructions to cause the electronic device to implement the data transmission method provided in the first aspect above.

[0015] The fifth aspect of this application provides another electronic device, including: a processor; and a memory for storing executable instructions of the processor; wherein the processor executes the executable instructions to cause the electronic device to implement the data transmission method provided in the second aspect above.

[0016] The technical effects of the electronic device provided in the fifth aspect can be found in the relevant description of the aforementioned data transmission method, and will not be repeated here.

[0017] The sixth aspect of this application provides a data transmission system.

[0018] A data transmission system includes electronic devices as provided in the fourth aspect above and electronic devices as provided in the fifth aspect above. Attached Figure Description

[0019] Figure 1 This is an application scenario diagram of a data transmission method in related technologies.

[0020] Figure 2 This is an application scenario diagram of a data transmission method in the embodiments of this application.

[0021] Figure 3 This is a first flowchart illustrating a data transmission method provided in an embodiment of this application.

[0022] Figure 4 This is a schematic diagram illustrating the relationship between the master device and the slave device in the embodiments of this application.

[0023] Figure 5 is a schematic diagram of the master device or the first slave device sending target data to the second slave device in an embodiment of this application.

[0024] Figure 6 This is a second flowchart illustrating a data transmission method provided in an embodiment of this application.

[0025] Figure 7 This is a schematic diagram of the master device obtaining target data from the first slave device in an embodiment of this application.

[0026] Figure 8 This is a schematic diagram of the third process of a data transmission method provided in the embodiments of this application.

[0027] Figure 9 This is a schematic diagram of the first process of data transmission between the source device, the master device, the first slave device, and the second slave device in the embodiments of this application.

[0028] Figure 10 This is a schematic diagram of the second process of data transmission between the source device, master device, first slave device and second slave device in the embodiments of this application.

[0029] Figure 11 This is a schematic diagram of the third process of data transmission between the source device, master device, first slave device, and second slave device in the embodiments of this application.

[0030] Figure 12 This is a schematic diagram of the fourth process of data transmission between the source device, master device, first slave device, and second slave device in the embodiments of this application.

[0031] Figure 13 This is a schematic diagram of the fifth process of data transmission between the source device, master device, first slave device, and second slave device in the embodiments of this application.

[0032] Figure 14 This is a schematic diagram of the sixth process of data transmission between the source device, master device, first slave device, and second slave device in the embodiments of this application.

[0033] Figure 15 This is a schematic diagram of the fourth process of a data transmission method provided in the embodiments of this application.

[0034] Figure 16 This is a fifth flowchart illustrating a data transmission method provided in an embodiment of this application.

[0035] Figure 17 This is a schematic diagram of the functional modules of a data transmission device provided in an embodiment of this application.

[0036] Figure 18 This is a schematic diagram of the structure of an electronic device provided for an embodiment of this application.

[0037] Figure 19 This is a schematic diagram of a data transmission system provided for an embodiment of this application. Detailed Implementation

[0038] It should be noted that the terms "first" and "second" in the specification, claims and drawings of this application are used to distinguish similar objects, rather than to describe a specific order or sequence.

[0039] It should also be noted that the methods disclosed in the embodiments of this application or the methods shown in the flowcharts include one or more steps for implementing the method. Without departing from the scope of the claims, the execution order of multiple steps can be interchanged, and some steps can also be deleted.

[0040] Some embodiments will now be described with reference to the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0041] Figure 1 This is a diagram illustrating an application scenario of a data transmission method in related technologies. For example... Figure 1 As shown, the data transmission method is applied between the sending device and the receiving device. The sending device needs to send data to multiple receiving devices, and the receiving devices complete the corresponding tasks in response to receiving the data.

[0042] However, factors such as a large number of receiving devices and a large distance between the sending and receiving devices may increase the instability during data transmission. This could lead to abnormal reception situations where, although the sending device sends data to multiple designated receiving devices, some receiving devices fail to receive the data.

[0043] In related technologies, when a reception anomaly is detected, the transmitting device needs to retransmit data until all designated receiving devices have received the data. This can lead to the transmitting device repeatedly transmitting data, resulting in a waste of communication resources. Therefore, this application provides a data transmission method, apparatus, system, and electronic device that can solve the problem of communication resource waste caused by the transmitting device needing to retransmit data when individual receiving devices fail to receive it.

[0044] Figure 2 This is a diagram illustrating an application scenario of a data transmission method according to an embodiment of this application. For example... Figure 2 As shown, the data transmission method is applied between the source device and the receiving device. The source device needs to send target data to multiple receiving devices, and the receiving devices can receive the target data and complete the corresponding tasks.

[0045] The receiving device has a first communication module and a second communication module. The receiving device communicates with the source device through the first communication module. For example, the source device can send data to the receiving device via broadcast. Multiple receiving devices communicate with each other through the second communication module. For example, multiple receiving devices are all in the same local area network, and the source device is not in this local area network.

[0046] The data transmission method described in this application does not involve improving the way the source device sends data, but rather improving the relevant configuration of the receiving device.

[0047] Specifically, one of the receiving devices in the same local area network (LAN) is configured as the master device, while the others are configured as slave devices. After the source device sends the target data to the master device and all slave devices, the master device analyzes its own and all slave devices' data reception status relative to the target data to determine whether there are any master / slave devices in the LAN that have not received the target data.

[0048] If the master device determines that it has not received the target data, it can request the target data from other receiving devices. If a slave device experiencing a reception anomaly is detected in the local area network (LAN), the master device can send the target data received by itself or other receiving devices to the slave device that has not received the target data. This ensures that all receiving devices in the LAN can receive the target data, and the source device does not need to resend the target data during this process, reducing waste of communication resources.

[0049] The data transmission method described in this application can be used in any scenario where a source device sends data to multiple receiving devices. The following example illustrates the data transmission scenario of a distributed photovoltaic system.

[0050] Distributed photovoltaic (PV) systems consist of multiple PV devices, characterized by their large number, wide distribution, and control equipment. When maintaining, updating, or configuring data for these PV devices, the transmitting device needs to send corresponding data to each device. However, after the transmitting device sends data, some PV devices may not receive it. The transmitting device is used for data transmission or forwarding and can be a PV device of the same type as the multiple receiving PV devices, or it can be a control master station. The PV devices can be micro-inverters used to control the solar panels.

[0051] In the example above, the transmitting device can be regarded as the source device, and multiple photovoltaic devices can be regarded as multiple receiving devices.

[0052] When a photovoltaic (PV) device with reception anomalies is detected in a local area network (LAN), the PV device acting as the master device will send the target data received by itself or other PV devices to the PV device that did not receive the target data, so that all PV devices in the LAN can receive the target data.

[0053] Figure 3 This is a flowchart illustrating a data transmission method provided in an embodiment of this application. The data transmission method is applied to the main device of the receiving device described above. Specifically, the data transmission method includes the following steps.

[0054] S301. When receiving target data or feedback information, wait for a preset time.

[0055] The target data refers to the data sent by the source device. The source device sends the target data to all receiving devices; that is, the source device sends the target data to the master device and all slave devices.

[0056] The feedback information is the message sent by the first slave device to the master device after receiving the target data. The first slave device is the slave device in the local area network that received the target data.

[0057] Specifically, the master device and all slave devices are on the same local area network (LAN), while the source device is not on this LAN. All slave devices are configured to send feedback information to the master device via the LAN after receiving target data.

[0058] It is understandable that after receiving the target data, the master device can determine that the source device has sent the target data and that it has received the target data. Conversely, after receiving feedback data, the master device can determine that the source device has sent the target data, but that it has not received the target data itself.

[0059] Because the stability of data transmission between the master device and each slave device within the same local area network is better than that of data transmission from the source device to the master device and each slave device, and data loss is less likely to occur, the master device can determine whether the source device has sent the target data, i.e., whether data transmission has started, by judging whether it has received the target data or feedback data.

[0060] If data transmission has already begun, that is, when the master device receives the target data sent by the source device or receives the feedback information sent by the first slave device, it waits for a preset time before executing the next step after the preset time has elapsed.

[0061] S302. After waiting for a preset time, the second slave device in the local area network that has not sent feedback information is identified as the target device.

[0062] Please see Figure 3 and Figure 4 In this embodiment, the second slave device is a slave device in the local area network that has not received target data from the source device. The target device is the receiving device that needs to send target data to it. In this embodiment, the feedback information carries the tag information of the first slave device. After receiving the feedback information, the master device can determine the identity of the first slave device based on the feedback information.

[0063] In one embodiment of this application, step S302 is specifically implemented as follows: the master device records the first slave device that sent feedback information in the first device list, and by comparing the first device list with the second device list of all slave devices in the local area network, obtains the second slave device that exists in the second device list but has not sent feedback information, and determines it as the target device.

[0064] S303. Send target data to the target device, or send a data sending command to the first slave device.

[0065] The data transmission command instructs the first slave device to send target data to the target device. That is, after receiving the data transmission command, the first slave device sends the target data it has received to the corresponding target device.

[0066] It is understandable that whether the master device sends the target data to the target device, or the first slave device sends the target data to the target device, the target device can receive the target data. Once the master device and all target devices have received the target data, all receiving devices in the local area network will have received the target data.

[0067] By adopting the data transmission method provided in this application, the source device only needs to send the target data once, and the master device and all slave devices can receive the target data. The source device does not need to resend the target data due to the failure of the second slave device to receive the target data, thus reducing the waste of communication resources.

[0068] Please see Figure 5A In one embodiment of this application, step S303 can be: sending target data to the target device. The master device, having already received the target data, directly sends the target data to the target device.

[0069] Please see Figure 5B In another embodiment of this application, step S303 may also be: sending a data transmission instruction to the first slave device to request the first slave device to send target data to the target device.

[0070] It is understood that, when the master device has already received the target data, the receiving device that sends the target data to the target device can be either the master device or the first slave device, and this application does not impose any restrictions on this.

[0071] Please see Figure 6 In one embodiment of this application, the data transmission method further includes the following steps.

[0072] S601. When receiving feedback information from the first slave device but not receiving target data from the source device, a data acquisition instruction is sent to the first slave device.

[0073] The data acquisition instruction is used to instruct the first slave device to send target data to the master device.

[0074] It is understandable that both the master device and the slave device are receiving devices within the same local area network. After the source device sends target data to multiple receiving devices, both the master device and the slave device may fail to receive the target data. The master device may also experience a receiving anomaly at the same time as the second slave device, failing to receive the target data.

[0075] When the master device receives feedback information from any of the first slave devices, it can determine that the source device has sent the target data, but the master device itself has not received the target data. In this case, the master device can determine that it has encountered a reception error and requests the target data from the first slave device.

[0076] S602, Receive target data sent by the first slave device.

[0077] In this process, the first slave device, upon receiving a data acquisition instruction, sends the target data to the master device.

[0078] Furthermore, in one embodiment of this application, step S303 is specifically implemented as follows:

[0079] Upon receiving target data from the source device or the first slave device, the target data is sent to the target device.

[0080] In this embodiment, when the master device does not receive the target data sent by the source device, the master device waits for a preset time after receiving the target data sent by the first slave device, and then executes step S302.

[0081] When the master device receives the target data sent by the source device, the master device may wait for a preset time after receiving the target data or after receiving the feedback information, and then execute step S302. This application does not impose any restrictions on this.

[0082] Please see Figure 7 Based on the aforementioned mechanism by which the master device can identify whether it has experienced a reception anomaly, in one embodiment of this application, step S301 can be implemented as follows: if the master device does not receive the target data and feedback information from the source device, it remains in standby mode until it receives the target data and feedback information from the source device.

[0083] If the master device does not receive the target data from the source device but receives feedback information, it requests the first slave device and identifies the target device to send the target data. The data transmission task ends when the master device and all slave devices have received the target data.

[0084] In one embodiment of this application, after the master device receives any target data or feedback information for the first time, it begins to wait for a preset time. After receiving another feedback information from another first slave device, the waiting time is not recalculated, so as to execute the next task in a timely manner and speed up the operation efficiency.

[0085] In another embodiment of this application, after the master device receives any target data or feedback information for the first time, it starts to wait for a preset time. After receiving another feedback information from another first slave device, it will recalculate the waiting time so as to provide sufficient time for each first slave device to send feedback information and reduce data loss.

[0086] In another embodiment of this application, the source device transmits target data to each receiving device via broadcast. Correspondingly, the data transmission method further includes the step of receiving the target data transmitted by the source device via broadcast.

[0087] In one embodiment of this application, the preset duration is a system preset value.

[0088] In another embodiment of this application, the preset duration is an adjustable parameter that can be set according to objective factors. Correspondingly, before step S301, the data transmission method further includes the step of: obtaining the preset duration based on transmission and reception impact information. The transmission and reception impact information includes transmission type and transmission distance. The transmission type is the method by which the source device transmits the target data, which includes, but is not limited to, broadcasting and power line carrier communication. The transmission distance is the distance from the source device to the master device. Both the transmission type and the transmission distance affect the specific value of the preset duration.

[0089] Specifically, the target data carries a device tag for the source device. This device tag indicates information such as the method the source device uses to transmit data, the model of the source device, and the location of the source device. After the master device receives the target data, it can obtain relevant information about the source device through the device tag and determine the transmission type and transmission distance.

[0090] In one embodiment of this application, the master device in the local area network is automatically updated. Specifically, after any receiving device determines itself to be the master device, it sends an identity verification command to other receiving devices; after receiving the identity verification command, the other receiving devices determine that the receiving device that sent the identity verification command is the master device.

[0091] Once any receiving device identifies itself as the master device, it begins timing and waits for a preset update cycle. This update cycle is the master device's identity switching cycle; every update cycle, the master device will switch its master device identity to another receiving device, thus updating its master device status.

[0092] Specifically, after waiting for a preset update cycle, the master device sends an identity update command to another receiving device. The receiving device that receives the identity update command determines itself as the master device, thereby completing the update of the master device's identity.

[0093] Specifically, in the step of the master device sending an identity update instruction to another receiving device, the master device can send the identity update instruction to the next receiving device according to a preset update order; the master device can also send the identity update instruction to another receiving device randomly.

[0094] Correspondingly, the data transmission method also includes the following steps: after the master device waits for a preset update period, it sends an identity update instruction to another receiving device; after any receiving device determines that it is the master device, it sends an identity confirmation instruction to other receiving devices.

[0095] Please see Figure 8In one embodiment of this application, all slave devices send feedback information carrying tag information to the master device upon receiving target data. After the target device receives the target data, it also sends feedback information to the master device. The master device can determine whether there are any slave devices in the local area network that have not yet received the target data by using all the received feedback information.

[0096] Specifically, after step S303, the data transmission method further includes the following steps:

[0097] S304. Receive feedback information and wait for the set duration.

[0098] S305. After waiting for the set time, determine whether all slave devices in the local area network have sent feedback information. If yes, return to step S302; otherwise, end.

[0099] In one embodiment of this application, the set duration may be consistent with the preset duration. In some feasible embodiments, the set duration may also be inconsistent with the preset duration.

[0100] In one embodiment of this application, once the master device determines that it and all slave devices have received the target data, the data transmission task is considered complete. The master device records statistical data from this data transmission task and stores it in the background database. The statistical data includes the time points when each receiving device sends feedback information, the time points when it sends the target data, and the number of times the target data was not received, so that the background administrator can maintain and manage the various receiving devices in the local area network based on the statistical data.

[0101] In one embodiment of this application, the local area network (LAN) is a wireless LAN, where each receiving device transmits data to each other via Wi-Fi. Alternatively, the LAN can be a wired LAN, where each receiving device is connected to the same Ethernet network via a network cable for data transmission.

[0102] It is understood that in some embodiments, the receiving devices may also use communication methods such as Bluetooth, as long as they can achieve stable data transmission between the receiving devices over a short distance.

[0103] It is understood that the embodiments of this application use a local area network (LAN) as an example for illustration. The LAN is configured with a master device, and the slave devices in the LAN can be regarded as forming a cluster around the master device. The cluster has the characteristic that the receiving devices are relatively close to each other.

[0104] In some embodiments, there may be multiple local area networks (LANs), and these LANs are independent of each other, with each LAN corresponding to a master device. When a source device simultaneously sends target data to various receiving devices in multiple LANs, the master devices in each LAN can independently use the data transmission method provided in this application to transmit the target data within their respective LANs, ensuring that all receiving devices can receive the target data.

[0105] For ease of understanding, the following describes the process of data transmission to the target device by combining the source device, master device, first slave device, and second slave device.

[0106] Please see Figure 9 In one embodiment of this application, the process of transmitting the target data includes:

[0107] The source device sends the target data;

[0108] The master device receives the target data and begins waiting for a preset time; the first slave device then receives the target data.

[0109] The first step is for the slave device to send feedback information to the master device;

[0110] After waiting for a preset time, the master device determines the second slave device as the target device;

[0111] The master device sends target data to the target device.

[0112] In the above embodiments, the master device receives the target data itself. After receiving the target data, the master device waits for a preset time and, after determining the target data, directly sends the target data to the target device.

[0113] Please see Figure 10 In another embodiment of this application, the process of transmitting the target data includes:

[0114] The source device sends the target data;

[0115] The master device receives the target data, and the first slave device receives the target data.

[0116] The first step is for the slave device to send feedback information to the master device;

[0117] The master device receives the feedback information and begins waiting for a preset time.

[0118] After waiting for a preset time, the master device determines the second slave device as the target device;

[0119] The master device sends target data to the target device.

[0120] In the above embodiments, the master device receives the target data itself. After receiving the feedback information, the master device waits for a preset time and, after determining the target data, directly sends the target data to the target device.

[0121] Please see Figure 11 In another embodiment of this application, the process of transmitting the target data includes:

[0122] The source device sends the target data;

[0123] The master device receives the target data and waits for a preset time before the first slave device receives the target data.

[0124] The first step is for the slave device to send feedback information to the master device;

[0125] After waiting for a preset time, the master device determines the second slave device as the target device;

[0126] The master device sends a data transmission command to the first slave device;

[0127] First, the device receives a data transmission instruction and sends the target data to the target device.

[0128] In the above embodiments, the master device receives the target data itself. After receiving the target data, the master device waits for a preset time. After determining the target data, it requests the first slave device to send the target data to the target device.

[0129] Please see Figure 12 In another embodiment of this application, the process of transmitting the target data includes:

[0130] The source device sends the target data;

[0131] The master device receives the target data, and the first slave device receives the target data.

[0132] The first step is for the slave device to send feedback information to the master device;

[0133] The master device receives the feedback information and begins waiting for a preset time.

[0134] After waiting for a preset time, the master device determines the second slave device as the target device;

[0135] First, the device receives a data transmission instruction and sends the target data to the target device.

[0136] In the above embodiments, the master device receives the target data itself. After receiving the feedback information, the master device starts to wait for a preset time. After determining the target data, it requests the first slave device to send the target data to the target device.

[0137] Please see Figure 13In another embodiment of this application, the process of transmitting the target data includes:

[0138] The source device sends the target data;

[0139] The first slave device received the target data, but the master device did not receive the target data.

[0140] The first step is for the slave device to send feedback information to the master device;

[0141] Upon receiving the feedback information, the master device begins waiting for a preset duration and sends a data acquisition command to the first slave device.

[0142] The first step is to receive a data acquisition instruction from the slave device and send the target data to the master device.

[0143] After waiting for a preset time, the master device determines the second slave device as the target device;

[0144] The master device sends target data to the target device.

[0145] In the above embodiment, the master device sends a data acquisition instruction to the first slave device to obtain the target data. After receiving the feedback information, the master device waits for a preset time and, after determining the target data, directly sends the target data to the target device.

[0146] Please see Figure 14 In another embodiment of this application, the process of transmitting the target data includes:

[0147] The source device sends the target data;

[0148] The first slave device received the target data, but the master device did not receive the target data.

[0149] The first step is for the slave device to send feedback information to the master device;

[0150] Upon receiving the feedback information, the master device begins waiting for a preset duration and sends a data acquisition command to the first slave device.

[0151] The first step is to receive a data acquisition instruction from the slave device and send the target data to the master device.

[0152] After waiting for a preset time, the master device determines the second slave device as the target device;

[0153] The master device sends a data transmission command to the first slave device;

[0154] First, the device receives a data transmission instruction and sends the target data to the target device.

[0155] In the above embodiments, the master device sends a data acquisition command to the first slave device to obtain target data. After receiving feedback information, the master device waits for a preset time, and after determining the target data, requests the first slave device to send the target data to the target device. The master device can simultaneously send both a data acquisition command and a data transmission command to the first slave device.

[0156] It is understandable that after the source device sends the target data, although some of the multiple receiving devices may fail to receive the target data, under normal circumstances, at least one receiving device should receive the target data.

[0157] Therefore, this application uses a first slave device quantity greater than or equal to 1 as an example. In extreme cases, if only the master device in the local area network receives the target data, the first slave device quantity can also be 0. In this case, since the master device receives the target data but does not receive feedback information, it will identify all slave devices as target devices and send the target data to the target devices.

[0158] The implementation principle of the data transmission method provided in this application is as follows: after the source device sends the target data, there should be at least one receiving device in the local area network that has received the target data. If the receiving device is the master device, the master device can directly determine that the source device has sent the target data; if the receiving device is the first slave device, the master device can directly determine that the source device has sent the target data through the feedback information of the first slave device.

[0159] Once the master device determines that the source device has sent the target data, it waits for a preset time and counts the second slave devices on the local area network that have not sent feedback information, thus identifying the target device that has not received the target data from the source device. Then, the master device either sends the target data directly to the target device or instructs the first slave device to send the target data to the target device, ensuring that the target device can receive the target data. Therefore, even if some receiving devices initially fail to receive the target data after the source device has sent it, the master device or the first slave device that has received the target data can still send it, ensuring that both the master device and all slave devices can receive the target data.

[0160] Therefore, the source device only needs to send the target data once, and the master device and all slave devices can receive the target data. The source device does not need to resend the target data due to a second slave device not receiving it, reducing the waste of communication resources. Furthermore, since the master and slave devices are on the same local area network, the data transmission between them is more stable, ensuring that the target data is sent to the corresponding object, thus improving the reliability of data transmission.

[0161] Figure 15This is a flowchart illustrating a data transmission method provided in an embodiment of this application. The data transmission method is applied to a first slave device of the receiving device described above. Specifically, the data transmission method includes the following steps.

[0162] S1501: Receive target data sent by the source device and send feedback information to the master device.

[0163] S1502, Receive data transmission command sent by the master device.

[0164] S1503. Send target data to the target device according to the data sending instruction.

[0165] The target device is the second slave device in the local area network that has not sent feedback information to the master device. The master device, the first slave device, and the second slave device are in the same local area network, while the source device is not in the local area network.

[0166] Please see Figure 16 In one embodiment of this application, the data transmission method includes the following steps.

[0167] S1601, Receive data acquisition command sent by the master device.

[0168] S1602. Send the target data to the master device according to the data acquisition instruction.

[0169] It is understood that the beneficial effects of the data transmission method applied to the first slave device provided in the embodiments of this application can be referred to the beneficial effects of the corresponding data transmission method applied to the master device provided above, and will not be repeated here.

[0170] Figure 17 This is a functional module diagram of a data transmission device provided for an embodiment of this application. The data transmission device is applied to a main device. The data transmission device includes:

[0171] The receive trigger module 1 is used to wait for a preset time after receiving target data sent by the source device or feedback information sent by the first slave device. The feedback information is the information sent by the first slave device to the master device after receiving the target data.

[0172] Target analysis module 2 is used to identify the second slave device that has not sent feedback information in the local area network as the target device after waiting for a preset time. The master device, the first slave device, and the second slave device are in the same local area network, while the source device is not in the local area network.

[0173] Data transmission module 3 is used to send target data to the target device, or to send a data transmission command to the first slave device. The data transmission command instructs the first slave device to send the target data to the target device.

[0174] It is understood that the module division described above is a logical functional division, and there may be other division methods in actual implementation. Furthermore, the functional modules in the various embodiments of this application can be integrated into the same processing unit, or each module can exist physically separately, or two or more modules can be integrated into the same unit. The integrated modules described above can be implemented in hardware or in a combination of hardware and software functional modules.

[0175] Figure 18 This is a schematic diagram of the structure of an electronic device 10 provided in an embodiment of this application. The electronic device 10 includes a processor 11 and a memory 12, wherein the memory 12 is used to store executable instructions of the processor 11. The processor 11 executes the executable instructions to enable the electronic device 10 to implement the data transmission method applied to a master device as described in the above technical solution, or to implement the data transmission method applied to a first slave device as described in the above technical solution.

[0176] The processor 11 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.

[0177] The memory 12 can be used to store the computer programs and / or modules. The processor 11 implements various functions of the electronic device 10 by running or retrieving the computer programs and / or modules stored in the memory 12, and by calling the data stored in the memory 12. The memory 12 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device 10, etc. In addition, the memory 12 may include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, at least one disk storage device, flash memory device, or other non-volatile solid-state storage device.

[0178] The memory 12 can be an external memory and / or an internal memory of the electronic device 10. Furthermore, the memory 12 can be a physical memory, such as a memory module, a TF card (Trans-flash Card), etc.

[0179] If the program code and various data in the memory 12 are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments, such as data transmission methods, can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), etc.

[0180] Figure 19 This is a schematic diagram of a data transmission system provided in an embodiment of this application. The data transmission system includes a first electronic device 20 and a second electronic device 30. The first electronic device 20 can be the electronic device 10 described above that implements the data transmission method applied to a master device, and the second electronic device 30 can be the electronic device 10 described above that implements the data transmission method applied to a first slave device. It can be understood that the first electronic device 20 can be regarded as a master device, and the second electronic device 30 can be regarded as a first slave device.

[0181] It is understood that the beneficial effects of the data transmission device, electronic device 10 and data transmission system provided in the embodiments of this application can be referred to the beneficial effects of the corresponding data transmission methods provided above, and will not be repeated here.

[0182] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application and are not intended to limit it. Although this application has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of this application without departing from the spirit and scope of the technical solutions of this application.

Claims

1. A data transmission method, characterized in that, Applied to the main equipment, including: Upon receiving target data sent by the source device, or upon receiving feedback information sent by the first slave device, wait for a preset time; the feedback information is information sent by the first slave device to the master device after receiving the target data; the feedback information carries the tag information of the first slave device, so that the master device can determine the identity of the first slave device based on the feedback information after receiving the feedback information; After the preset waiting time, the second slave device in the local area network that has not sent the feedback information is identified as the target device; wherein, the master device, the first slave device, and the second slave device are in the same local area network, and the source device is not in the local area network; the master device records the first slave device that sent the feedback information in the first device list, and by comparing the first device list with the second device list of all slave devices in the local area network, the second slave device that exists in the second device list but has not sent the feedback information is obtained and identified as the target device; The target data is sent to the target device, or a data sending instruction is sent to the first slave device; the data sending instruction is used to instruct the first slave device to send the target data to the target device.

2. The data transmission method according to claim 1, characterized in that, The method further includes: When the feedback information sent by the first slave device is received, but the target data sent by the source device is not received, a data acquisition instruction is sent to the first slave device, the data acquisition instruction being used to instruct the first slave device to send the target data to the master device; Receive the target data sent by the first slave device.

3. The data transmission method according to claim 1 or 2, characterized in that, Sending the target data to the target device includes: Upon receiving the target data sent by the source device, or upon receiving the target data sent by the first slave device, the target data is sent to the target device.

4. The data transmission method according to claim 1, characterized in that, The method further includes: receiving the target data sent by the source device via broadcast.

5. A data transmission method, characterized in that, Applied to the first slave device, including: The system receives target data sent by the source device and sends feedback information to the master device. The feedback information carries the tag information of the first slave device, so that the master device can determine the identity of the first slave device based on the feedback information after receiving it. Receive the data transmission command sent by the master device; According to the data sending instruction, the target data is sent to the target device; the target device is a second slave device in the local area network that has not sent the feedback information to the master device. The master device, the first slave device, and the second slave device are in the same local area network, while the source device is not in the local area network. The master device records the first slave device that sent the feedback information in the first device list. By comparing the first device list with the second device list of all slave devices in the local area network, the master device obtains the second slave device that exists in the second device list but has not sent the feedback information, and determines it as the target device.

6. The data transmission method according to claim 5, characterized in that, The method further includes: Receive the data acquisition command sent by the master device; According to the data acquisition instruction, the target data is sent to the master device.

7. A data transmission device, characterized in that, Applied to the main equipment, including: A receiving trigger module is used to wait for a preset time when it receives target data sent by a source device or feedback information sent by a first slave device; the feedback information is information sent by the first slave device to the master device after receiving the target data; the feedback information carries the tag information of the first slave device so that the master device can determine the identity of the first slave device based on the feedback information after receiving the feedback information. The target analysis module is used to identify the second slave device in the local area network that has not sent the feedback information as the target device after the preset waiting time; wherein the master device, the first slave device, and the second slave device are in the same local area network, and the source device is not in the local area network; the master device records the first slave device that sent the feedback information in the first device list, and by comparing the first device list with the second device list of all slave devices in the local area network, obtains the second slave device that exists in the second device list but has not sent the feedback information, and identifies it as the target device; The data transmission module is used to send the target data to the target device, or to send a data transmission instruction to the first slave device; the data transmission instruction is used to instruct the first slave device to send the target data to the target device.

8. An electronic device, characterized in that, include: processor; as well as Memory for storing the executable instructions of the processor; The processor executes the executable instructions to cause the electronic device to implement the method as described in any one of claims 1 to 4.

9. An electronic device, characterized in that, include: processor; as well as Memory for storing the executable instructions of the processor; The processor executes the executable instructions to cause the electronic device to implement the method as described in any one of claims 5 to 6.

10. A data transmission system, characterized in that, Includes the electronic device as described in claim 8 and the electronic device as described in claim 9.

Citation Information

Patent Citations

  • Data transmission method and device and medium

    CN113703364A