Data transmission method and apparatus, device, and storage medium

By displaying Bluetooth transmission controls on the data transmission page, the system automatically scans and selects target Bluetooth devices for data transmission, solving the problem of cumbersome transmission processes between devices and improving transmission efficiency.

WO2026046099A1PCT designated stage Publication Date: 2026-03-05XIAN UNISOC TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/116649
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-08-28
Filing Date
2025-08-25
Publication Date
2026-03-05

AI Technical Summary

Technical Problem

The data transmission process between devices is cumbersome, resulting in low transmission efficiency.

Method used

By displaying Bluetooth transmission controls on the data transmission page, the system responds to user actions to scan for Bluetooth devices within a preset range, automatically identifies the target Bluetooth device based on device information, and performs data transmission.

Benefits of technology

Without requiring users to manually select Bluetooth devices, the target Bluetooth device can be quickly identified through scanning results and device information, improving the efficiency of data transmission between devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025116649_05032026_PF_FP_ABST
    Figure CN2025116649_05032026_PF_FP_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a data transmission method and apparatus, a device, and a storage medium. The method comprises: displaying a Bluetooth transmission control on a data transmission page; in response to a selection operation of a user on the Bluetooth transmission control, scanning a Bluetooth device within a preset range to obtain a scanning result, the scanning result comprising device information of at least one Bluetooth device and the number of Bluetooth devices; determining whether the number of Bluetooth devices is greater than 1, if yes, determining a target Bluetooth device on the basis of device information of a plurality of Bluetooth devices, and if not, determining the Bluetooth device as the target Bluetooth device; and transmitting data to the target Bluetooth device. The method of the present application improves the efficiency of data transmission between devices.
Need to check novelty before this filing date? Find Prior Art

Description

Data transmission methods, apparatus, equipment and storage media

[0001] This application claims priority to Chinese Patent Application No. 202411195661.4, filed on August 28, 2024, entitled "Data Transmission Method, Apparatus, Device and Storage Medium", the entire contents of which are incorporated herein by reference. Technical Field

[0002] This application belongs to the technical field of data processing, specifically relating to a data transmission method, apparatus, device, and storage medium. Background Technology

[0003] In the field of Bluetooth technology, data transmission between devices can be achieved through the Object Push Profile (OPP) protocol. The data can include photos, files, documents, etc.

[0004] Currently, the data transmission process between devices is as follows: The terminal device enables Bluetooth and searches for nearby Bluetooth devices; the user on the terminal device selects the target Bluetooth device, selects the data to be transmitted on the terminal device, and generates a transmission request; the transmission request is sent to the target Bluetooth device; after receiving the transmission request, the target Bluetooth device will prompt the user of the target Bluetooth device whether to accept the transmission; if the user of the target Bluetooth device accepts the transmission, the terminal device transmits the data to the target Bluetooth device.

[0005] In the above process, the data transmission between devices is quite cumbersome, resulting in low efficiency in data transmission between devices. Summary of the Invention

[0006] This application relates to a data transmission method, apparatus, device, and storage medium, which addresses the shortcomings of the prior art where the process of data transmission between devices is cumbersome, resulting in low efficiency in data transmission between devices.

[0007] In a first aspect, embodiments of this application provide a data transmission method applied in a terminal device, the method comprising:

[0008] Display Bluetooth transfer controls on the data transfer page;

[0009] In response to the user's selection of the Bluetooth transmission control, the system scans for Bluetooth devices within a preset range and obtains the scan results, which include device information of at least one Bluetooth device and the number of Bluetooth devices.

[0010] Determine whether the number of Bluetooth devices is greater than 1. If so, determine the target Bluetooth device based on the device information of multiple Bluetooth devices. If not, determine the Bluetooth device as the target Bluetooth device.

[0011] Data is transmitted to the target Bluetooth device.

[0012] In one possible implementation, the device information includes signal strength, and determining the target Bluetooth device based on the device information of multiple Bluetooth devices includes:

[0013] The multiple Bluetooth devices are sorted in descending order of signal strength;

[0014] The judgment step includes: determining whether the i-th Bluetooth device meets the preset conditions, where i is initially 1;

[0015] If yes, then the i-th Bluetooth device is determined as the target Bluetooth device; if no, then i is updated to i+1, and the judgment step is executed until the target Bluetooth device is determined, or, if the multiple Bluetooth devices do not meet the preset conditions respectively, the Bluetooth device with the strongest signal strength is determined as the target Bluetooth device.

[0016] In one possible implementation, determining whether the i-th Bluetooth device meets preset conditions includes:

[0017] Determine whether the i-th Bluetooth device has historical data, wherein the historical data is a record of accepting a transmission or a record of rejecting a transmission;

