CN116723538A - Bluetooth device testing method, device and system, electronic device and storage medium - Google Patents

Bluetooth device testing method, device and system, electronic device and storage medium Download PDF

Info

Publication number
CN116723538A
CN116723538A CN202310725681.7A CN202310725681A CN116723538A CN 116723538 A CN116723538 A CN 116723538A CN 202310725681 A CN202310725681 A CN 202310725681A CN 116723538 A CN116723538 A CN 116723538A
Authority
CN
China
Prior art keywords
test
bluetooth
bluetooth device
message
equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310725681.7A
Other languages
Chinese (zh)
Inventor
邹雪根
司马健
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xinyuan Microelectronics Hainan Co ltd
Xinyuan Microelectronics Nanjing Co ltd
Xinyuan Technology Shanghai Co ltd
VeriSilicon Microelectronics Shanghai Co Ltd
VeriSilicon Microelectronics Chengdu Co Ltd
Original Assignee
Xinyuan Microelectronics Hainan Co ltd
Xinyuan Microelectronics Nanjing Co ltd
Xinyuan Technology Shanghai Co ltd
VeriSilicon Microelectronics Shanghai Co Ltd
VeriSilicon Microelectronics Chengdu Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xinyuan Microelectronics Hainan Co ltd, Xinyuan Microelectronics Nanjing Co ltd, Xinyuan Technology Shanghai Co ltd, VeriSilicon Microelectronics Shanghai Co Ltd, VeriSilicon Microelectronics Chengdu Co Ltd filed Critical Xinyuan Microelectronics Hainan Co ltd
Priority to CN202310725681.7A priority Critical patent/CN116723538A/en
Publication of CN116723538A publication Critical patent/CN116723538A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/08Testing, supervising or monitoring using real traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B17/00Monitoring; Testing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Electromagnetism (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application relates to the field of communication, and particularly discloses a Bluetooth device testing method, a Bluetooth device testing device, a Bluetooth device testing system, an electronic device and a storage medium. The Bluetooth equipment testing method comprises the following steps: obtaining a test file; obtaining a standard message; controlling the Bluetooth equipment to be tested and the Bluetooth equipment to be tested to carry out data communication according to the test file; acquiring a test message between the Bluetooth equipment to be tested and the test Bluetooth equipment; and acquiring the test result according to the matching degree of the test message and the standard message. Compared with the prior art, the Bluetooth equipment testing method, device and system, the electronic equipment and the storage medium provided by the embodiment of the application have the advantage of being capable of reducing the Bluetooth equipment testing cost.

Description

Bluetooth device testing method, device and system, electronic device and storage medium
Technical Field
The present application relates to the field of communications, and in particular, to a method, an apparatus, a system, an electronic device, and a storage medium for testing bluetooth devices.
Background
Because the bluetooth equipment needs to meet the related protocol of bluetooth communication before being marketed, the testing process of whether the bluetooth equipment meets the related protocol of bluetooth communication is an indispensable step in the research and development and production processes of bluetooth products. The standard test equipment is usually used for the related test of the communication protocol of the Bluetooth equipment, and the standard test equipment internally comprises a related test set for testing the Bluetooth equipment, wherein the test set complies with the test standard specified in the Bluetooth communication standard and can be used for testing the Bluetooth product.
The specific test procedure is generally: firstly, configuring standard test equipment through matched software on a terminal, and selecting a corresponding test set according to functional characteristics supported by a product; after configuration is completed, a test is started, the standard test equipment sequentially executes a selected test set, and the Bluetooth equipment to be tested is tested according to test contents.
However, standard bluetooth test equipment is expensive to sell, resulting in higher cost of the test process of the bluetooth equipment, which affects the overall development and production efficiency of bluetooth products.
Disclosure of Invention
The application aims to provide a Bluetooth device testing method, a Bluetooth device testing device, a Bluetooth device testing system, an electronic device and a storage medium, which can reduce the testing cost of the Bluetooth device.
In a first aspect, the present application provides a bluetooth device testing method, including: obtaining a test file; obtaining a standard message; controlling the Bluetooth equipment to be tested and the Bluetooth equipment to be tested to carry out data communication according to the test file; acquiring a test message between the Bluetooth equipment to be tested and the test Bluetooth equipment; and acquiring the test result according to the matching degree of the test message and the standard message.
According to the Bluetooth equipment testing method, data communication is conducted between the Bluetooth equipment to be tested and the Bluetooth equipment to be tested through the testing file, then the testing result of the Bluetooth equipment to be tested is obtained according to the matching degree between the testing message generated in the communication process and the standard message obtained in advance, the testing process of the Bluetooth equipment to be tested is completed through the Bluetooth equipment to be tested, dependence on the standard testing equipment in the Bluetooth equipment testing process is reduced, the use of the standard testing equipment is reduced, and the cost of the Bluetooth equipment to be tested is far lower than that of the standard testing equipment, so that the testing cost of the Bluetooth equipment is reduced.
In an alternative embodiment, the obtaining the standard packet includes: obtaining a sample log file, wherein the sample log file is generated in the test process of standard test equipment and sample Bluetooth equipment; and acquiring the standard message from the sample log file. According to the log file generated in the test process of the standard test equipment and the sample Bluetooth equipment, the standard message is obtained, so that the reliability of the standard message is higher.
In an alternative embodiment, the acquiring the test file includes: and acquiring the test file according to the sample log file. According to the method, the test file is obtained according to the log file generated in the test process of the standard test equipment and the sample Bluetooth equipment, so that the influence of different test files on the difference between the test message and the standard message can be reduced.
In an optional embodiment, the obtaining the test file according to the sample log file includes: acquiring a plurality of communication commands related to a test process in the sample log file; acquiring a first communication command used for controlling the standard test equipment in the communication commands, modifying equipment information in the first communication command into equipment information of the test Bluetooth equipment, and forming a first control command; acquiring a second communication command used for controlling the sample Bluetooth device in the plurality of communication commands, and modifying device information in the second communication command into device information of the Bluetooth device to be tested to form a second control command; and merging the first control command and the second control command to form the test file.
In an optional embodiment, the controlling, according to the test file, the bluetooth device to be tested and the bluetooth device to be tested to perform data communication includes: and respectively sending the first control command and the second control command to the Bluetooth testing equipment and the Bluetooth testing equipment, and controlling the Bluetooth testing equipment and the Bluetooth testing equipment to carry out data communication by the first control command and the second control command.
In an optional embodiment, the obtaining a test packet between the bluetooth device to be tested and the test bluetooth device includes: acquiring a first test message generated by the test Bluetooth equipment according to the first control command; and acquiring a second test message generated by the Bluetooth device to be tested according to the second control command.
In an optional embodiment, the obtaining the standard packet from the sample log file includes: acquiring a first standard message corresponding to the first communication command in the sample log file; acquiring a second standard message corresponding to the second communication command in the sample log file; the step of obtaining the test result according to the matching degree of the test message and the standard message comprises the following steps: and acquiring the test result according to the matching degree of the first test message and the first standard message and the matching degree of the second test message and the second standard message.
In an alternative embodiment, the acquiring the test file includes: and acquiring a user-defined test file input by a user. The user-defined test file input by the user can be used for improving the applicability of the test method.
In an alternative embodiment, the obtaining the standard packet includes: and acquiring the user-defined message input by the user. The applicability of the test method can be improved by using the user-defined message input by the user.
In a second aspect, the present application provides a bluetooth device testing apparatus, including: the file acquisition module is used for acquiring a test file and a standard message; the control module is used for controlling the Bluetooth equipment to be tested and the Bluetooth equipment to be tested to carry out data communication according to the test file; the message acquisition module is used for acquiring a test message between the Bluetooth equipment to be tested and the test Bluetooth equipment; and the processing module is used for acquiring the test result according to the matching degree of the test message and the standard message.
In a third aspect, the present application provides a bluetooth device testing system, including: the bluetooth device testing apparatus and the bluetooth device for testing connected with the bluetooth device testing apparatus according to the foregoing embodiments; the bluetooth device testing apparatus is configured to perform the bluetooth device testing method according to any one of the foregoing embodiments; the Bluetooth testing device is used for carrying out data communication with the Bluetooth device to be tested under the control of the Bluetooth device testing device.
In a fourth aspect, the present application provides an electronic device comprising: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the bluetooth device testing method according to any one of the preceding embodiments. In a fifth aspect, the present application provides a computer readable storage medium storing a computer program for execution by a processor to implement the bluetooth device testing method according to any one of the preceding embodiments.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flow chart of a bluetooth device testing method according to an embodiment of the present application;
FIG. 2 is an illustration of a sample log file in some embodiments of the application;
FIG. 3 is an illustration of standard messages and test files in some embodiments of the application;
FIG. 4 is an illustration of a test message as it passes in some embodiments of the application;
FIG. 5 is an illustration of a test message when a test fails in some embodiments of the present application;
fig. 6 is a schematic structural diagram of a bluetooth device testing apparatus according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a bluetooth device testing system according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present application more apparent, the technical solutions of the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application, and it is apparent that the described embodiments are some embodiments of the present application, but not all embodiments of the present application. The components of the embodiments of the present application generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the application, as presented in the figures, is not intended to limit the scope of the application, as claimed, but is merely representative of selected embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
It should be noted that: like reference numerals and letters denote like items in the following figures, and thus once an item is defined in one figure, no further definition or explanation thereof is necessary in the following figures.
In the description of the present application, it should be noted that, if the terms "upper", "lower", "inner", "outer", and the like indicate an azimuth or a positional relationship based on the azimuth or the positional relationship shown in the drawings, or the azimuth or the positional relationship in which the inventive product is conventionally put in use, it is merely for convenience of describing the present application and simplifying the description, and it is not indicated or implied that the apparatus or element referred to must have a specific azimuth, be configured and operated in a specific azimuth, and thus it should not be construed as limiting the present application.
Furthermore, the terms "first," "second," and the like, if any, are used merely for distinguishing between descriptions and not for indicating or implying a relative importance.
It should be noted that the features of the embodiments of the present application may be combined with each other without conflict.
The embodiment of the application provides a Bluetooth device testing method, which is used for testing a Bluetooth device to be tested, and as shown in fig. 1, comprises the following steps:
s101: and obtaining a test file.
S102: and obtaining a standard message.
S103: and controlling the Bluetooth equipment to be tested and the Bluetooth testing equipment to carry out data communication according to the test file, and obtaining a test message between the Bluetooth testing equipment to be tested and the Bluetooth testing equipment.
S104: and obtaining a test result according to the matching degree of the test message and the standard message.
Compared with the prior art, in the Bluetooth equipment testing method provided by the embodiment of the application, the data communication is performed between the Bluetooth equipment to be tested and the Bluetooth equipment to be tested through the test file, then the test result of the Bluetooth equipment to be tested is obtained according to the matching degree between the test message generated in the communication process and the standard message acquired in advance, the test process of the Bluetooth equipment to be tested is completed by using the Bluetooth equipment to be tested, the dependence on the standard test equipment of Bluetooth in the Bluetooth equipment testing process is reduced, the use of the standard test equipment is reduced, and the cost of the Bluetooth equipment to be tested is far lower than that of the standard test equipment, so that the test cost of the Bluetooth equipment is reduced.
In this step S101, the test file is a file for testing the bluetooth device to be tested, in the practical application process, the test file may be run through a bluetooth device testing device such as an upper computer, and the bluetooth device testing device such as the upper computer may control data communication between the bluetooth device to be tested and the bluetooth device to be tested according to the test file, or the test file may be run by using the bluetooth device with a test function, and the bluetooth device to be tested may directly perform data communication with the bluetooth device to be tested according to the test file, and specifically may perform setting according to practical needs.
In some embodiments of the present application, after the test file is run, the bluetooth device to be tested and the test bluetooth device can be controlled to perform data communication according to the test file, and in the process of performing data communication between the bluetooth device to be tested and the test bluetooth device, a data message related to the data communication process can be generated. It can be understood that in different embodiments of the present application, the message type of the test message may be different, for example, the test message may be any combination of various data such as a communication time point, a communication result, a communication duration, a communication quality, and the like, and may specifically be set according to an actual requirement and a data type of the standard message.
Further, in some embodiments of the present application, the test file may be a file stored in advance in the bluetooth device testing apparatus, or may be a file obtained by the bluetooth device testing apparatus from other electronic devices in real time, or may be a file generated by the bluetooth device testing apparatus in real time, which may be specifically set according to actual needs.
In some embodiments of the application, the test file may be obtained from a sample log file. The sample log file is generated in the test process of the standard test equipment and the sample Bluetooth equipment. The standard test equipment is the test equipment used for carrying out standardized test on the Bluetooth equipment in the related technology, the sample Bluetooth equipment is the Bluetooth equipment which is used as a test sample and has passed the test, the standard test equipment is used for testing the sample Bluetooth equipment, and then a log file generated in the test process is obtained as a sample log file. In the practical application process, the sample log file can be obtained in advance and stored in the Bluetooth test equipment, the pre-stored sample log file can be directly obtained when the Bluetooth test equipment is tested, or the sample log file can be stored in a server in advance, and then the sample log file can be received from the server when the Bluetooth test equipment is tested.
Further, in some embodiments of the present application, the number and types of sample log files may be plural, and different sample log files may be generated for storage according to the types, models, etc. of the sample bluetooth devices. When the Bluetooth equipment to be tested is tested, the sample Bluetooth equipment which is the same as the Bluetooth equipment to be tested can be obtained according to the type, the model and other data of the Bluetooth equipment to be tested, and then the corresponding sample log file is obtained.
Further, in some embodiments of the present application, a number of communication commands associated with the test procedure in the sample log file may be obtained; acquiring a first communication command used for controlling standard test equipment in a plurality of communication commands, and modifying equipment information in the first communication command into equipment information of the test Bluetooth equipment to form a first control command; acquiring a second communication command used for controlling the sample Bluetooth device in the plurality of communication commands, and modifying device information in the second communication command into device information of the Bluetooth device to be tested to form a second control command; and combining the first control command and the second control command to form a test file.
It should be understood that the foregoing directly obtaining the plurality of communication commands related to the test procedure in the sample log file is only a specific illustration of building the test file in some embodiments of the present application, and is not limited to the specific illustration, and in some other embodiments of the present application, the test file may be built by removing unwanted commands (e.g., commands generated during internal control and communication of the standard test device itself, commands unrelated to the test requirements) in the sample log file, that is, after removing unwanted commands in the sample, the remaining commands are the plurality of communication commands related to the test procedure, and then obtaining a first communication command for controlling the standard test device in the plurality of communication commands, modifying device information in the first communication command to be device information of the test bluetooth device, and forming the first control command; acquiring a second communication command used for controlling the sample Bluetooth device in the plurality of communication commands, and modifying device information in the second communication command into device information of the Bluetooth device to be tested to form a second control command; and combining the first control command and the second control command to form a test file.
It should be understood that the foregoing obtaining the test file according to the log file generated during the testing process of the standard test device and the sample bluetooth device is merely illustrative in some embodiments of the present application, and not limiting, and in some other embodiments of the present application, the test file may be obtained by a user or may be generated according to other files, for example, bluetooth communication protocol, etc., and particularly may be flexibly set according to actual needs. In the related art, after the standard test equipment of the bluetooth equipment is produced, the available test items are also determined, if a user needs to test other items, the standard test equipment needs to be debugged by a provider of the standard test equipment, in the embodiment of the application, the user-input custom test file is used, and the test of other items needed by the user can be completed without passing through the provider of the standard test equipment, so that the applicability of the test method can be improved.
In step S102, the standard message is a data message that should be generated when the test of the bluetooth device to be tested passes. In some embodiments of the present application, the standard message may also be obtained through a sample log file generated in a testing process of the standard testing device and the sample bluetooth device, and specifically may obtain a first standard message corresponding to the first communication command in the sample log file; and obtaining a second standard message corresponding to the second communication command in the sample log file. According to the log file generated in the test process of the standard test equipment and the sample Bluetooth equipment, the standard message is obtained, so that the reliability of the standard message is higher. In addition, according to the log files generated in the test process of the standard test equipment and the sample Bluetooth equipment, the test files and the standard messages are obtained simultaneously, so that the influence of different test files on the difference between the test messages and the standard messages can be reduced.
It can be understood that the above-mentioned standard message obtained according to the log file generated during the testing process of the standard testing device and the sample bluetooth device is only an illustration in some embodiments of the present application, and is not limited to the above-mentioned standard message, and in some other embodiments of the present application, the standard message may be a custom standard message input by the user, or a standard message generated according to other files, for example, a bluetooth communication protocol, etc., and specifically may be flexibly set according to actual needs. In the related art, after the standard test equipment of the bluetooth equipment is produced, the available test items are also determined, if a user needs to test other items, the standard test equipment needs to be debugged by a provider of the standard test equipment, in the embodiment of the application, the user-defined standard message input by the user is used, and the test of other items needed by the user can be completed without passing through the provider of the standard test equipment, so that the applicability of the test method can be improved.
Further, in some embodiments of the present application, the standard message may be recorded in the same file together with the test file, that is, a single file is used to record both the control command in the test file and the standard message corresponding to the control command.
In step S103, the controlling the bluetooth device to be tested and the bluetooth device to be tested to perform data communication according to the test file may specifically be sending a first control command and a second control command to the bluetooth device to be tested and the bluetooth device to be tested, respectively, where the first control command and the second control command control the bluetooth device to be tested and the bluetooth device to be tested to perform data communication. The method comprises the steps that a first control command is sent to a Bluetooth testing device, a second control command is sent to the Bluetooth testing device, the Bluetooth testing device performs data communication with the Bluetooth testing device under the first control command, and meanwhile the Bluetooth testing device performs data communication with the Bluetooth testing device under the second control command, so that a data message generated in the whole communication process is obtained to serve as a test message.
In some embodiments of the present application, the test message may include a first test message generated by the bluetooth device under test and a second test message generated by the bluetooth device under test. Specifically, a data message generated when the test bluetooth device performs data communication with the bluetooth device to be tested under the first control command can be obtained as a first test message, and a data message generated when the test bluetooth device performs data communication with the test bluetooth device under the control of the second control command can be obtained as a second test message.
In step S104, the matching degree of the test message and the standard message is the same degree of data between the test message and the standard message, and specifically, a ratio between the data amount of the data identical to the standard message in the test message and the data amount of all the data of the standard message may be used as the matching degree of the test message and the standard message. For example, the standard message may be Q1, Q2, Q3, Q4, Q5, Q6, Q7, and Q8, and the test message is Q1, Q2, Q3, Q4, M1, Q6, and Q7, and if the data in the test message identical to the standard message is Q1, Q2, Q3, Q4, Q6, and Q7, the data amount is 6, the total data amount of the standard message is 8, and the matching degree between the test message and the standard message is 75%.
Specifically, in the process of obtaining the test result according to the matching degree of the test message and the standard message, a matching degree threshold value can be preset, and the test result is obtained according to the magnitude relation between the matching degree of the test message and the standard message and the preset matching degree threshold value, namely if the matching degree of the test message and the standard message is greater than or equal to the preset matching degree threshold value, the test of the Bluetooth device to be tested passes, otherwise if the matching degree of the test message and the standard message is less than the preset matching degree threshold value, the test of the Bluetooth device to be tested fails. In different embodiments of the present application, the matching degree threshold may be flexibly preset according to actual needs, for example, when the accuracy requirement for the detection result is high, the matching degree threshold may be set to be large, for example, the matching degree threshold may be set to be 98% matching, 99% matching, even 100% matching, etc., and may be specifically preset according to actual needs.
Further, in some embodiments of the present application, as before, the test packet may include a first test packet generated by the test bluetooth device and a second test packet generated by the bluetooth device to be tested, and the standard packet may include a first standard packet and a second standard packet, and the test result may be obtained according to the matching degree of the first test packet and the first standard packet and the matching degree of the second test packet and the second standard packet.
Specifically, for example, a matching degree threshold may be preset, if the matching degree of the first test packet and the first standard packet and the matching degree of the second test packet and the second standard packet are both greater than or equal to the matching degree threshold, the test of the bluetooth device to be tested is passed, otherwise, if the matching degree of the first test packet and the first standard packet or the matching degree of the second test packet and the second standard packet is less than the matching degree threshold, the test of the bluetooth device to be tested is not passed. It should be understood that the foregoing is merely illustrative of obtaining the test result according to the matching degree of the first test packet and the first standard packet and the matching degree of the second test packet and the second standard packet in the foregoing embodiment of the present application, and is not limited to the foregoing embodiment, and in some other embodiments of the present application, the first matching degree threshold value and the second matching degree threshold value may be preset, for example, if the matching degree of the first test packet and the first standard packet is greater than or equal to the first matching degree threshold value and the matching degree of the second test packet and the second standard packet is greater than or equal to the second matching degree threshold value, the test of the bluetooth device to be tested is passed, otherwise, if the matching degree of the first test packet and the first standard packet is less than the first matching degree threshold value or the matching degree of the second test packet and the second standard packet is less than the second matching degree threshold value, the test of the bluetooth device to be tested is not passed.
An illustration of a sample log file in some embodiments of the application is shown in fig. 2. Wherein the command indicated by "COM3 →" is a test command generated by a standard test apparatus, the command indicated by "COM3≡" is a command received by the standard test equipment, i.e., standard messages generated by the sample bluetooth device.
Fig. 3 illustrates an example of standard messages and test files in some embodiments of the application. The command indicated by "TESTER|CMD|1|1" is a first control command for testing the Bluetooth device, the command indicated by "TESTER|EVT|1|1" is a first standard message generated by testing the Bluetooth device, the command indicated by "IUT|CMD|1|1" is a second control command for testing the Bluetooth device, and the command indicated by "IUT|EVT|1|1" is a second standard message generated by testing the Bluetooth device.
Fig. 4 illustrates an example of a test message when a test passes in some embodiments of the application. The read indicates the read command line number, the command indicated by the "TESTER|CMD|" is a first control command for testing the operation of the Bluetooth device, the "TESTER|EVT|" is a first test message generated by testing the Bluetooth device, the command indicated by the "IUT|CMD|" is a second control command for testing the operation of the Bluetooth device, and the "IUT|EVT|" is a second test message generated by testing the Bluetooth device.
FIG. 5 is a diagram illustrating an example of a test message when a test fails in some embodiments of the application. The command indicated by the 'IUT|EVT|' is a second control command for running the Bluetooth device to be tested, and the 'IUT|EVT|' is a second test message generated by the Bluetooth device to be tested.
The embodiment of the application relates to a Bluetooth device testing device 100, as shown in fig. 6, comprising: the file acquisition module 201, the file acquisition module 201 is used for acquiring a test file and a standard message; the control module 202, the control module 202 is used for controlling the bluetooth device 200 to be tested and the bluetooth device 300 to be tested to perform data communication according to the test file; the message acquisition module 203 is configured to acquire a test message between the bluetooth device 200 to be tested and the bluetooth device 300 to be tested; and the processing module 204 is used for acquiring a test result according to the matching degree of the test message and the standard message.
Compared with the prior art, in the bluetooth device testing apparatus provided by the embodiment of the application, after the file acquisition module 201 acquires the test file and the standard message, the control module 202 controls the test bluetooth device to communicate with the bluetooth device to be tested through the test file, then the message acquisition module 203 acquires the test message between the bluetooth device to be tested 200 and the bluetooth device to be tested 300, the processing module 204 obtains the test result of the bluetooth device to be tested according to the matching degree between the test message generated in the communication process and the pre-acquired standard message, the test process of the bluetooth device to be tested is completed by using the bluetooth device to be tested, the dependence on the standard test device in the test process of the bluetooth device is reduced, the use of the standard test device is reduced, and the cost of the bluetooth device to be tested is far lower than that of the standard test device, thereby the test cost of the bluetooth device is reduced.
The embodiment of the application relates to a Bluetooth device testing system, as shown in fig. 7, comprising: the bluetooth device testing apparatus 100 as provided in the foregoing embodiments, and the test bluetooth device 300 connected to the bluetooth device testing apparatus 100. Wherein the bluetooth device testing apparatus 100 is configured to perform the bluetooth device testing method as provided in the foregoing embodiments; the test bluetooth device 300 is used for performing data communication with a bluetooth device to be tested under the control of the bluetooth device testing apparatus 100, thereby completing the test process of the bluetooth device to be tested.
An embodiment of the present application relates to an electronic device, as shown in fig. 8, including: at least one processor 401; and a memory 402 communicatively coupled to the at least one processor 401; the memory 402 stores instructions executable by the at least one processor 401, and the instructions are executed by the at least one processor 401, so that the at least one processor 401 can execute the bluetooth device testing method in the above embodiments.
Where the memory and the processor are connected by a bus, the bus may comprise any number of interconnected buses and bridges, the buses connecting the various circuits of the one or more processors and the memory together. The bus may also connect various other circuits such as peripherals, voltage regulators, and power management circuits, which are well known in the art, and therefore, will not be described any further herein. The bus interface provides an interface between the bus and the transceiver. The transceiver may be one element or may be a plurality of elements, such as a plurality of receivers and transmitters, providing a means for communicating with various other apparatus over a transmission medium. The data processed by the processor is transmitted over the wireless medium via the antenna, which further receives the data and transmits the data to the processor.
The processor is responsible for managing the bus and general processing and may also provide various functions including timing, peripheral interfaces, voltage regulation, power management, and other control functions. And memory may be used to store data used by the processor in performing operations.
Embodiments of the present application relate to a computer-readable storage medium storing a computer program. The computer program implements the above-described method embodiments when executed by a processor.
That is, it will be understood by those skilled in the art that all or part of the steps in implementing the methods of the embodiments described above may be implemented by a program stored in a storage medium, where the program includes several instructions for causing a device (which may be a single-chip microcomputer, a chip or the like) or a processor (processor) to perform all or part of the steps in the methods of the embodiments of the application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Although the protection scope of the present application is not limited to the above embodiments, any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present application should be covered within the protection scope of the present application, for example, the present application is exemplified only for the testing procedure of the bluetooth device, and in practical use, the present application may be used for testing other communication devices in the wireless communication technical field, such as wifi devices, zigbee devices, etc.

Claims (13)

1. A method for testing a bluetooth device, comprising:
obtaining a test file;
obtaining a standard message;
controlling the Bluetooth equipment to be tested and the Bluetooth equipment to be tested to carry out data communication according to the test file;
acquiring a test message between the Bluetooth equipment to be tested and the test Bluetooth equipment;
and acquiring the test result according to the matching degree of the test message and the standard message.
2. The method for testing a bluetooth device according to claim 1, wherein the obtaining the standard message includes:
obtaining a sample log file, wherein the sample log file is generated in the test process of standard test equipment and sample Bluetooth equipment;
and acquiring the standard message from the sample log file.
3. The bluetooth device testing method according to claim 2, wherein the acquiring the test file includes:
and acquiring the test file according to the sample log file.
4. The bluetooth device testing method according to claim 3, wherein the acquiring the test file according to the sample log file includes:
acquiring a plurality of communication commands related to a test process in the sample log file;
acquiring a first communication command used for controlling the standard test equipment in the communication commands, modifying equipment information in the first communication command into equipment information of the test Bluetooth equipment, and forming a first control command;
acquiring a second communication command used for controlling the sample Bluetooth device in the plurality of communication commands, and modifying device information in the second communication command into device information of the Bluetooth device to be tested to form a second control command;
and merging the first control command and the second control command to form the test file.
5. The method for testing a bluetooth device according to claim 4, wherein the controlling the bluetooth device to be tested and the bluetooth device to be tested to perform data communication according to the test file comprises:
and respectively sending the first control command and the second control command to the Bluetooth testing equipment and the Bluetooth testing equipment, and controlling the Bluetooth testing equipment and the Bluetooth testing equipment to carry out data communication by the first control command and the second control command.
6. The method for testing a bluetooth device according to claim 5, wherein the obtaining a test packet between the bluetooth device to be tested and the bluetooth device to be tested comprises:
acquiring a first test message generated by the test Bluetooth equipment according to the first control command;
and acquiring a second test message generated by the Bluetooth device to be tested according to the second control command.
7. The method for testing a bluetooth device according to claim 6, wherein the obtaining the standard message from the sample log file includes:
acquiring a first standard message corresponding to the first communication command in the sample log file;
acquiring a second standard message corresponding to the second communication command in the sample log file;
the step of obtaining the test result according to the matching degree of the test message and the standard message comprises the following steps:
and acquiring the test result according to the matching degree of the first test message and the first standard message and the matching degree of the second test message and the second standard message.
8. The bluetooth device testing method according to claim 1, wherein the acquiring the test file includes:
and acquiring a user-defined test file input by a user.
9. The method for testing a bluetooth device according to claim 1, wherein the obtaining the standard message includes:
and acquiring the user-defined message input by the user.
10. A bluetooth device testing apparatus, comprising:
the file acquisition module is used for acquiring a test file and a standard message;
the control module is used for controlling the Bluetooth equipment to be tested and the Bluetooth equipment to be tested to carry out data communication according to the test file;
the message acquisition module is used for acquiring a test message between the Bluetooth equipment to be tested and the test Bluetooth equipment;
and the processing module is used for acquiring the test result according to the matching degree of the test message and the standard message.
11. A bluetooth device testing system, comprising:
the bluetooth device testing apparatus according to claim 11 and a test bluetooth device connected to the bluetooth device testing apparatus;
the bluetooth device testing apparatus is configured to perform the bluetooth device testing method according to any one of claims 1 to 9;
the Bluetooth testing device is used for carrying out data communication with the Bluetooth device to be tested under the control of the Bluetooth device testing device.
12. An electronic device, comprising:
at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the bluetooth device testing method according to any one of claims 1 to 9.
13. A computer readable storage medium storing a computer program, wherein the computer program is executed by a processor to implement the bluetooth device testing method according to any one of claims 1 to 9.
CN202310725681.7A 2023-06-16 2023-06-16 Bluetooth device testing method, device and system, electronic device and storage medium Pending CN116723538A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310725681.7A CN116723538A (en) 2023-06-16 2023-06-16 Bluetooth device testing method, device and system, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310725681.7A CN116723538A (en) 2023-06-16 2023-06-16 Bluetooth device testing method, device and system, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN116723538A true CN116723538A (en) 2023-09-08

Family

ID=87865819

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310725681.7A Pending CN116723538A (en) 2023-06-16 2023-06-16 Bluetooth device testing method, device and system, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN116723538A (en)

Similar Documents

Publication Publication Date Title
CN104641673B (en) For automatically configuring the method and test system of tester
CN113672441B (en) Method and device for testing intelligent equipment
CN112649717B (en) Test method, device, terminal equipment and storage medium
CN113608518B (en) Data generation method, device, terminal equipment and medium
CN112612262A (en) Production line testing method and device for vehicle-mounted equipment, computer equipment and storage medium
CN110347539B (en) Test method, device, system, computing device and medium applied to server
CN106507501A (en) A kind of Bluetooth connecting method and device
CN115542875A (en) Vehicle detection method based on SOA service and related equipment
CN112996020A (en) Bluetooth-based automatic testing method and device and Bluetooth testing terminal
CN113133041B (en) Method and device for testing vehicle-to-vehicle communication function in dynamic interval train control vehicle
CN111786852B (en) Test method and related equipment
CN116723538A (en) Bluetooth device testing method, device and system, electronic device and storage medium
CN111787555A (en) Method and equipment for testing intelligent terminal
CN111277303A (en) Production testing method and system based on universal asynchronous receiving and transmitting transmitter to Bluetooth
CN107645430B (en) Data processing method, system and related equipment
WO2019227454A1 (en) Ecu identifier and identification method, system, device and medium thereof
CN113660139B (en) V2X protocol consistency detection method based on multiple message layer communication
CN112783708B (en) DTU hardware testing method, terminal and computer readable storage medium
CN115442451A (en) Image signal transmission method and display device test equipment
CN111541589B (en) Method, device and equipment for testing expansion module interface of intelligent terminal
CN113645052B (en) Firmware debugging method and related equipment
CN112084076A (en) Test method, electronic device, and storage medium
CN103678054B (en) Test method and device for BACnet equipment
CN109491648B (en) Method, system and equipment for realizing independent partition of library function in embedded software
CN112422693A (en) User online short video draft queue exporting method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination