CN107631750B - Method, device, terminal and storage medium for testing terminal to be tested - Google Patents

Method, device, terminal and storage medium for testing terminal to be tested Download PDF

Info

Publication number
CN107631750B
CN107631750B CN201710661655.7A CN201710661655A CN107631750B CN 107631750 B CN107631750 B CN 107631750B CN 201710661655 A CN201710661655 A CN 201710661655A CN 107631750 B CN107631750 B CN 107631750B
Authority
CN
China
Prior art keywords
test
terminal
tested
sample
control instruction
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.)
Active
Application number
CN201710661655.7A
Other languages
Chinese (zh)
Other versions
CN107631750A (en
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.)
Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Original Assignee
Yulong Computer Telecommunication Scientific Shenzhen 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 Yulong Computer Telecommunication Scientific Shenzhen Co Ltd filed Critical Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Priority to CN201710661655.7A priority Critical patent/CN107631750B/en
Publication of CN107631750A publication Critical patent/CN107631750A/en
Application granted granted Critical
Publication of CN107631750B publication Critical patent/CN107631750B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The invention discloses a method, a device, a terminal and a storage medium for testing a terminal to be tested, wherein the method comprises the following steps: establishing connection between the terminal to be tested and the test equipment; sending a control instruction to the test equipment; acquiring a test sample in the process of executing the control instruction by the test equipment and/or after the test equipment finishes executing the operation corresponding to the control instruction; and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample. This scheme is through terminal to be tested to test equipment send control command to control test equipment carries out relevant test operation, obtains the test sample according to the test demand, compares the test sample rather than the predetermined standard that corresponds and confirms the test result, compares with prior art, not only can abandon at least one PC, need not personnel's operation moreover, greatly reduced test cost, improved the automation and the efficiency of software testing at terminal.

Description