[0018] If so, obtain at least one historical record information corresponding to the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the at least one historical record information;

[0019] If not, send a transmission request to the i-th Bluetooth device, obtain the transmission response sent by the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the transmission response.

[0020] In one possible implementation, determining whether the i-th Bluetooth device meets preset conditions based on the at least one historical record information includes:

[0021] Based on the at least one historical record information, the priority weight of the i-th Bluetooth device is determined;

[0022] If the priority weight is greater than the threshold, determine whether the latest historical record information corresponding to the i-th Bluetooth device is the received transmission record. If yes, determine that the i-th Bluetooth device meets the preset conditions; otherwise, determine that the i-th Bluetooth device does not meet the preset conditions.

[0023] If the priority weight is not greater than the threshold, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0024] In one possible implementation, the transmission response includes an accept response and a reject response. Based on the transmission response, determining whether the i-th Bluetooth device meets preset conditions includes:

[0025] If the transmission response is the acceptance response, it is determined that the i-th Bluetooth device meets the preset conditions;

[0026] If the transmission response is the rejection response, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0027] In one possible implementation, after obtaining the transmission response sent by the i-th Bluetooth device:

[0028] Based on the transmission response, establish the historical transmission information corresponding to the i-th Bluetooth device.

[0029] In one possible implementation, a Bluetooth transmission control is displayed on the data transmission page, including:

[0030] Obtain the Bluetooth transmission mode of the terminal device, wherein the Bluetooth transmission mode is either automatic transmission mode or manual transmission mode;

[0031] When the Bluetooth transmission mode is determined to be automatic transmission mode, a Bluetooth transmission control is displayed on the data transmission page.

[0032] Secondly, embodiments of this application provide a data transmission apparatus, applied in a terminal device, the apparatus comprising:

[0033] The display module is used to display Bluetooth transmission controls on the data transmission page;

[0034] The scanning module is used to scan for Bluetooth devices within a preset range in response to the user's selection operation of the Bluetooth transmission control, and obtain the scanning results, which include device information of at least one Bluetooth device and the number of Bluetooth devices.

[0035] The judgment module is used to determine whether the number of Bluetooth devices is greater than 1. If so, it determines the target Bluetooth device based on the device information of multiple Bluetooth devices. If not, it determines the Bluetooth device as the target Bluetooth device.

[0036] A transmission module is used to transmit data to the target Bluetooth device.

[0037] In one possible implementation, the device information includes signal strength, and the determination module is specifically used for:

[0038] The multiple Bluetooth devices are sorted in descending order of signal strength;

[0039] The judgment step includes: determining whether the i-th Bluetooth device meets the preset conditions, where i is initially 1;

[0040] If yes, then the i-th Bluetooth device is determined as the target Bluetooth device; if no, then i is updated to i+1, and the judgment step is executed until the target Bluetooth device is determined, or, if the multiple Bluetooth devices do not meet the preset conditions respectively, the Bluetooth device with the strongest signal strength is determined as the target Bluetooth device.

[0041] In one possible implementation, the determination module is specifically used for:

[0042] Determine whether the i-th Bluetooth device has historical data, wherein the historical data is a record of accepting a transmission or a record of rejecting a transmission;

[0043] If so, obtain at least one historical record information corresponding to the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the at least one historical record information;

[0044] If not, send a transmission request to the i-th Bluetooth device, obtain the transmission response sent by the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the transmission response.

[0045] In one possible implementation, the determination module is specifically used for:

[0046] Based on the at least one historical record information, the priority weight of the i-th Bluetooth device is determined;

[0047] If the priority weight is greater than the threshold, determine whether the latest historical record information corresponding to the i-th Bluetooth device is the received transmission record. If yes, determine that the i-th Bluetooth device meets the preset conditions; otherwise, determine that the i-th Bluetooth device does not meet the preset conditions.

[0048] If the priority weight is not greater than the threshold, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0049] In one possible implementation, the transmission response includes an accept response and a reject response, and the determination module is specifically used for:

[0050] If the transmission response is the acceptance response, it is determined that the i-th Bluetooth device meets the preset conditions;

[0051] If the transmission response is the rejection response, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0052] In one possible implementation, the device further includes a storage module, the storage module being used for:

[0053] Based on the transmission response, establish the historical transmission information corresponding to the i-th Bluetooth device.

[0054] In one possible implementation, the display module is specifically used for:

[0055] Obtain the Bluetooth transmission mode of the terminal device, wherein the Bluetooth transmission mode is either automatic transmission mode or manual transmission mode;

