A kind of method and system thereof that tests the upper bluetooth module of embedded PCB A
Technical field
The present invention relates to a kind of method and system thereof that tests the upper bluetooth module of embedded PCB A.
Background technology
PCBA: be the abbreviation of English Printed Circuit Board+Assembly, namely the PCB hollow plate passes through the SMT(surface mounting technology) go up part, pass through again the whole processing procedure of DIP plug-in unit.PCBA in the present invention is exactly the circuit board that has not also had the complete machine assembling behind the paster.
Embedded device enters in the middle of people's the life more and more, and is industrial such as industrial computer, and touch-screen etc. are commercial such as thin client, display screen etc., common embedded device just has MP3, MP4, wearable electronic in the life in addition, set-top box, mobile phone, dull and stereotyped etc.Only dull and stereotyped one, at present according to industry development trend and analysis, the shipment amount of panel computer in 2013 is near 200,000,000.Under so large-scale radix background, production efficiency has just become to restrict the short slab of embedded production capacity.Particularly present embedded device will be realized increasing function, is provided with increasing functional module at PCBA, such as bluetooth module etc.In order to enhance productivity, guarantee production unit in technologic quality, so we need to propose a kind of method that the upper bluetooth module of embedded PCB A is tested fast.Can test out fast the quality of bluetooth module, guarantee the correct welding of bluetooth module among the PCBA and correct parameter testing, guarantee the reliability of SMT technique.
A kind of " proving installation of mobile TV PCBA and method of testing " disclosed in the prior art, see that publication number is: CN101360257, open day be: 20090204 Chinese patent, describe the proving installation of a kind of PCBA of mobile TV, comprised DVD player, AV signal distributor, modulation, frequency mixer and test fixture.Used DVD player, AV signal distributor, modulation, frequency mixer and test fixture to come mobile TV PCBA is tested in the documents, because the television antenna feedback point on the PCBA plate that the upper bluetooth module of embedded PCB A does not have to mention in the documents, can't received RF signal, so this documents can't be tested the bluetooth module on the embedded PCB A.
Disclose a kind of " bluetooth earphone PCBA batch testing method and system " in the prior art, seen that publication number is: CN102243281A open day was: 20111116 Chinese patent, the PCBA batch testing method of bluetooth earphone has been described.Technical characterictic in the documents carries out batch testing to the PCBA of bluetooth earphone and shows test results at display for using with the computer of test procedure, need to use test computer and display, when having a plurality of testers to test a large amount of PCBA, prepare a plurality of test computers and display.Computer and display are bought and used the cost that has increased on the one hand test, have also taken on the other hand the place, and be also inconvenient when computer and display move simultaneously, do not seem during test very convenient that limitation is arranged.
" a kind of PCBA device for testing functions and method of testing thereof " disclosed in the prior art, see that publication number is: CN 102854452A, open day be: 20130102 Chinese patent, a kind of PCBA device for testing functions has been described, digital multimeter is arranged, and a changeover mechanism and a Function detection mechanism form.Disclosed technical characterictic can be tested multiple current, built-in relay, external relay, switch key and keyboard in this documents, and then can't test for the quality, particularly bluetooth module internal work of the bluetooth module on the embedded PCB A are bad.
Disclose " a kind of PCBA automated testing method and system of display device " in the prior art, seen that publication number is: CN103002317A open day was: 20130327 Chinese patent, a kind of PCBA automated testing method of display device has been described.Documents need to be used industrial computer and display device equally to the test of PCBA, and certain limitation is arranged.
A kind of " the open PCBA functional test of modularization platform, test macro and method " disclosed in the prior art, see that publication number is: CN102590730A, open day be: 20120718 Chinese patent, the open PCBA functional test of a kind of modularization platform has been described.In this documents the monitor station that comprises needle-bar has been used in the test of PCBA, also be useful on the testing needle corresponding with the PCBA test point on the monitor station of needle-bar, need to when designing, PCB reserve test point in the time of then will detecting PCBA, also to make needle-bar simultaneously, greatly increase the time of research and development to testing process, also strengthened the testing cost of enterprise simultaneously.During the simultaneously change of the position of components on the PCBA of different batches, in case the test point on the PCB is blocked when needing to change the position, then needle-bar will be revised accordingly, and is very loaded down with trivial details.
In sum, the problem such as prior art exists testing cost high to the test of the upper bluetooth module of PCBA, and testing process is loaded down with trivial details has limited the production efficiency of telecommunications product, can not meet the demand of technical development.
Summary of the invention
Technical matters to be solved by this invention is to provide a kind of method and system of testing the upper bluetooth module of embedded PCB A, whether normally can test out quickly and accurately the upper bluetooth module SMT of PCBA.
For achieving the above object, the invention provides a kind of method of testing the upper bluetooth module of embedded PCB A, comprise the steps:
Plug type storer in the upper memory interface of scanning PCBA;
Loading is pre-stored in the test code of plug type storer, the test bluetooth module;
If test result is normal, then the prompt facility on the driving PCB A sends regular prompt information, if test result is unusual, then the prompt facility on the driving PCB A sends abnormal prompt information.
Further, described plug type storer is the SD card.
Further, load first linux kernel and the least root file system that is pre-stored in the plug type storer before loading the test code be pre-stored in the plug type storer.
Further, the concrete steps of test bluetooth module are:
To bluetooth module sending module type information reading order; Wait for that bluetooth module returns the module type information, if bluetooth module does not return the module type information in the time-out time of setting, then test result is unusual, finishes test;
If bluetooth module returns the module type information in the time-out time of setting, then read and to plug the driving that prestores in the storer and load corresponding the driving according to the module type information, the network interface of configuration bluetooth module, Sampling network interface starting state, if network interface starts unusual, then test result is unusual, finishes test;
Use bluetooth module and the bluetooth transmitter that presets to match if network interface starts normal, detect the pairing result, if can not match then test result is unusual, finish test, otherwise test result is normal, finish test.
Further, described prompt facility is the LED lamp, and described regular prompt information is LED lamp Chang Liang, and abnormal prompt information is the flicker of LED lamp.
For realizing goal of the invention, the present invention also provides a kind of embedded PCB A fast testing system of upper bluetooth module, comprise for pointing out test result whether normally prompt facility, bluetooth module to be measured, the plug type storer that is used for connecting the memory interface of plug type storer and stores test code, it is characterized in that: also comprise with lower module:
Memory Controller is for the plug type storer of swept memory interface;
The bluetooth module controller is used for the communication control module;
The Auto-matching module is used for loading the test code that is pre-stored in the plug type storer;
Automatic test module is used for the test bluetooth module;
Wherein, when test result was normal, automatic test module drove described prompt facility and sends regular prompt information; When test result was unusual, automatic test module drove described prompt facility and sends abnormal prompt information.
Further, described fast testing system also comprises:
Embedded kernel loads module: be used for before the Auto-matching module loading is pre-stored in the test code of plug type storer, loading first linux kernel and the least root file system that is pre-stored in the plug type storer.
Further, described automatic test module comprises with lower unit:
Read module model unit is used for to bluetooth module sending module type information reading order; Wait for that bluetooth module returns the module type information, if bluetooth module does not return the module type information in the time-out time of setting, then test result is unusual, finishes test;
The module drive loading unit, be used for when read module model unit successfully reads type information, read and to plug the driving that prestores in the storer and load corresponding the driving according to the module type information, the network interface of configuration bluetooth module, Sampling network interface starting state, if network interface starts unusual, then test result is unusual, finishes test;
And module communication unit, be used for detecting the network interface starting state when normal when the module drive loading unit, use bluetooth module that external bluetooth transmitter is scanned, if can not return normal Bluetooth transmission machine information then test result is unusual, finish test, otherwise test result is normal, finishes test.
The present invention has following advantage: PCBA and powers on and just begin to load in the plug type storer test procedure and test, and does not have other unnecessary steps, demonstrates intuitively onboard test result when test finishes, and has improved testing efficiency.If adopt especially pipelining, prepare a plurality of plug type storeies, a tester inserts the plug-in storer on the PCBA plate specially and powers on to the PCBA plate simultaneously, another tester checks specially test result and sorts the PCBA plate of different test results and the plug type storer is taken out, in the time of just can having avoided a people to test in stand-by period of PCBA test process, can test fast the correctness of the upper bluetooth module SMT of Embedded PCBA, test and production efficiency have been improved greatly, for the normal operation of follow-up complete machine provides hardware guarantee, obtained good effect.
Description of drawings
Fig. 1 is the upper bluetooth module test system structural representation of the described PCBA of the specific embodiment of the invention;
Fig. 2 is the upper bluetooth module test method process flow diagram of the described PCBA of the specific embodiment of the invention.
Embodiment
By describing technology contents of the present invention, structural attitude in detail, being realized purpose and effect, below in conjunction with embodiment and cooperate accompanying drawing to give in detail explanation.
Bluetooth transmitter: powerful Bluetooth signal transmitter, generally be used for utilizing in public bluetooth advertisement etc. business, can be regarded as one with the mobile phone of bluetooth, but its emissive power is very large, area coverage is large.Bluetooth module in this case on the PCBA scans bluetooth transmitter, guarantees that the bluetooth module paster on the PCBA is normal.
As shown in Figure 1, the present embodiment provides a kind of embedded PCB A fast testing system of upper bluetooth module, comprises bluetooth module 1, plug type storer, Memory Controller, bluetooth module controller, Auto-matching module 4, automatic test module 5, reminding module.Wherein Memory Controller is SD controller 3, and the GPS module controller is UART controller 7, and the plug type storer can be SD card 2, and reminding module can be LED lamp 6.Native system also is useful on the bluetooth transmitter 8 for bluetooth module scanning outward.
Flow process as shown in Figure 2, below in conjunction with embodiment method of testing of the present invention is described in detail, in this embodiment, embedded PCB A is the dull and stereotyped PCBA of Android, the dull and stereotyped PCBA of existing Android is upper with USB control unit interface or SD control unit interface, the storer of plug type can be USB flash disk or SD card, these memory sizes are little, cost is mobile everywhere after hanging down and also can plugging, set-up procedure is simple, just can prepare a plurality of storeies that can be used for testing as long as copy to paste, conveniently carry out test in batches.At first the plug type storer in the memory interface scans on step S101 need to be to PCBA, for next step loading ready.
Reload the test code that is pre-stored in the plug type storer, the test bluetooth module.Test code is existed in the plug type storer, do not need during test the PCBA plate is made amendment, accelerated testing process.Owing to the plug type storer scanned, then can directly load test code.Test code can be write the content measurement of bluetooth module as required: if content measurement is simple, as only being that the test bluetooth module exists, that the hardware testing code that can directly write bottom is tested the progress that can accelerate to test.If content measurement relative complex, as need to all carrying out to the various aspects of bluetooth module the test of integrality, then can use embedded kernel (such as WINCE, Linux etc.) and the least root file system, because embedded kernel and least root file system can provide for test process the environment of an operating system, comprised the environment that the relevant network environment of bluetooth module and subsequent drive load.Reload test code on the basis of embedded kernel and test, also can reduce the workload that test code is write.The present embodiment has been selected linux kernel, then linux kernel and least root file system to be deposited in the plug type storer in advance, then in step S102, load first linux kernel and the least root file system be pre-stored in the plug type storer, after reload test code and enter testing process.
Whether the quality upper bluetooth module SMT(Surface Mount of test PCBA) will be tested bluetooth module can normal communication, can show that then bluetooth module SMT is normal by normal communication, can not normal communication then bluetooth module SMT is unusual.Use bluetooth module to carry out communication test and will drive first bluetooth module, drive the model that bluetooth module will be known first bluetooth module, according to this principle, then can carry out in accordance with the following steps the test of bluetooth module:
To bluetooth module sending module type information reading order.Can use different controllers to operate on it for different bluetooth modules, in the present embodiment, bluetooth module is adopted the universal asynchronous transmission and reception apparatus of UART() controller operates it, namely utilizes the UART controller to send to bluetooth module in step S103 and read the model message command.Then wait in step S104 that bluetooth module returns the module type information, if bluetooth module does not return the module type information in the time-out time of setting, then enter step S111 test result unusual, finish test;
If bluetooth module returns the module type information in the time-out time of setting, then read at step S105 and can plug the driving that prestores in the storer and load corresponding the driving according to the module type information, the network interface of configuration bluetooth module, Sampling network interface starting state judges at step S106 whether network interface starts normal.Because test procedure carries out under the Linux environment, the Linux environment provides the network interface configurator, and the network interface that then bluetooth module is driven the bluetooth module of registering in linux kernel is configured, and Sampling network interface starting state.If the network interface starting state is unusual, then enter step S111 test result unusual, finish test;
If the network interface starting state is normally then enter step S107 and use bluetooth module and bluetooth transmitter to match, then detect whether successful matching at step S108, if match unsuccessfully, then enter step S111 test result unusual, end is tested; Otherwise it is normal to enter step S109 test result, finishes test.
After above test code executed, if test result is normal, then the prompt facility on the driving PCB A sent regular prompt information, if test result is unusual, then the prompt facility on the driving PCB A sends abnormal prompt information.The dull and stereotyped PCBA of Android often has can allow the user directly get access to test result whether normal prompt facility has LED, loudspeaker or Vib., regular prompt information can be the work of driving arrangement continuation, such as LED Chang Liang, loudspeaker ring always, Vib. vibrates always, and then step S110 is LED Chang Liang on the driving PCB A after step S109 test result is normal; Abnormal prompt information can be the driving arrangement intermittent work, and such as LED flicker, loudspeaker ring discontinuously, and Vib. vibrates discontinuously, is LED Chang Liang on the driving PCB A at the unusual rear step S112 of step S111 test result then.Like this when test finishes on the PCBA plate response of the difference of equipment expressed test result simple and clearly.
When needing simultaneously a large amount of embedded PCB A tested, can use a plurality of SD cards that PCBA is tested, namely can rapidly normal and unusual PCBA plate be separated, just can be ready for ensuing production, have Practical significance.The mobility of the plug type storeies such as SD card, so that can be in any place for the test of the upper bluetooth module of PCBA, simultaneously because SD card price is cheap, the SD card is long-pending little also only need to take quite little space, can greatly reduce the testing cost of enterprise.
In other embodiments, the corresponding module in the present embodiment and step can be applied to mobile phone, MP4, other embedded PCBs such as touch-screen A.
The above only is embodiments of the invention; be not so limit claim of the present invention; every equivalent structure or equivalent flow process conversion that utilizes instructions of the present invention and accompanying drawing content to do; or directly or indirectly be used in other relevant technical fields, all in like manner be included in the scope of patent protection of the present invention.