Method, device, terminal and storage medium for testing terminal to be tested
Technical Field
The invention relates to the technical field of testing, in particular to a method, a device, a terminal and a storage medium for testing a terminal to be tested.
Background
At present, with the development of communication technology, various mobile terminals have become an indispensable part of people's daily life, and electronic devices such as mobile phones, tablet computers, and the like have become more and more popular in people's daily life. Before repairing a fault terminal of a user, the terminal is tested and maintained and processed according to a test result; taking a mobile phone as an example, the mobile phone test relates to hardware test, software test and the like. Hardware tests generally have strict physical and electrical indexes, for example, an optical camera of a mobile phone can image light fed back from the outside, and the test on the camera mainly lies in image tests. In the prior art, the following scheme is generally adopted for testing a mobile phone camera:
the existing scheme generally needs at least one PC, test equipment and a mobile phone, a test analysis tool is integrated in the PC, the PC is respectively connected with the test equipment and the mobile phone, the PC sends a test instruction to the test equipment, the test equipment prepares to test hardware conditions of a mobile phone camera, for example, photographing conditions such as a pure white board, a pure black board and a certain photographing distance are provided for the camera, the PC is informed after the test conditions are prepared, the PC controls the camera of the mobile phone to photograph to obtain image information, and the PC determines a test result of the camera according to the image information. This solution has the following drawbacks:
1. camera test equipment is automatic inadequately, when providing the hardware condition of shooing for the cell-phone camera (if promote the blank and cover the camera top), need the relevant function key on the manual operation test equipment, the blank just can slide to the camera top under the promotion of atmospheric pressure, and is with high costs, inefficiency.
2. The application of the mobile phone cannot realize automatic photographing, automatic focusing, automatic imaging and image analysis.
Therefore, how to improve the automation and intelligence of the terminal test and improve the test efficiency becomes a technical problem to be solved urgently.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, an apparatus, a terminal and a storage medium for setting a test condition for testing a terminal to be tested, so as to solve the problem in the prior art that an automation performance of a terminal test process is poor.
The first aspect of the present invention provides a method for testing a terminal to be tested, wherein the terminal to be tested and a testing device have the same baud rate, and the method includes: establishing connection between the terminal to be tested and the test equipment; sending a control instruction to the test equipment; acquiring a test sample in the process of executing the control instruction by the test equipment and/or after the test equipment finishes executing the operation corresponding to the control instruction; and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
By implementing the method described in the first aspect, after the authentication between the terminal to be tested and the test equipment passes, a communication connection is established between the terminal to be tested and the test equipment, and a control instruction is sent to the test equipment through the terminal to control the test equipment to execute a related test operation (here, mainly referred to as a preparation condition for obtaining a test sample), specifically, obtaining the test sample can be divided into two cases, one of which, the terminal to be tested and the test equipment make a predetermined agreement, once the test equipment starts to execute an operation corresponding to the control instruction, the terminal to be tested can start obtaining the test sample, that is, in the process of preparing the condition for the test equipment, the terminal to be tested can always obtain a plurality of related test samples; secondly, after the test equipment executes the operation corresponding to the control instruction, the task completion notice is returned to the terminal to be tested, then the terminal to be tested can obtain the test sample according to the test requirement, and finally the final test result is determined according to the obtained test sample and the preset standard corresponding to the test sample so as to complete the test of the terminal to be tested.
With reference to the first aspect of the present invention, in a first embodiment of the first aspect of the present invention, the test sample is an image sample, and the control instruction includes: shooting a background and/or shooting a distance, wherein the obtaining of the test sample comprises: and controlling a camera of the terminal to be tested to take a picture to obtain the image sample.
By executing the above steps, when the test sample is an image sample, the camera of the terminal to be tested is tested, the camera test mainly consists in testing the imaging quality of the camera, and the control instruction may include but is not limited to: the background and/or shooting distance are/is shot, when the test equipment receives the control instruction, shooting conditions (such as a preset shooting background, a preset shooting distance and the like) required by the camera test can be prepared, the terminal can be informed after the preparation, then the terminal to be tested controls the camera to shoot, and a sample image for testing can be obtained.
With reference to the first aspect of the present invention, in a second implementation manner of the first aspect of the present invention, the test samples are audio samples, and the control instruction includes: starting the recording, wherein the obtaining of the test sample comprises: controlling the terminal to be tested to play a test audio file; and receiving an audio sample recorded by the testing equipment.
By performing the above steps, the test sample may be an audio sample, and at this time, an audio module (such as a speaker) of the terminal to be tested is tested, and mainly the audio distortion of the terminal to be tested is tested, and the control instruction includes but is not limited to: and starting the recording, wherein the test equipment receives the control instruction and then prepares the recording condition required by the test, starts the recording, informs the terminal to be tested after the recording is prepared, then the terminal to be tested starts to play the test audio file, and sends the recorded audio sample to the terminal so that the terminal to be tested can determine the final test result according to the audio sample and the corresponding preset standard.
With reference to the first aspect of the present invention, in a third implementation manner of the first aspect of the present invention, the test sample is a gravity-sensitive sample, the controlling instruction includes moving the terminal to be tested, and the obtaining the test sample includes: collecting gravity sensing data of the terminal to be tested; and using the gravity sensing data as the gravity sensing sample.
By executing the steps, the test sample can be a gravity sensing sample, that is, the gravity sensor of the terminal to be tested is tested, for example, the accuracy of the gravity sensor can be tested, the control instruction includes but is not limited to moving the terminal to be tested, the position of the terminal to be tested is continuously moved by the test equipment (the control instruction can be added in advance), the gravity sensor of the terminal to be tested can acquire relevant gravity sensing data (for example, position coordinate data) in the process, so that the gravity sensing samples of the terminal to be tested at different positions can be obtained, then the accuracy of the gravity sensor of the terminal to be tested is determined according to the gravity sensing samples and the preset standard thereof, the whole process is automatically completed, manual operation of the test equipment is not needed, and the automation and the test efficiency of the gravity sensing test are improved.
Furthermore, a second aspect of the present invention provides an apparatus for testing a terminal under test, which may be used for a terminal under test, such as a mobile phone, and the like, wherein the terminal under test has the same baud rate as a test device, and the apparatus for testing a terminal under test includes a module or a unit for executing any one of the methods for testing a terminal under test in the first aspect or the first aspect.
For example, the apparatus comprises: the first establishing module is used for establishing connection between the terminal to be tested and the testing equipment; the first sending module is used for sending a control instruction to the test equipment; the first obtaining module is used for obtaining a test sample in the process of executing the control instruction by the test equipment and/or after the test equipment finishes executing the operation corresponding to the control instruction; and the first determining module is used for determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
By implementing the device for testing the terminal to be tested, after the authentication between the terminal to be tested and the testing equipment is passed, the communication connection is established between the terminal to be tested and the testing equipment, and the terminal sends a control instruction to the testing equipment so as to control the testing equipment to execute related testing operations (mainly referred to herein as test sample preparation conditions), specifically, the acquisition of the test sample can be divided into two cases, one of which, the terminal to be tested and the testing equipment make a predetermined agreement, once the testing equipment starts to execute the operation corresponding to the control instruction, the terminal to be tested can start the acquisition of the test sample, that is, in the process of the test equipment preparation conditions, the terminal to be tested can always acquire a plurality of related test samples; secondly, after the test equipment executes the operation corresponding to the control instruction, the task completion notice is returned to the terminal to be tested, then the terminal to be tested can obtain the test sample according to the test requirement, and finally the final test result is determined according to the obtained test sample and the preset standard corresponding to the test sample so as to complete the test of the terminal to be tested.
With reference to the second aspect of the present invention, in a first embodiment of the second aspect of the present invention, the test sample is an image sample, and the control instruction includes: shooting a background and/or shooting a distance, wherein the obtaining of the test sample comprises: and controlling a camera of the terminal to be tested to take a picture to obtain the image sample.
Through implementing above-mentioned device for testing terminal that awaits measuring, when the test sample is the image sample, test the camera of terminal that awaits measuring promptly, the camera test mainly lies in the test to its imaging quality, then control command can include but not limited to: the background and/or shooting distance are/is shot, when the test equipment receives the control instruction, shooting conditions (such as a preset shooting background, a preset shooting distance and the like) required by the camera test can be prepared, the terminal can be informed after the preparation, then the terminal to be tested controls the camera to shoot, and a sample image for testing can be obtained.
With reference to the second aspect of the present invention, in a second embodiment of the second aspect of the present invention, the test sample is an audio sample, and the control instruction includes: starting the recording, wherein the obtaining of the test sample comprises: controlling the terminal to be tested to play a test audio file; and receiving an audio sample recorded by the testing equipment.
By implementing the above apparatus for testing a terminal to be tested, the test sample may be an audio sample, and at this time, an audio module (such as a speaker) of the terminal to be tested is tested, and the audio distortion of the terminal to be tested is mainly tested, and then the control instruction includes but is not limited to: and starting the recording, wherein the test equipment receives the control instruction and then prepares the recording condition required by the test, starts the recording, informs the terminal to be tested after the recording is prepared, then the terminal to be tested starts to play the test audio file, and sends the recorded audio sample to the terminal so that the terminal to be tested can determine the final test result according to the audio sample and the corresponding preset standard.
With reference to the second aspect of the present invention, in a third implementation manner of the second aspect of the present invention, the test sample is a gravity-sensitive sample, the controlling instruction includes moving the terminal to be tested, and the acquiring the test sample includes: collecting gravity sensing data of the terminal to be tested; and using the gravity sensing data as the gravity sensing sample.
By implementing the device for testing the terminal to be tested, the test sample can be a gravity sensing sample, that is, the gravity sensor of the terminal to be tested is tested, for example, the accuracy of the gravity sensor can be tested, the control instruction includes but is not limited to moving the terminal to be tested, the position of the terminal to be tested is continuously moved by the testing equipment (the control instruction can be added in advance), the gravity sensor of the terminal to be tested can acquire relevant gravity sensing data (for example, position coordinate data), so that the gravity sensing samples of the terminal to be tested at different positions can be obtained, then the accuracy of the gravity sensor of the terminal to be tested is determined according to the gravity sensing samples and the preset standards thereof, the whole process is automatically completed, manual operation of the testing equipment is not needed, and the automation and the testing efficiency of the gravity sensing test are improved.
The modules or units included in the apparatus for testing a terminal to be tested are not limited to the above-mentioned naming modes.
These aspects of the present application will be more readily apparent from the following description of the embodiments.
A third aspect of the present invention provides a terminal under test, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method for testing the terminal under test according to the first aspect of the present invention or any embodiment of the first aspect.
A fourth aspect of the present invention provides a computer-readable storage medium storing computer instructions for causing a computer to perform the method for testing a terminal under test according to the first aspect of the present invention or any embodiment of the first aspect.
Drawings
The features and advantages of the present invention will be more clearly understood by reference to the accompanying drawings, which are illustrative and not to be construed as limiting the invention in any way, and in which:
fig. 1 shows a structure of a cellular phone in an embodiment of the present invention;
FIG. 2 shows a flowchart of a method for testing a terminal under test according to an embodiment of the invention;
FIG. 3 is a schematic diagram illustrating a UI architecture of a terminal under test according to an embodiment of the invention;
FIG. 4 is a functional schematic diagram of a terminal under test according to an embodiment of the present invention;
FIG. 5 shows another flowchart of a method for testing a terminal under test according to an embodiment of the invention;
FIG. 6 is a schematic structural diagram of an apparatus for testing a terminal under test according to an embodiment of the present invention;
FIG. 7 is a schematic diagram of another structure of an apparatus for testing a terminal under test according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of a terminal according to an embodiment of the present invention;
fig. 9 shows another structural diagram of a terminal according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a schematic diagram of an application scenario of an embodiment of the present invention. The mobile terminal is a mobile device such as a mobile phone or a tablet computer, the mobile terminal takes a mobile phone as an example, a partial structural block diagram of the mobile phone is shown in fig. 1, and the mobile phone includes a radio frequency circuit 110, a memory 120, an input unit 130, a display unit 140, a sensor 150, an audio circuit 160, a wireless module 170, a processor 180, a power supply 190, and the like. Those skilled in the art will appreciate that the handset configuration shown in fig. 1 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
Wherein the RF circuit 110 is used for receiving and transmitting signals during the transmission and reception of information or a call. The memory 120 is used to store software programs and modules, and the processor 180 executes various functional applications and data processing of the mobile phone by operating the software programs and modules stored in the memory 120. The input unit 130 is used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the cellular phone. The input unit 130 may include a touch panel 131 and other input devices 132. Other input devices 132 may include, but are not limited to, one or more of a physical keyboard, function keys, a mouse, and a joystick. The display unit 140 is used to display information input by the user or information provided to the user and various menus of the mobile phone. The display unit 140 may include a display panel 141. The touch panel 131 can cover the display panel 141, and when the touch panel 131 detects a touch operation on or near the touch panel 131, the touch operation is transmitted to the processor 180 to determine the type of the touch event, and then the processor 180 provides a corresponding visual output on the display panel 141 according to the type of the touch event.
The handset may also include at least one sensor 150, such as a light sensor, motion sensor, and other sensors. The light sensor may include an ambient light sensor for adjusting the brightness of the display panel 141 according to the brightness of ambient light, and a proximity sensor for turning off the display panel 141 and/or the backlight when the mobile phone is moved to the ear. The light sensor in this embodiment may be disposed on the front and back of the mobile phone, and is used to detect a shielding area when the user holds the mobile phone. The mobile phone can further comprise a pressure sensor which is arranged on the front side or the back side shell of the mobile phone and used for obtaining a shielding area when a user holds the mobile phone in a pressure detection mode. In addition, the mobile phone can be also provided with other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer and an infrared sensor, which are not described in detail.
Audio circuitry 160, speaker 161, microphone 162 may provide an audio interface between the user and the handset. The wireless module 170 may be a WIFI module, which provides a wireless internet access service to the user.
The processor 180 is a control center of the mobile phone, connects various parts of the entire mobile phone by using various interfaces and lines, and performs various functions of the mobile phone and processes data by operating or executing software programs and/or modules stored in the memory 120 and calling data stored in the memory 120, thereby integrally monitoring the mobile phone. Optionally, processor 180 may include one or more processing units. In addition, the mobile phone further comprises a power supply 190 for supplying power to each component, and the power supply 190 is logically connected with the processor 180 through a power management system, so that functions of charging, discharging, power consumption management and the like are managed through the power management system.
Although not shown, the mobile phone may further include a camera, a bluetooth module, etc., which are not described herein.
Referring to fig. 2, a method for testing a terminal to be tested according to an embodiment of the present invention can be applied to a terminal to be tested, such as a mobile phone, where the terminal to be tested and a testing device have the same baud rate, and the method includes:
s21: establishing connection between a terminal to be tested and test equipment; specifically, before the terminal to be tested is in communication connection with the test equipment, the terminal to be tested needs to perform identity authentication on the test equipment, after the authentication is passed, communication connection is established between the terminal to be tested and the test equipment, and the communication connection can be specifically realized through communication protocol development, for example, a unique request and a response instruction of the terminal to be tested and a camera test equipment (a single chip microcomputer part) can be formulated according to a 16-system or ASCII code rule, a unique communication instruction is agreed for each behavior of the test equipment (such as a switch of an air valve channel, a switch of an incandescent lamp and the like), and the test equipment can make a corresponding action according to the communication instruction received by the single chip microcomputer of the test equipment, so that the operation of the test equipment is highly automated. For example, the main UI of the test terminal is responsible for starting the test and displaying the test result, and the PL2303 chip is integrated in the transmission device RS232 for serial communication between the terminal to be tested and the test device, so that the communication instruction sent by the terminal to be tested can perform data interaction with the single chip microcomputer system of the test device through the serial port.
S22: sending a control instruction to the test equipment; specifically, after the communication connection is established, the terminal to be tested may send a control instruction to the test equipment according to the test requirement of the terminal to be tested, so as to control the test equipment to execute a related test operation (here, mainly referring to a preparation condition for obtaining a test sample), and after the test equipment executes an operation corresponding to the control instruction, a task completion notification is returned to the terminal to be tested, so that the terminal to be tested may perform a next test procedure.
S23: after the test equipment executes the operation corresponding to the control instruction, obtaining a test sample; after the test equipment prepares the conditions required by obtaining the test sample according to the control instruction, the terminal to be tested can obtain the sample to be tested in the conditions prepared by the test equipment according to the test requirements.
S24: and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample. And finally, determining a final test result according to the test sample acquired in the step S23 and the preset standard corresponding to the test sample to complete the test of the terminal to be tested.
Optionally, if the test sample is an image sample, the control instruction includes: shooting a background and/or shooting a distance, and obtaining a test sample comprises: and controlling a camera of the terminal to be tested to shoot to obtain an image sample. Specifically, when the test sample is an image sample, that is, a camera of the terminal to be tested is tested, the camera test mainly includes testing the imaging quality of the camera, and the control instruction may include but is not limited to: shooting background and/or shooting distance, when the test equipment receives the control instruction, the test equipment prepares the shooting conditions (such as preset shooting background and preset shooting distance) required by the camera test, informs the terminal after the preparation, then the terminal to be tested controls the camera to shoot, namely, a sample image for testing can be obtained, for example, in a real-time application scene, the terminal to be tested can use native API of android Camera to realize functions of automatic photographing, automatic focusing, imaging quality analysis (where a third party SO library needs to be developed), and the like, wherein the main thread is used for automatically taking pictures and receiving response instructions fed back by the singlechip system of the test equipment in real time, therefore, the next action is responded in time, all control instructions and result judgment are realized by the terminal to be tested, and the scheme can be realized through the APP main framework shown in the figure 3. Therefore, the whole process is automatically finished, manual operation of test equipment is not needed, and the automation and the efficiency of sample image acquisition are improved.
As a specific implementation manner, as shown in fig. 4, the implementation of the test of the mobile phone camera in this embodiment is a schematic framework diagram, and the functions of each module are as follows:
the module A is a control function class, a related agreed control instruction is sent to the test equipment through the equipment to be tested, after the response success instruction of the test equipment is fed back, the test equipment can act according to the agreed behavior of the control instruction, for example, the white board is pushed right above the front camera, and the backlight of the white board is turned on.
The module B is an application function class, when the photographing condition is met (namely after the test equipment executes the operation corresponding to the control instruction), the terminal to be tested automatically photographs according to the test requirement (whether focusing is needed or not and the like), and analyzes the resolution of the imaging picture according to the actual requirement and the preset standard, so that whether the function of the camera is qualified or not is detected.
And the module C is a display result type of the UI, so that a test result can be displayed, and the direct observation of related personnel is facilitated.
At present, relatively mature testing equipment is developed in the market, the switch of each channel is controlled through an air valve generally, hardware conditions required by photographing are pushed to be in place through an air cylinder, level switches of the channels are controlled through relays, various light required by photographing is achieved, and the on-off control of each relay is achieved through a single chip microcomputer. Taking a certain type of test equipment on the market as an example, the following simple functional description is made on each functional module of the test equipment:
1. the ARM control board is used for responding a control instruction sent by the terminal to be tested and controlling the opening and closing of the electromagnetic valve;
2. a 24V power supply is used for stably supplying power to the ARM control board;
3. the electromagnetic valve is used for controlling the opening and closing of the air pipe and the opening and closing of the incandescent lamp;
4. a clamp carrier plate is used for placing a terminal to be tested;
5. the cylinder is used for controlling the size of the airflow;
6. a light source control board controls the brightness of the incandescent lamp;
7. the upper and lower lamp panels are used for testing a remote charge picture;
in this embodiment, an agreed communication protocol may be burned on a control board of the test device, and then the device to be tested (for example, a mobile phone) is connected to the test device through a serial port connection mode of the PL2303, so as to implement real-time interaction, thereby completing an automated test of the camera of the terminal to be tested.
Optionally, the test sample is an audio sample, and the control instruction includes: starting the recording, and obtaining the test sample comprises: controlling the terminal to be tested to play a test audio file; an audio sample recorded by the testing device is received. The test sample may also be an audio sample, in which an audio module (such as a speaker) of the terminal to be tested is tested, and the audio distortion is mainly tested, and the control instruction includes but is not limited to: and starting the recording, wherein the test equipment receives the control instruction and then prepares the recording condition required by the test, starts the recording, informs the terminal to be tested after the recording is prepared, then the terminal to be tested starts to play the test audio file, and sends the recorded audio sample to the terminal so that the terminal to be tested can determine the final test result according to the audio sample and the corresponding preset standard.
In the method for testing the terminal to be tested provided in this embodiment, after the authentication between the terminal to be tested and the testing device is passed, establishing communication connection between the terminal to be tested and the test equipment, sending control instructions to the test equipment through the terminal to control the test equipment to execute relevant test operations, after the test equipment executes the operation corresponding to the control instruction, the task completion notification is returned to the terminal to be tested, then the terminal to be tested can obtain a test sample according to the test requirement, and finally the final test result is determined according to the obtained test sample and the preset standard corresponding to the test sample, to complete the test of the terminal to be tested, compared with the prior art, not only can at least one PC be abandoned, and the terminal controls the test equipment without personnel operation, thereby greatly reducing the test cost and improving the automation and the test efficiency of the terminal test.
Referring to fig. 5, a method for testing a terminal to be tested according to an embodiment of the present invention can be applied to a terminal to be tested, such as a mobile phone, where the terminal to be tested and a testing device have the same baud rate, and the method includes:
s51: establishing connection between a terminal to be tested and test equipment; specifically, before the terminal to be tested is in communication connection with the test equipment, the terminal to be tested needs to perform identity authentication on the test equipment, after the authentication is passed, communication connection is established between the terminal to be tested and the test equipment, and the communication connection can be specifically realized through communication protocol development, for example, a unique request and a response instruction of the terminal to be tested and a camera test equipment (a single chip microcomputer part) can be formulated according to a 16-system or ASCII code rule, a unique communication instruction is agreed for each behavior of the test equipment (such as a switch of an air valve channel, a switch of an incandescent lamp and the like), and the test equipment can make a corresponding action according to the communication instruction received by the single chip microcomputer of the test equipment, so that the operation of the test equipment is highly automated. For example, the main UI of the test terminal is responsible for starting the test and displaying the test result, and the PL2303 chip is integrated in the transmission device RS232 for serial communication between the terminal to be tested and the test device, so that the communication instruction sent by the terminal to be tested can perform data interaction with the single chip microcomputer system of the test device through the serial port.
S52: sending a control instruction to the test equipment; specifically, after the communication connection is established, the terminal to be tested may send a control instruction to the test equipment according to the test requirement of the terminal to be tested, so as to control the test equipment to execute a related test operation (here, mainly referring to a preparation condition for obtaining a test sample), so that the terminal to be tested can obtain the test sample.
S53: in the process of executing the control instruction by the test equipment, obtaining a test sample; specifically, the terminal to be tested and the test equipment make a pre-appointment, once the test equipment starts to execute the operation corresponding to the control instruction, the terminal to be tested can start to obtain the test sample, that is, the terminal to be tested can always obtain a plurality of relevant test samples in the process of preparing conditions of the test equipment.
S54: and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample. The terminal to be tested determines a final test result according to the plurality of test samples acquired in the step S53 and the preset standard corresponding to the test samples, so as to complete the test of the terminal to be tested.
Optionally, the test sample is a gravity-sensitive sample, the control instruction includes moving the terminal to be tested, and obtaining the test sample includes: collecting gravity sensing data of a terminal to be detected; and taking the gravity sensing data as a gravity sensing sample. In this embodiment, the test sample may be a gravity-sensitive sample, that is, the gravity sensor of the terminal to be tested is tested, for example, the accuracy of the gravity-sensitive sample can be tested, the control instruction includes but is not limited to moving the terminal to be tested, the position of the terminal to be tested is continuously moved by the test equipment (specifically, the control instruction may be added in advance), in this process, the gravity sensor of the terminal to be tested may acquire related gravity-sensitive data (for example, position coordinate data), so that the gravity-sensitive samples of the terminal to be tested at different positions can be obtained, then, the accuracy of the gravity sensor of the terminal to be tested is determined according to the gravity-sensitive samples and preset standards thereof, the whole process is automatically completed, the test equipment does not need to be manually operated, and the automation and.
In the method for testing a terminal to be tested provided in this embodiment, after the authentication between the terminal to be tested and the testing device is passed, a communication connection is established between the terminal to be tested and the testing device, and a control instruction is sent to the testing device through the terminal to be tested to control the testing device to perform a related testing operation, specifically, the terminal to be tested and the testing device make a pre-appointment, once the testing device starts to perform an operation corresponding to the control instruction, the terminal to be tested can start to obtain a test sample, that is, in the process of preparing conditions of the testing device, the terminal to be tested can always obtain a plurality of related test samples, and finally the terminal to be tested determines a final testing result according to the plurality of obtained test samples and a preset standard corresponding to the test samples to complete the testing of the terminal to be tested, compared with the prior art, not only at least one PC can be abandoned, but also the testing device can, the test method has the advantages that the operation of personnel is not needed, the test cost is greatly reduced, and the automation and the test efficiency of the test process of the terminal to be tested are improved.
Referring to fig. 6, which is a schematic structural diagram of an apparatus for testing a terminal to be tested according to an embodiment of the present invention, which may be applied to a terminal to be tested, such as a mobile phone, where the terminal to be tested and a testing device have the same baud rate, the apparatus includes:
a first establishing module 61, configured to establish a connection between a terminal to be tested and a test device; see step S21 in the above embodiment for details.
A first sending module 62, configured to send a control instruction to the testing device; see step S22 in the above embodiment for details.
The first obtaining module 63 is configured to obtain a test sample after the test equipment executes an operation corresponding to the control instruction; see step S23 in the above embodiment for details.
The first determining module 64 is configured to determine a test result of the terminal to be tested according to the test sample and a preset standard corresponding to the test sample. See step S24 in the above embodiment for details.
Optionally, in some embodiments of the present invention, the test sample is an image sample, and the control instruction includes: shooting a background and/or shooting a distance, and obtaining a test sample comprises: and controlling a camera of the terminal to be tested to shoot to obtain an image sample. For details, see the relevant detailed description in the above embodiments.
Optionally, in some embodiments of the present invention, the test sample is an audio sample, and the control instruction includes: starting the recording, and obtaining the test sample comprises: controlling the terminal to be tested to play a test audio file; an audio sample recorded by the testing device is received. For details, see the relevant detailed description in the above embodiments.
According to the device for testing the terminal to be tested, after the terminal to be tested passes the authentication with the testing equipment, the communication connection is established between the terminal to be tested and the testing equipment, the control instruction is sent to the testing equipment through the terminal to control the testing equipment to execute the related testing operation, after the testing equipment executes the operation corresponding to the control instruction, the task completion notification is returned to the terminal to be tested, then the terminal to be tested can obtain the testing sample according to the testing requirement, and finally the final testing result is determined according to the obtained testing sample and the preset standard corresponding to the testing sample to complete the testing of the terminal to be tested.
Referring to fig. 7, a schematic structural diagram of an apparatus for testing a terminal to be tested according to an embodiment of the present invention may be applied to a terminal to be tested, such as a mobile phone, where the terminal to be tested and a testing device have the same baud rate, and the apparatus includes:
a second establishing module 71, configured to establish a connection between the terminal to be tested and the testing device; see step S51 in the above embodiment for details.
A second sending module 72, configured to send a control instruction to the testing device; see step S52 in the above embodiment for details.
The second obtaining module 73 is configured to obtain a test sample in a process of executing the control instruction by the test equipment; see step S53 in the above embodiment for details.
And a second determining module 74, configured to determine a test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample. See step S54 in the above embodiment for details.
Optionally, in some embodiments of the present invention, the test sample is a gravity-sensitive sample, the control instruction includes moving the terminal to be tested, and the obtaining the test sample includes: collecting gravity sensing data of a terminal to be detected; and taking the gravity sensing data as a gravity sensing sample. For details, see the relevant detailed description in the above embodiments.
According to the device for testing the terminal to be tested, after the authentication between the terminal to be tested and the testing equipment is passed, the communication connection is established between the terminal to be tested and the testing equipment, and the control instruction is sent to the testing equipment through the terminal to be tested so as to control the testing equipment to execute the relevant testing operation, specifically, the terminal to be tested and the testing equipment are agreed in advance, once the testing equipment starts to execute the operation corresponding to the control instruction, the terminal to be tested can start to obtain the testing sample, namely, in the process of preparing the condition of the testing equipment, the terminal to be tested can obtain a plurality of relevant testing samples all the time, finally, the terminal to be tested determines the final testing result according to the plurality of obtained testing samples and the preset standard corresponding to the testing samples so as to complete the testing of the terminal to be tested, compared with the prior art, at least one PC can be abandoned, and the testing, the test method has the advantages that the operation of personnel is not needed, the test cost is greatly reduced, and the automation and the test efficiency of the test process of the terminal to be tested are improved.
An embodiment of the present invention further provides a terminal, including: any of the embodiments described above with reference to fig. 6 is an apparatus for testing a terminal under test.
A terminal of the present invention is described below by taking a smart phone as an example.
As shown in fig. 8, correspondingly, a terminal provided in the embodiment of the present invention includes: at least one processor 81, a memory 82, for example, one processor in fig. 8, the processor 81 and the memory 82 are connected by a bus 80, the memory 82 stores instructions executable by the at least one processor 81, and the instructions are executed by the at least one processor 81 to cause the at least one processor to perform the following method:
establishing connection between the terminal to be tested and the test equipment;
sending a control instruction to the test equipment;
after the test equipment executes the operation corresponding to the control instruction, obtaining a test sample;
and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
Optionally, in some embodiments of the present invention, the test sample is an image sample, and the control instruction includes: shooting a background and/or shooting a distance, wherein the obtaining of the test sample comprises: and controlling a camera of the terminal to be tested to take a picture to obtain the image sample.
Optionally, in some embodiments of the present invention, the test sample is an audio sample, and the control instruction includes: starting the recording, wherein the obtaining of the test sample comprises: controlling the terminal to be tested to play a test audio file; and receiving an audio sample recorded by the testing equipment.
The related description may be understood by referring to the related description and effect corresponding to the step in fig. 2, and will not be described in detail herein.
According to the terminal to be tested provided by the embodiment, after the terminal to be tested passes the authentication with the test equipment, the communication connection is established between the terminal to be tested and the test equipment, the control instruction is sent to the test equipment through the terminal to control the test equipment to execute the relevant test operation, after the test equipment executes the operation corresponding to the control instruction, the task completion notification is returned to the terminal to be tested, then the terminal to be tested can obtain the test sample according to the test requirement, and finally the final test result is determined according to the obtained test sample and the preset standard corresponding to the test sample to complete the test of the terminal to be tested.
An embodiment of the present invention further provides a terminal, including: any of the embodiments described above with reference to fig. 7 is an apparatus for testing a terminal under test.
A terminal of the present invention is described below by taking a smart phone as an example.
As shown in fig. 9, correspondingly, a terminal provided in the embodiment of the present invention includes: at least one processor 91 and a memory 92, where fig. 9 illustrates one processor, the processor 91 and the memory 92 are connected by a bus 90, the memory 92 stores instructions executable by the at least one processor 91, and the instructions are executed by the at least one processor 91 to cause the at least one processor to perform the following method:
establishing connection between the terminal to be tested and the test equipment;
sending a control instruction to the test equipment;
acquiring a test sample in the process of executing the control instruction by the test equipment;
and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
Optionally, in some embodiments of the present invention, the test sample is a gravity-sensitive sample, the controlling instruction includes moving the terminal to be tested, and the obtaining the test sample includes: collecting gravity sensing data of the terminal to be tested; and using the gravity sensing data as the gravity sensing sample.
The related description may be understood by referring to the related description and effect corresponding to the step in fig. 5, which is not described herein too much.
The terminal to be tested provided by the embodiment has the advantages that the test cost is reduced, and the automation and the test efficiency of the test process of the terminal to be tested are improved.
After the authentication of the terminal to be tested and the test equipment is passed, communication connection is established between the terminal to be tested and the test equipment, and a control instruction is sent to the test equipment through the terminal to be tested so as to control the test equipment to execute relevant test operation, specifically, the terminal to be tested and the test equipment are agreed in advance, once the test equipment starts to execute operation corresponding to the control instruction, the terminal to be tested can start to obtain test samples, namely, the terminal to be tested can always obtain a plurality of relevant test samples in the process of preparing conditions of the test equipment, and finally the terminal to be tested determines a final test result according to the obtained plurality of test samples and a preset standard corresponding to the test samples so as to finish the test of the terminal to be tested. The automation and the test efficiency of the test process of the terminal to be tested are improved.
The embodiment of the invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions can execute all or part of the processes in the method of the embodiment. The storage medium may be a magnetic Disk, an optical Disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a Flash Memory (Flash Memory), a Hard Disk (Hard Disk Drive, abbreviated as HDD) or a Solid State Drive (SSD), etc.; the storage medium may also comprise a combination of memories of the kind described above.
Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations fall within the scope defined by the appended claims.