[0056] When the Bluetooth transmission mode is determined to be automatic transmission mode, a Bluetooth transmission control is displayed on the data transmission page.

[0057] Thirdly, this application provides a chip on which a computer program is stored, and when the computer program is executed by the chip, it implements the data transmission method as described in any of the first aspects.

[0058] Fourthly, this application provides a chip module on which a computer program is stored, and when the computer program is executed by the chip module, it implements the data transmission method as described in any of the first aspects.

[0059] Fifthly, embodiments of this application provide an electronic device, including: a memory, a processor, and a transceiver;

[0060] The memory stores computer-executed instructions;

[0061] The processor executes computer execution instructions stored in the memory to implement the data transfer method as described in any of the first aspects.

[0062] In a sixth aspect, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the data transmission method described in any one of the first aspects.

[0063] In a seventh aspect, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the data transmission method described in any one of the first aspects.

[0064] This application provides a data transmission method, apparatus, device, and storage medium. In this method, a Bluetooth transmission control is displayed on a data transmission page. In response to a user's selection of the Bluetooth transmission control, a scan of Bluetooth devices within a preset range is performed to obtain scan results. The scan results include device information and the number of Bluetooth devices. It is determined whether the number of Bluetooth devices is greater than one. If so, a target Bluetooth device is identified based on the device information of multiple Bluetooth devices. If not, the target Bluetooth device is identified, and data is transmitted to it. This eliminates the need for the user to manually select a Bluetooth device for transmission. By using the scan results and the device information of the Bluetooth devices, the target Bluetooth device can be quickly and automatically identified, improving the efficiency of data transmission between devices. Attached Figure Description

[0065] To more clearly illustrate the technical solutions in this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0066] Figure 1 is a schematic diagram of an application scenario provided by an embodiment of this application;

[0067] Figure 2 is a flowchart illustrating a data transmission method provided in an embodiment of this application;

[0068] Figure 3 is a flowchart illustrating another data transmission method provided in an embodiment of this application;

[0069] Figure 4 is a schematic diagram of a data transmission device provided in an embodiment of this application;

[0070] Figure 5 is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.

[0071] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0072] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0073] It should be noted that although the terms "first," "second," etc., are used to describe various types of information in the embodiments of this application, this information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. Optionally, without departing from the scope of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information.

[0074] It should be understood that the terms "comprising" or "including" indicate the presence of the previously mentioned features, steps, or operations, but do not preclude the presence, occurrence, or addition of one or more other features, steps, or operations. The terms "and / or," etc., used in this application can be interpreted as inclusive, or mean any one or any combination thereof. Optionally, "A and / or B" means "any one of the following: A; B; A and B." Additionally, the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0075] In the field of Bluetooth technology, data transmission between devices can be achieved through the Object Push Profile (OPP) protocol. The data can include photos, files, documents, etc.

[0076] The following examples, with reference to Figure 1, illustrate the application scenarios corresponding to the data transmission process.

[0077] Figure 1 is a schematic diagram of an application scenario provided by an embodiment of this application. Referring to Figure 1, Figure 1 may include a terminal device 101 and multiple Bluetooth devices 102.

[0078] Terminal device 101 can establish communication connections with multiple Bluetooth devices 102.

[0079] When the Bluetooth function is enabled on the terminal device 101, multiple Bluetooth devices 102 can be found.

[0080] The user selects the Bluetooth device 102 to transmit data through the terminal device 101, selects the data to be transmitted on the terminal device 101, generates a transmission request, and sends the transmission request to the Bluetooth device 102.

[0081] After receiving a transmission request, the Bluetooth device 102 can prompt the user of the Bluetooth device whether to accept the transmission. If the user accepts the transmission, the terminal device 101 transmits data to the Bluetooth device 102.

[0082] In the above process, the data transmission between devices is quite cumbersome, resulting in low efficiency in data transmission between devices.

[0083] To address the aforementioned technical problems, this application provides a data transmission method. By scanning Bluetooth devices within a preset range, the method obtains scan results and determines whether the number of Bluetooth devices in the scan results is greater than one. If so, the target Bluetooth device is determined based on the device information of the multiple Bluetooth devices; otherwise, the target Bluetooth device is selected and data is transmitted to it. This eliminates the need for users to manually select Bluetooth devices for transmission. By using the scan results and the device information of the Bluetooth devices, the target Bluetooth device can be quickly and automatically determined, improving the efficiency of data transmission between devices.

[0084] The technical solutions shown in this application will now be described in detail through specific embodiments. It should be noted that the following embodiments may exist independently or in combination with each other; for the same or similar content, the description will not be repeated in different embodiments.

