Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
In the production process of the PCB main board, a factory often needs to test the HDMI interface on the main board to determine whether the CEC circuit of the HDMI interface on the main board is normal.
Currently, the main method for testing the CEC circuit of the HDMI interface on the motherboard to be tested is to manually operate the remote controller, send a functional instruction to the CEC device connected to the motherboard to be tested, and then observe whether the CEC device connected to the motherboard to be tested makes a functional response corresponding to the functional instruction to determine whether the CEC circuit of the HDMI interface on the motherboard to be tested is normal.
However, this method requires manual operation and determination, and the testing efficiency is low, which affects the mass production of PCB main boards in a factory.
Based on this, embodiments of the present application provide a method, an apparatus, a terminal and a computer readable storage medium for testing a CEC circuit of an HDMI interface, which can automatically perform a CEC circuit test of the HDMI interface, and improve the CEC circuit test efficiency of the HDMI interface.
In order to explain the technical means of the present application, the following description will be given by way of specific examples.
When the CEC circuit of the HDMI interface provided on the main board to be tested is tested, as shown in fig. 1, the main board to be tested is connected to the CEC device supporting the CEC function through the HDMI interface. At this time, the CEC circuit of the HDMI interface on the motherboard to be tested can be tested by using the CEC circuit testing method of the HDMI interface provided by the present application.
It should be noted that, as shown in fig. 2, the CEC device supporting the CEC function connected to the main board to be tested may be provided by a signal source, and when the CEC circuit of the HDMI interface disposed on the main board to be tested is tested, the main board to be tested may be connected to one or more CEC devices supporting the CEC function in the signal source through the HDMI interface. At this time, the CEC circuit of the HDMI interface on the motherboard to be tested can also be tested by using the CEC circuit testing method of the HDMI interface provided by the present application.
Fig. 3 is a schematic diagram illustrating an implementation flow of a CEC circuit testing method for an HDMI interface according to an embodiment of the present application, where the method is applicable to a terminal, and can be executed by a CEC circuit testing device of an HDMI interface configured on the terminal, and is suitable for a situation where a CEC circuit test of the HDMI interface needs to be performed automatically, so as to improve CEC circuit testing efficiency of the HDMI interface. The terminal can be an intelligent terminal such as a smart phone, a computer and a smart television.
The CEC circuit test method of the HDMI interface described above may includesteps 301 to 302.
Step 301, acquiring the number of CEC devices connected to the main board to be tested through the main board to be tested.
In the embodiment of the application, because when the CEC circuit of the HDMI interface is tested, all CEC functions and indexes of the HDMI interface do not need to be tested, only it needs to be determined whether the CEC circuit of the HDMI interface arranged on the main board to be tested can realize communication between the main board to be tested and the CEC device, i.e., it is determined whether the CEC circuit of the HDMI interface arranged on the main board to be tested can normally work, therefore, the number of the CEC devices connected with the main board to be tested can be obtained through the main board to be tested, and the number is compared with the number of the CEC devices actually connected with the main board to be tested, thereby completing the test of the CEC circuit of the HDMI interface.
Specifically, as shown in fig. 4, in some embodiments of the present application, the obtaining, by the motherboard to be tested, the number of CEC devices connected to the motherboard to be tested may include:step 401 tostep 402.
Step 401, sending a CEC broadcast message to the CEC device connected to the motherboard to be tested through the motherboard to be tested, and receiving, by the motherboard to be tested, CEC device information sent by the CEC device according to the received CEC broadcast message.
And 402, acquiring the number of CEC devices connected with the mainboard to be tested, which are acquired by the mainboard to be tested according to the CEC device information.
That is, the motherboard to be tested may send a CEC broadcast message to the CEC device connected to the motherboard to be tested; after receiving the CEC broadcast message sent by the motherboard to be tested, the CEC device may feed back CEC device information to the motherboard to be tested; after the main board to be tested receives the CEC device information fed back by the CEC device, the number of CEC devices connected to the main board to be tested can be obtained according to the CEC device information. At this time, the terminal may directly obtain the number of CEC devices connected to the main board to be tested, which is obtained by the main board to be tested.
It should be noted that, if the CEC circuit of the HDMI interface on the main board to be tested is normal, the main board to be tested may receive CEC device information sent by all CEC devices connected to the main board to be tested; if the CEC circuit of any HDMI interface on the mainboard to be tested is abnormal, the mainboard to be tested cannot receive the CEC equipment information sent by all the CEC equipment connected with the mainboard to be tested.
For example, 3 HDMI interfaces on the tv PCB main board all support CEC functions, the 3 HDMI interfaces are respectively connected to 3 CEC devices that support CEC functions, the tv PCB main board can send a CEC broadcast message to the CEC device connected to the tv PCB main board, if the CEC circuits of the 3 HDMI interfaces are all normal, the CEC device information fed back by the CEC device received by the tv PCB main board will be equal to 3, and if the CEC circuit of any HDMI interface in the 3 HDMI interfaces is abnormal, the CEC device information received by the tv PCB main board will be less than 3.
In some embodiments of the present application, the main board to be tested may include a CEC device list, and after the main board to be tested receives CEC device information sent by a CEC device connected to the main board to be tested, the main board to be tested may automatically accumulate, according to the CEC device information, the number of CEC devices connected to the main board to be tested in the CEC device list; at this time, the terminal may directly obtain the number of CEC devices connected to the main board to be tested through the CEC device list.
Step 302, comparing the number of the CEC devices connected to the main board to be tested, which are acquired by the main board to be tested, with the preset CEC device number, and obtaining a test result whether the CEC circuit of the HDMI interface is normal or not according to the comparison result.
The preset CEC equipment number is the number of CEC equipment actually connected with the mainboard to be tested.
In some embodiments of the present application, the preset CEC device number may be obtained before comparing the number of CEC devices connected to the main board to be tested, which is obtained by the main board to be tested, with the preset CEC device number. For example, a manually input preset number of CEC devices may be acquired.
It should be noted that, in actual operation, the number of CEC devices actually connected to the motherboard to be tested may be equal to the maximum number of CEC devices that can be supported by the motherboard to be tested; at this time, by using the method for testing the CEC circuit of the HDMI interface provided by the present application, the test of the CEC circuits of all HDMI interfaces supporting the CEC function on the main board to be tested can be completed.
Specifically, after acquiring the number of CEC devices connected to the main board to be tested through the main board to be tested and acquiring the preset number of CEC devices, the above-mentioned test result of whether the CEC circuit of the HDMI interface is normal according to the comparison result may include: if the number of the CEC devices connected with the mainboard to be tested, which is acquired by the mainboard to be tested, is the same as the preset number of the CEC devices, the CEC circuit of the HDMI interface is confirmed to be normal; and if the number of the CEC devices connected with the mainboard to be tested, which is acquired by the mainboard to be tested, is different from the preset CEC device number, determining that the CEC circuit of the HDMI interface is abnormal.
If the number of the CEC devices connected with the main board to be tested and acquired by the main board to be tested is the same as the preset number of the CEC devices, the number of the CEC devices connected with the main board to be tested and acquired by the main board to be tested is the same as the actual number of the CEC devices connected with the main board to be tested, and therefore the HDMI interface connected with the CEC devices on the main board to be tested can realize communication between the main board to be tested and the CEC devices, and therefore the CEC circuit of the HDMI interface can be confirmed to be normal. If the number of the CEC devices connected with the main board to be tested and acquired by the main board to be tested is different from the preset number of the CEC devices, the number of the CEC devices connected with the main board to be tested and acquired by the main board to be tested are different from the actual number of the CEC devices connected with the main board to be tested, and it is described that one or more HDMI interfaces exist in the HDMI interface connected with the CEC devices on the main board to be tested, so that the communication between the main board to be tested and the CEC devices cannot be realized, and therefore, the abnormality of the CEC circuit of the HDMI.
In practical application, the same HDMI interface may be simultaneously connected to a plurality of CEC devices supporting CEC functions, and similarly, if the number of CEC devices connected to the main board to be tested, which is acquired by the main board to be tested, is the same as the preset number of CEC devices, it may be determined that the CEC circuit of the HDMI interface is normal; if the number of the CEC devices connected with the mainboard to be tested, which is acquired by the mainboard to be tested, is different from the preset CEC device number, the abnormality of the CEC circuit of the HDMI interface can be confirmed.
For example, 3 HDMI interfaces on the main board of the tv PCB support CEC functions, wherein 2 HDMI interfaces are respectively connected to 2 CEC devices supporting CEC functions, and 1 HDMI interface is simultaneously connected to 2 CEC devices supporting CEC functions. At this time, the television PCB main board sends a CEC broadcast message to the CEC device connected to the television PCB main board, and if the CEC device information fed back by the CEC device received by the television PCB main board is equal to 4, it can be confirmed that the CEC circuits of the 3-way HDMI interface are normal; if the number of the CEC device information received by the main board of the television PCB is less than 4, it can be confirmed that there is an abnormality in the CEC circuit of one or more HDMI interfaces among the 3 HDMI interfaces.
In the embodiment of the application, when the CEC circuit of the HDMI interface arranged on the mainboard to be tested is tested, the mainboard to be tested is connected with the CEC equipment supporting the CEC function through the HDMI interface, at this time, the terminal can obtain the number of the CEC equipment connected with the mainboard to be tested through the mainboard to be tested, then the number of the CEC equipment connected with the mainboard to be tested and obtained by the mainboard to be tested is compared with the preset number of the CEC equipment, and according to the comparison result, whether the CEC circuit of the HDMI interface arranged on the mainboard to be tested can realize the communication between the mainboard to be tested and the CEC equipment is determined, so as to obtain the test result whether the CEC circuit of the HDMI interface is normal or not, the process does not need to manually operate and judge, the automatic test of the CEC circuit of the HDMI interface on the mainboard to be tested is realized, and the CEC circuit test, and the production efficiency of the mainboard to be tested.
In order to further improve the efficiency of the CEC circuit test of the HDMI interface, in some embodiments of the present application, the sending the CEC broadcast message to the CEC device connected to the motherboard to be tested through the motherboard to be tested may include: and automatically sending the CEC broadcast message to CEC equipment connected with the mainboard to be tested when the mainboard to be tested is powered on.
For example, the main board to be tested is set, so that when the main board to be tested is powered on, a CEC broadcast message can be automatically sent to CEC devices connected with the main board to be tested, and after CEC device information sent by the CEC devices connected with the main board to be tested is received, the number of the CEC devices connected with the main board to be tested in a CEC device list is automatically accumulated according to the CEC device information; when the terminal tests the CEC circuit of the HDMI, the number of CEC devices connected with the mainboard to be tested can be directly obtained through the CEC device list, the number of CEC devices connected with the mainboard to be tested does not need to be obtained by waiting for the mainboard to be tested, and therefore the efficiency of CEC circuit testing of the HDMI is improved.
In practical applications, a part of the main boards to be tested cannot automatically send a CEC broadcast message to the CEC device connected to the main board to be tested when being powered on, and in order to improve the universality of the CEC circuit testing method of the HDMI interface, in some other embodiments of the present application, the sending of the CEC broadcast message to the CEC device connected to the main board to be tested by using the main board to be tested may include: and sending a CEC equipment number obtaining instruction to the mainboard to be tested, and sending a CEC broadcast message to the CEC equipment connected with the mainboard to be tested by the mainboard to be tested according to the received CEC equipment number obtaining instruction.
That is to say, the main board to be tested may send, after receiving the CEC device number acquisition instruction sent by the terminal, a CEC broadcast message to the CEC devices connected to the main board to be tested according to the received CEC device number acquisition instruction, receive CEC device information sent by the CEC devices according to the received CEC broadcast message, and obtain, according to the CEC device information, the number of the CEC devices connected to the main board to be tested.
In some embodiments of the present application, in order to facilitate a worker to check and maintain a test result of a CEC circuit of an HDMI, after obtaining a test result of whether the CEC circuit of the HDMI is normal according to a comparison result, the method may include: and uploading the test result of whether the CEC circuit of the HDMI interface is normal to the server.
The server may be a local server or a cloud server, which is not limited in this application.
It should be noted that, for simplicity of description, the foregoing method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts, as some steps may, in accordance with the present application, occur in other orders.
Fig. 5 is a schematic structural diagram of a CECcircuit testing apparatus 500 that provides an HDMI interface according to an embodiment of the present application, where the HDMI interface is disposed on a motherboard to be tested; when testing the CEC circuit of the HDMI interface, the main board to be tested is connected to a CEC device supporting a CEC function through the HDMI interface, and thetesting apparatus 500 of the HDMI interface may include: anacquisition unit 501 and atest unit 502.
An obtainingunit 501, configured to obtain, through the main board to be tested, the number of CEC devices connected to the main board to be tested;
thetesting unit 502 is configured to compare the number of CEC devices connected to the main board to be tested, which is obtained by the main board to be tested, with a preset number of CEC devices, and obtain a test result of whether a CEC circuit of the HDMI interface is normal according to the comparison result.
In some embodiments of the present application, the obtainingunit 501 is further specifically configured to: sending a CEC broadcast message to CEC equipment connected with the mainboard to be tested through the mainboard to be tested, and receiving CEC equipment information sent by the CEC equipment according to the received CEC broadcast message by the mainboard to be tested; and acquiring the quantity of CEC equipment connected with the mainboard to be tested, which is acquired by the mainboard to be tested according to the CEC equipment information.
In some embodiments of the present application, the obtainingunit 501 is further specifically configured to: and sending a CEC equipment number acquisition instruction to the mainboard to be tested, and sending the CEC broadcast message to the CEC equipment connected with the mainboard to be tested by the mainboard to be tested according to the received CEC equipment number acquisition instruction.
In some embodiments of the present application, the obtainingunit 501 is further specifically configured to: and automatically sending the CEC broadcast message to CEC equipment connected with the mainboard to be tested when the mainboard to be tested is powered on.
In some embodiments of the present application, thetest unit 502 is further specifically configured to: if the number of the CEC devices connected with the mainboard to be tested, which is acquired by the mainboard to be tested, is the same as the preset CEC device number, confirming that the CEC circuit of the HDMI interface is normal; and if the number of the CEC devices connected with the mainboard to be tested, which is acquired by the mainboard to be tested, is different from the preset CEC device number, determining that the CEC circuit of the HDMI interface is abnormal.
In some embodiments of the present application, thetest unit 502 is further specifically configured to: and acquiring the number of preset CEC devices.
In some embodiments of the present application, the HDMI interface testing apparatus further includes a transmitting unit, configured to upload a test result indicating whether a CEC circuit of the HDMI interface is normal to a server.
It should be noted that, for convenience and simplicity of description, the specific working process of the HDMIinterface testing apparatus 500 described above may refer to the corresponding process of the method described in fig. 1 to fig. 4, and is not described herein again.
Fig. 6 is a schematic diagram of a terminal according to an embodiment of the present application. Theterminal 6 may include: aprocessor 60, amemory 61 and acomputer program 62, such as a test program for an HDMI interface, stored in saidmemory 61 and executable on saidprocessor 60. Theprocessor 60 executes thecomputer program 62 to implement the steps in the above-described embodiments of the testing method for the HDMI interface, such as thesteps 301 to 302 shown in fig. 3. Alternatively, theprocessor 60, when executing thecomputer program 62, implements the functions of the modules/units in the above-mentioned device embodiments, such as the functions of theunits 501 to 502 shown in fig. 5.
The computer program may be divided into one or more modules/units, which are stored in thememory 61 and executed by theprocessor 60 to accomplish the present application. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution of the computer program in the terminal. For example, the computer program may be divided into an acquisition unit and a test unit, each unit having the following specific functions: the acquisition unit is used for acquiring the number of CEC devices connected with the mainboard to be tested through the mainboard to be tested; and the test unit is used for comparing the number of the CEC devices connected with the mainboard to be tested, which are acquired by the mainboard to be tested, with the preset number of the CEC devices, and obtaining a test result whether the CEC circuit of the HDMI interface is normal or not according to the comparison result.
The terminal can be a mobile terminal such as a smart television, or a computing device such as a smart phone, a desktop computer, a notebook, a palm computer and a cloud server. The terminal may include, but is not limited to, aprocessor 60, amemory 61. Those skilled in the art will appreciate that fig. 6 is only an example of a terminal and is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or different components, e.g., the terminal may also include input-output devices, network access devices, buses, etc.
TheProcessor 60 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital HDMI interface tester (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
Thememory 61 may be an internal storage unit of the terminal, such as a hard disk or a memory of the terminal. Thememory 61 may also be an external storage device of the terminal, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal. Further, thememory 61 may also include both an internal storage unit and an external storage device of the terminal. Thememory 61 is used for storing the computer program and other programs and data required by the terminal. Thememory 61 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/terminal and method may be implemented in other ways. For example, the above-described apparatus/terminal embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated modules/units, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by a computer program, which can be stored in a computer-readable storage medium and can realize the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.