Claims (10)

1. A method for testing a terminal under test, wherein the terminal under test has the same baud rate as a test device, the method being used in the terminal under test, wherein the method comprises:
establishing connection between the terminal to be tested and the test equipment;
sending a control instruction to the test equipment;
acquiring a test sample in the process of executing the control instruction by the test equipment and/or after the test equipment finishes executing the operation corresponding to the control instruction; the test sample is an image sample, an audio sample or a gravity sensing sample;
and determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
2. The method according to claim 1, wherein when the test sample is an image sample, the control instruction comprises: shooting a background and/or shooting a distance, wherein the obtaining of the test sample comprises:
and controlling a camera of the terminal to be tested to take a picture to obtain the image sample.
3. The method according to claim 1, wherein when the test sample is an audio sample, the control instruction comprises: starting the recording, wherein the obtaining of the test sample comprises:
controlling the terminal to be tested to play a test audio file;
and receiving an audio sample recorded by the testing equipment.
4. The method according to claim 1, wherein when the test sample is a gravity-sensitive sample, the controlling instructions comprise moving the terminal under test, and the obtaining the test sample comprises:
collecting gravity sensing data of the terminal to be tested;
and using the gravity sensing data as the gravity sensing sample.
5. An apparatus for testing a terminal under test, wherein the terminal under test has the same baud rate as a test device, the apparatus being used in the terminal under test, wherein the apparatus comprises:
the first establishing module is used for establishing connection between the terminal to be tested and the testing equipment;
the first sending module is used for sending a control instruction to the test equipment;
the first obtaining module is used for obtaining a test sample in the process of executing the control instruction by the test equipment and/or after the test equipment finishes executing the operation corresponding to the control instruction; the test sample is an image sample, an audio sample or a gravity sensing sample;
and the first determining module is used for determining the test result of the terminal to be tested according to the test sample and the preset standard corresponding to the test sample.
6. The apparatus according to claim 5, wherein when the test sample is an image sample, the control instruction comprises: shooting a background and/or shooting a distance, wherein the obtaining of the test sample comprises:
and controlling a camera of the terminal to be tested to take a picture to obtain the image sample.
7. The apparatus according to claim 5, wherein when the test sample is an audio sample, the control instruction comprises: starting the recording, wherein the obtaining of the test sample comprises:
controlling the terminal to be tested to play a test audio file;
and receiving an audio sample recorded by the testing equipment.
8. The apparatus of claim 5, wherein when the test sample is a gravity-sensitive sample, the control instruction comprises moving the terminal under test, and the obtaining the test sample comprises:
collecting gravity sensing data of the terminal to be tested;
and using the gravity sensing data as the gravity sensing sample.
9. A terminal under test comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method for testing a terminal under test according to any of claims 1 to 4 when executing the program.
10. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method for testing a terminal under test according to any one of claims 1 to 4.
CN201710661655.7A 2017-08-04 2017-08-04 Method, device, terminal and storage medium for testing terminal to be tested Active CN107631750B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710661655.7A CN107631750B (en) 2017-08-04 2017-08-04 Method, device, terminal and storage medium for testing terminal to be tested

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710661655.7A CN107631750B (en) 2017-08-04 2017-08-04 Method, device, terminal and storage medium for testing terminal to be tested