[0085] Figure 2 is a schematic flowchart of a data transmission method provided in an embodiment of this application. The executing entity in this embodiment can be a terminal device or a data transmission device installed in the terminal device. The data transmission device can be implemented through software or through a combination of software and hardware.

[0086] Please refer to Figure 2. The method includes:

[0087] S201. Display the Bluetooth transmission control on the data transmission page.

[0088] The data transfer page allows users to select the data to be transferred and then transfer the data.

[0089] A Bluetooth transmission control is a control that enables Bluetooth data transmission.

[0090] It can display a data transfer page, which may include multiple data and Bluetooth transfer controls.

[0091] Among them, multiple data points can be data that can be transmitted.

[0092] Multiple data can be images, videos, files, etc., and there are no restrictions here.

[0093] Optionally, the Bluetooth transmission control can be displayed on the data transmission page by: obtaining the Bluetooth transmission mode of the terminal device; and displaying the Bluetooth transmission control on the data transmission page when the Bluetooth transmission mode is determined to be automatic transmission mode.

[0094] The Bluetooth transmission mode can be either automatic or manual.

[0095] Automatic transfer mode can automatically select the target Bluetooth device for Bluetooth transfer.

[0096] Manual transfer mode allows users to manually select the target Bluetooth device for Bluetooth transfer.

[0097] S202. In response to the user's selection of the Bluetooth transmission control, scan for Bluetooth devices within the preset range and obtain the scan results.

[0098] The selection operation can be either a click or a touch operation; there is no limitation here.

[0099] The preset range can be the range that the terminal device can scan.

[0100] A Bluetooth device can be a device with Bluetooth transmission capabilities.

[0101] The scan results may include device information for at least one Bluetooth device and the number of Bluetooth devices.

[0102] In some cases, if no Bluetooth device is found within the preset range, the scan results may also not contain any Bluetooth device information. In such cases, data transmission is not possible.

[0103] It can respond to the user's selection of the Bluetooth transmission control, call the Bluetooth application programming interface, broadcast Bluetooth signals within a preset range, scan for Bluetooth devices within the preset range, and obtain the scan results.

[0104] S203. Determine if the number of Bluetooth devices is greater than 1. If yes, determine the target Bluetooth device based on the device information of multiple Bluetooth devices. If no, determine the target Bluetooth device as the Bluetooth device.

[0105] Device information may include device name, device type, signal strength, etc.

[0106] The target Bluetooth device can be the Bluetooth device to which data is to be transmitted.

[0107] It can determine whether the number of Bluetooth devices is greater than 1. If so, it can identify the target Bluetooth device based on the signal strength and / or device type of the multiple Bluetooth devices. If not, it can identify the Bluetooth device as the target Bluetooth device.

[0108] Alternatively, the target Bluetooth device can be determined based on the signal strength of multiple Bluetooth devices in the following way: the Bluetooth device with the strongest signal strength among the multiple Bluetooth devices can be identified as the target Bluetooth device.

[0109] Optionally, the target Bluetooth device can be determined based on the signal strength and device type of multiple Bluetooth devices in the following way: at least one first Bluetooth device of a preset type can be determined from the multiple Bluetooth devices, and the first Bluetooth device with the largest signal strength among the at least one first Bluetooth device can be determined as the target Bluetooth device.

[0110] Optionally, the target Bluetooth device can be determined based on the device information of multiple Bluetooth devices in the following way: sort the multiple Bluetooth devices in descending order of signal strength; perform a judgment step, which includes: determining whether the i-th Bluetooth device meets the preset conditions, initially i is 1; if yes, then determine the i-th Bluetooth device as the target Bluetooth device; if no, then update i to i+1 and perform the judgment step until the target Bluetooth device is determined, or, if multiple Bluetooth devices do not meet the preset conditions respectively, determine the Bluetooth device with the strongest signal strength as the target Bluetooth device.

[0111] It should be noted that the target Bluetooth device can be determined based on the device information of multiple Bluetooth devices through any feasible implementation method, and the embodiments of this application do not limit this.

[0112] S204. Transmit data to the target Bluetooth device.

[0113] It can establish a Bluetooth connection with the target Bluetooth device and transmit data to the target Bluetooth device.

[0114] Alternatively, data can be transmitted by packaging the data into multiple data packets, and then transmitting each data packet separately.

[0115] The data transmission method provided in this embodiment displays a Bluetooth transmission control on the data transmission page. In response to the user's selection of the Bluetooth transmission control, it scans for Bluetooth devices within a preset range, obtaining scan results. The scan results include device information and the number of Bluetooth devices at least one. It determines whether the number of Bluetooth devices is greater than one. If so, it identifies the target Bluetooth device based on the device information of multiple Bluetooth devices; otherwise, it designates the target Bluetooth device and transmits data to it. This eliminates the need for the user to manually select a Bluetooth device for transmission. By using the scan results and the device information of the Bluetooth devices, the target Bluetooth device can be quickly and automatically identified, improving the efficiency of data transmission between devices.

[0116] The process of determining the target Bluetooth device based on the device information of multiple Bluetooth devices (S203) will be explained below with reference to Figure 3.

[0117] Figure 3 is a flowchart illustrating another data transmission method provided in an embodiment of this application. Based on the above embodiments, referring to Figure 3, the method includes:

[0118] S301. Sort multiple Bluetooth devices in descending order of signal strength.

[0119] The signal strength of multiple Bluetooth devices can be determined, and the devices can be sorted in descending order of signal strength to obtain a device sequence.

[0120] Device sequence can be used to determine the order in which multiple Bluetooth devices are the target Bluetooth device.

[0121] S302. Initialize i to 1.

[0122] S303. Determine whether the i-th Bluetooth device has historical record information.

[0123] If so, then execute S304;

[0124] If not, then execute S308.

[0125] Historical records show whether a transmission was accepted or rejected.

[0126] It can obtain Bluetooth device information, which includes device identifiers corresponding to multiple Bluetooth devices and historical information corresponding to each Bluetooth device. It can determine whether the Bluetooth device information includes the device identifier corresponding to the i-th Bluetooth device. If yes, it is determined that historical information exists; otherwise, it is determined that historical information does not exist.

[0127] For example, Bluetooth device information can be shown in Table 1:

[0128] Table 1

[0129] S304. Obtain at least one historical record information corresponding to the i-th Bluetooth device.

[0130] At least one historical record can be determined from the Bluetooth device information for the i-th Bluetooth device.

[0131] S305. Determine the priority weight of the i-th Bluetooth device based on at least one historical record.

[0132] Priority weights can be used to represent the probability that the Bluetooth device is the target Bluetooth device.

[0133] Priority weights can be determined using at least one piece of historical information.

[0134] Optionally, the priority weight is calculated as follows: determine a first number of accepted transmission records and a second number of rejected transmission records in at least one historical record; determine a first weight value based on the first number; determine a second weight value based on the second number; and determine the sum of the first weight value and the second weight value as the priority weight.

[0135] Optionally, the priority weight is calculated as follows: It can be determined whether the number of records corresponding to at least one historical record is greater than 1. If so, the multiple historical records are sorted in order from oldest to newest. The weight value corresponding to the first historical record is determined based on the first historical record. The weight value corresponding to the i-th historical record is determined based on the i-th and (i-1)-th historical records, where i takes the values ​​2, ..., n, and n is the number of records corresponding to the multiple historical records. The sum of the multiple weight values ​​is then determined as the priority weight. If not, the priority weight is determined based on the historical records.

[0136] Among them, the weight value corresponding to the i-th historical record information can be determined based on the i-th historical record information and the (i-1)-th historical record information in the following ways:

[0137] Case 1: The (i-1)th historical record is an accepted transmission record, and the ith historical record is a rejected transmission record. The weight value corresponding to the ith historical record is determined to be the first weight value, for example, the first weight value is -2.

[0138] Case 2: The (i-1)th historical record is a rejected transmission record, and the ith historical record is an accepted transmission record. The weight value corresponding to the ith historical record is determined to be the second weight value, for example, the second weight value is 2.

[0139] Case 3: If the (i-1)th historical record is a transmission rejection record and the ith historical record is a transmission rejection record, determine the weight value corresponding to the ith historical record as the third weight value, for example, the third weight value is -4;

[0140] Case 4: The (i-1)th historical record information is a received transmission record, and the ith historical record information is a received transmission record information. The weight value corresponding to the ith historical record information is determined to be the fourth weight value, for example, the fourth weight value is 4.

[0141] Optionally, after determining the priority weight of the i-th Bluetooth device, the historical number of times the i-th Bluetooth device was the target Bluetooth device in manual transmission mode is obtained from the Bluetooth device information, and the priority weight is updated based on the historical number of times.

[0142] S306. Determine whether the priority weight is greater than the threshold.

[0143] If so, then execute S307;

[0144] If not, then execute S312.

[0145] For example, a threshold of 3 can be used to determine whether the priority weight is greater than 3.

[0146] S307. Determine whether the latest historical record information corresponding to the i-th Bluetooth device is a received transmission record.

[0147] If so, then execute S311;

[0148] If not, then execute S312.