Publications (2)

Publication Number Publication Date
CN107631750A CN107631750A (en) 2018-01-26
CN107631750B true CN107631750B (en) 2021-05-18

Family

ID=61099154

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710661655.7A Active CN107631750B (en) 2017-08-04 2017-08-04 Method, device, terminal and storage medium for testing terminal to be tested

Country Status (1)

Country Link
CN (1) CN107631750B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108683465B (en) * 2018-05-16 2021-08-17 深圳市广和通无线通信软件有限公司 Signaling test method and device, computer equipment and storage medium
CN112019988B (en) * 2020-07-28 2022-06-14 广州亚美智造科技有限公司 Method and device for testing audio equipment, test fixture, equipment and storage medium
CN112468641B (en) * 2020-10-26 2023-04-21 百果园技术(新加坡)有限公司 Program testing method, device, terminal and storage medium
CN113726604A (en) * 2021-08-27 2021-11-30 四川九洲电器集团有限责任公司 Antenna interface unit testing method, device, terminal and readable storage medium
CN114006844B (en) * 2021-09-30 2024-01-12 武汉通力路达科技有限公司 WIFI throughput test method, WIFI throughput test device and computer readable storage medium

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20030060364A (en) * 2002-01-08 2003-07-16 김영호 Inspection System of Mobile Phone Bar Code and Identity Number
CN1522086A (en) * 2003-02-12 2004-08-18 华冠通讯股份有限公司 Automatic test system and method for handset function
CN100554916C (en) * 2006-04-28 2009-10-28 孙盈军 A kind of method of testing of digital product and isolated plant thereof
CN101568042A (en) * 2008-04-21 2009-10-28 鸿富锦精密工业(深圳)有限公司 Mobile phone keyboard lamp testing system and mobile phone keyboard lamp testing method
CN101577922A (en) * 2008-05-06 2009-11-11 鸿富锦精密工业(深圳)有限公司 Device and method for testing sound system of mobile phone sound
TWI493957B (en) * 2008-10-17 2015-07-21 Chi Mei Comm Systems Inc System and method for testing shaking function of a mobile phone
US8793094B2 (en) * 2010-06-04 2014-07-29 Apple Inc. Vibrator motor speed determination in a mobile communications device
CN102271177B (en) * 2011-07-18 2015-06-17 惠州Tcl移动通信有限公司 Method and system for calibrating proximity sensor of mobile phone
CN203151602U (en) * 2012-12-26 2013-08-21 天津三星通信技术研究有限公司 Portable mobile phone test system
CN103607492B (en) * 2013-08-26 2018-01-16 上海斐讯数据通信技术有限公司 A kind of test system and method for testing to cell phone mainboard function
CN104135553B (en) * 2014-08-01 2017-03-22 南京声准科技有限公司 Method and device for audio test by automatically pressing communication terminal
CN104243651A (en) * 2014-09-25 2014-12-24 声科科技(南京)有限公司 Automatic self-test method and device of communication terminals
CN104608120B (en) * 2015-02-05 2017-04-26 天津市康凯特软件科技有限公司 Manipulator device for automatic testing of mobile phone and use method
CN105790859A (en) * 2016-02-29 2016-07-20 华为技术有限公司 Method and apparatus for testing electronic device
CN106506762A (en) * 2016-09-23 2017-03-15 惠州Tcl移动通信有限公司 Test equipment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Smartphone with Augmented Gateway Functionality as Opportunistic WSN Gateway Device;Pesko, M等;《WIRELESS PERSONAL COMMUNICATIONS》;20141031;第78卷(第3期);全文 *
基于ARM9设计低压电力载波测试终端的研究;宁娟等;《广东通信科技》;20121015(第10期);全文 *