[0149] When the priority weight is greater than the threshold, it is determined whether the latest historical record information corresponding to the i-th Bluetooth device is a received transmission record. In this way, by using factors such as the signal strength, priority weight, and latest historical record information of the i-th Bluetooth device, the accuracy of identifying the target terminal can be improved.

[0150] S308, Send a transmission request to the i-th Bluetooth device.

[0151] A transmission request can be used to ask a Bluetooth device whether it will accept the transmission.

[0152] It can generate a transmission request and send the transmission request to the i-th Bluetooth device.

[0153] S309. Obtain the transmission response sent by the i-th Bluetooth device.

[0154] Obtain the response information sent by the i-th Bluetooth device, parse the response information, and obtain the transmission response sent by the i-th Bluetooth device.

[0155] Optionally, after obtaining the transmission response sent by the i-th Bluetooth device, historical transmission information corresponding to the i-th Bluetooth device can be established based on the transmission response.

[0156] In this way, historical transmission information can be updated in real time based on the transmission response, thereby improving the accuracy of identifying the target terminal.

[0157] S310. Determine whether the transmission response is an acceptance response.

[0158] If so, then execute S311;

[0159] If not, then execute S312.

[0160] If the transmission response is an accept response, then the i-th Bluetooth device is determined to meet the preset conditions;

[0161] If the transmission response is a rejection response, then the i-th Bluetooth device is determined to be non-compliant with the preset conditions.

[0162] S311. Determine that the i-th Bluetooth device meets the preset conditions, and identify the i-th Bluetooth device as the target Bluetooth device.

[0163] After S311, it ends.

[0164] S312. Determine that the i-th Bluetooth device does not meet the preset conditions, and update i to i+1.

[0165] After S312, execute S313.

[0166] S313. Determine if i is greater than the number of Bluetooth devices.

[0167] If so, then execute S314;

[0168] If not, then execute S303.

[0169] S314. Identify the Bluetooth device with the strongest signal strength as the target Bluetooth device.

[0170] Among multiple Bluetooth devices, the Bluetooth device with the strongest signal can be identified as the target Bluetooth device.

[0171] Generally, according to user habits, when transmitting data via Bluetooth, the distance between the terminals is relatively close, and the signal strength is relatively strong.

[0172] The implementation details of each step in this application embodiment can be found in the description of the corresponding steps or operations in the above method embodiments; repeated content will not be repeated.

[0173] The data transmission method provided in this embodiment sorts multiple Bluetooth devices according to their signal strength from largest to smallest; it then performs a judgment step, which includes: determining whether the i-th Bluetooth device has historical data, which may be a transmission acceptance record or a transmission rejection record; if so, acquiring at least one historical data record corresponding to the i-th Bluetooth device and determining the priority weight of the i-th Bluetooth device based on the at least one historical data record; if the priority weight is greater than a threshold, determining whether the latest historical data record corresponding to the i-th Bluetooth device is a transmission acceptance record; if so, determining that the i-th Bluetooth device meets a preset condition; otherwise, determining that the i-th Bluetooth device does not meet the preset condition. The system sets conditions; if the priority weight is not greater than a threshold, the i-th Bluetooth device is determined not to meet the preset conditions; otherwise, a transmission request is sent to the i-th Bluetooth device, and the transmission response sent by the i-th Bluetooth device is obtained. If the transmission response is an accept response, the i-th Bluetooth device is determined to meet the preset conditions; if the transmission response is a reject response, the i-th Bluetooth device is determined not to meet the preset conditions. Initially, i is 1. If yes, the i-th Bluetooth device is determined as the target Bluetooth device; otherwise, i is updated to i+1, and the judgment steps are executed until the target Bluetooth device is determined. Alternatively, if multiple Bluetooth devices do not meet the preset conditions, the Bluetooth device with the strongest signal strength is determined as the target Bluetooth device. In this way, the user does not need to manually select a Bluetooth device for transmission. By using the scanning results and the device information of the Bluetooth devices, the target Bluetooth device can be quickly and automatically determined, improving the data transmission efficiency between devices.

[0174] Figure 4 is a schematic diagram of a data transmission device provided in an embodiment of this application. Referring to Figure 4, the device 400 includes a display module 401, a scanning module 402, a judgment module 403, and a transmission module 404.

[0175] Display module 401 is used to display Bluetooth transmission controls on the data transmission page;

[0176] The scanning module 402 is used to scan for Bluetooth devices within a preset range in response to the user's selection operation of the Bluetooth transmission control, and obtain the scanning results, which include device information of at least one Bluetooth device and the number of Bluetooth devices.

[0177] The judgment module 403 is used to determine whether the number of Bluetooth devices is greater than 1. If so, the target Bluetooth device is determined based on the device information of multiple Bluetooth devices. If not, the Bluetooth device is determined as the target Bluetooth device.

[0178] The transmission module 404 is used to transmit data to the target Bluetooth device.

[0179] In one possible implementation, the device information includes signal strength, and the determination module 403 is specifically used for:

[0180] The multiple Bluetooth devices are sorted in descending order of signal strength;

[0181] The judgment step includes: determining whether the i-th Bluetooth device meets the preset conditions, where i is initially 1;

[0182] If yes, then the i-th Bluetooth device is determined as the target Bluetooth device; if no, then i is updated to i+1, and the judgment step is executed until the target Bluetooth device is determined, or, if the multiple Bluetooth devices do not meet the preset conditions respectively, the Bluetooth device with the strongest signal strength is determined as the target Bluetooth device.

[0183] In one possible implementation, the determination module 403 is specifically used for:

[0184] Determine whether the i-th Bluetooth device has historical data, wherein the historical data is a record of accepting a transmission or a record of rejecting a transmission;

[0185] If so, obtain at least one historical record information corresponding to the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the at least one historical record information;

[0186] If not, send a transmission request to the i-th Bluetooth device, obtain the transmission response sent by the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the transmission response.

[0187] In one possible implementation, the determination module 403 is specifically used for:

[0188] Based on the at least one historical record information, the priority weight of the i-th Bluetooth device is determined;

[0189] If the priority weight is greater than the threshold, determine whether the latest historical record information corresponding to the i-th Bluetooth device is the received transmission record. If yes, determine that the i-th Bluetooth device meets the preset conditions; otherwise, determine that the i-th Bluetooth device does not meet the preset conditions.

[0190] If the priority weight is not greater than the threshold, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0191] In one possible implementation, the transmission response includes an acceptance response and a rejection response, and the determination module 403 is specifically used for:

[0192] If the transmission response is the acceptance response, it is determined that the i-th Bluetooth device meets the preset conditions;

[0193] If the transmission response is the rejection response, it is determined that the i-th Bluetooth device does not meet the preset conditions.

[0194] In one possible implementation, the device further includes a storage module 405, which is used for:

[0195] Based on the transmission response, establish the historical transmission information corresponding to the i-th Bluetooth device.

[0196] In one possible implementation, the display module 404 is specifically used for:

[0197] Obtain the Bluetooth transmission mode of the terminal device, wherein the Bluetooth transmission mode is either automatic transmission mode or manual transmission mode;

[0198] When the Bluetooth transmission mode is determined to be automatic transmission mode, a Bluetooth transmission control is displayed on the data transmission page.

[0199] Figure 5 is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Referring to Figure 5, the electronic device 500 may include: a memory 501, a processor 502, and a transceiver 503.

[0200] Memory 501 is used to store program instructions;

[0201] The processor 502 is used to execute the program instructions stored in the memory, so that the electronic device 500 performs any of the data transmission methods shown above.

[0202] Transceiver 503 may include a transmitter and / or a receiver. The transmitter may also be referred to as a transmitter, transmitter port, or transmitter interface, and the receiver may also be referred to as a receiver port, receiver interface, or similar descriptions. Exemplarily, memory 501, processor 502, and transceiver 503 are interconnected via bus 504.

[0203] This application also provides a chip on which a computer program is stored. When the computer program is executed by the chip, it implements the above-mentioned data transmission method. The corresponding content and effects can be referred to the method embodiment section, and will not be repeated here.

[0204] This application also provides a chip module on which a computer program is stored. When the computer program is executed by the chip module, it implements the above-mentioned data transmission method. The corresponding content and effects can be referred to the method embodiment section, and will not be repeated here.

[0205] This application also provides a computer program product that can be executed by a processor, and when the computer program product is executed, the above-described data transmission method can be implemented.

[0206] The data transmission apparatus, electronic device, computer-readable storage medium, and computer program product of the embodiments of this application can execute the technical solutions shown in the above-described data transmission method embodiments. Their implementation principles and beneficial effects are similar, and will not be described again here.

[0207] All or part of the steps of the above method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a readable memory. When the program is executed, it performs the steps of the above method embodiments; and the aforementioned memory (storage medium) includes: read-only memory (ROM), random access memory (RAM), flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof.

[0208] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-executable instructions. These computer-executable instructions can be provided to a processing unit of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processing unit of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more blocks of the flowchart illustrations and / or one or more blocks of the block diagrams.

[0209] These computer-executable instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.

[0210] These computer-executable instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable apparatus, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.

[0211] Obviously, those skilled in the art can make various modifications and variations to the embodiments of this application without departing from the spirit and scope of this application. Therefore, if these modifications and variations to the embodiments of this application fall within the scope of the claims of this application and their equivalents, this application also intends to include these modifications and variations.