Also Published As

Publication number Publication date
CN107631750A (en) 2018-01-26

Similar Documents

Publication Publication Date Title
CN107631750B (en) Method, device, terminal and storage medium for testing terminal to be tested
US20170091551A1 (en) Method and apparatus for controlling electronic device
CN110557575B (en) Method for eliminating glare and electronic equipment
CN104503691A (en) Equipment control method and device
CN105468152A (en) Terminal operation control method and device based on wearable equipment, and equipment
US20170013456A1 (en) Method and device for testing a terminal
CN103916468B (en) Method for upgrading system, terminal, server and upgrade-system
KR102314690B1 (en) Device And Communication Connection Method Thereof
CN104506443A (en) Router setting interface display method and device
CN103024200B (en) Be applied to image pickup method and the filming apparatus of intelligent terminal
EP3185131A1 (en) Method and device for switching state
CN105487680A (en) Terminal screen capture method and apparatus and terminal
CN105392251A (en) Method, device and system for managing intelligent lamp
CN105376410A (en) Method and device for setting alarm clock
CN105491292A (en) Method and device for shooting fill-in light
CN105635553B (en) Image shooting method and device
CN105589345A (en) Apparatus control method and device
CN110187769B (en) Preview image viewing method, equipment and computer readable storage medium
CN107770449B (en) Continuous shooting method, electronic device and storage medium
CN113868132A (en) Application program testing method and device, electronic equipment and storage medium
CN113705389A (en) Face recognition module testing method and device, storage medium and electronic equipment
CN105517280A (en) Method and device for lighting
CN106612149A (en) Radio frequency circuit test method, device, system and mobile terminal
CN106791169A (en) Screen control method and device
CN106789472A (en) Consumer electronics control CEC function detecting methods, apparatus and system

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
GR01 Patent grant
GR01 Patent grant