Claims

1. A data transmission method, characterized in that, When applied in a terminal device, the method includes: Display Bluetooth transfer controls on the data transfer page; In response to the user's selection of the Bluetooth transmission control, the system scans for Bluetooth devices within a preset range and obtains the scan results, which include device information of at least one Bluetooth device and the number of Bluetooth devices. Determine whether the number of Bluetooth devices is greater than 1. If so, determine the target Bluetooth device based on the device information of multiple Bluetooth devices. If not, determine the Bluetooth device as the target Bluetooth device. Data is transmitted to the target Bluetooth device.

2. The method according to claim 1, characterized in that, The device information includes signal strength. Based on the device information of multiple Bluetooth devices, the target Bluetooth device is determined, including: The multiple Bluetooth devices are sorted in descending order of signal strength; The judgment step includes: determining whether the i-th Bluetooth device meets the preset conditions, where i is initially 1; If yes, then the i-th Bluetooth device is determined as the target Bluetooth device; if no, then i is updated to i+1, and the judgment step is executed until the target Bluetooth device is determined, or, if the multiple Bluetooth devices do not meet the preset conditions respectively, the Bluetooth device with the strongest signal strength is determined as the target Bluetooth device.

3. The method according to claim 2, characterized in that, Determine whether the i-th Bluetooth device meets the preset conditions, including: Determine whether the i-th Bluetooth device has historical data, wherein the historical data is a record of accepting a transmission or a record of rejecting a transmission; If so, obtain at least one historical record information corresponding to the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the at least one historical record information; If not, send a transmission request to the i-th Bluetooth device, obtain the transmission response sent by the i-th Bluetooth device, and determine whether the i-th Bluetooth device meets the preset conditions based on the transmission response.

4. The method according to claim 3, characterized in that, Based on the at least one historical record information, determine whether the i-th Bluetooth device meets the preset conditions, including: Based on the at least one historical record information, the priority weight of the i-th Bluetooth device is determined; If the priority weight is greater than the threshold, determine whether the latest historical record information corresponding to the i-th Bluetooth device is the received transmission record. If yes, determine that the i-th Bluetooth device meets the preset conditions; otherwise, determine that the i-th Bluetooth device does not meet the preset conditions. If the priority weight is not greater than the threshold, it is determined that the i-th Bluetooth device does not meet the preset conditions.

5. The method according to claim 3, characterized in that, The transmission response includes an accept response and a reject response. Based on the transmission response, it is determined whether the i-th Bluetooth device meets the preset conditions, including: If the transmission response is the acceptance response, it is determined that the i-th Bluetooth device meets the preset conditions; If the transmission response is the rejection response, it is determined that the i-th Bluetooth device does not meet the preset conditions.

6. The method according to claim 5, characterized in that, After obtaining the transmission response sent by the i-th Bluetooth device: Based on the transmission response, establish the historical transmission information corresponding to the i-th Bluetooth device.

7. The method according to any one of claims 1-6, characterized in that, Display Bluetooth transfer controls on the data transfer page, including: Obtain the Bluetooth transmission mode of the terminal device, wherein the Bluetooth transmission mode is either automatic transmission mode or manual transmission mode; When the Bluetooth transmission mode is determined to be automatic transmission mode, a Bluetooth transmission control is displayed on the data transmission page.

8. A data transmission device, characterized in that, The device, used in terminal equipment, includes: The display module is used to display Bluetooth transmission controls on the data transmission page; The scanning module is used to scan for Bluetooth devices within a preset range in response to the user's selection operation of the Bluetooth transmission control, and obtain the scanning results, which include device information of at least one Bluetooth device and the number of Bluetooth devices. The judgment module is used to determine whether the number of Bluetooth devices is greater than 1. If so, it determines the target Bluetooth device based on the device information of multiple Bluetooth devices. If not, it determines the Bluetooth device as the target Bluetooth device. A transmission module is used to transmit data to the target Bluetooth device.

9. An electronic device, characterized in that, include: Memory, processor, and transceiver; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions that, when executed by a processor, are used to implement the method as described in any one of claims 1-7.

Citation Information

Patent Citations

  • Mobile terminal, and mobile terminal and Bluetooth wristband binding method and device

    CN104902435A

  • Bluetooth pairing method and device

    CN105407453A

  • Bluetooth name search method and device, electronic equipment and storage medium

    CN110460983A

  • Method and system for quickly connecting target equipment from complex environment

    CN113543099A

  • Data transmission method and device, equipment and storage medium

    CN118945633A