Light source editable control method
By using multiple LED light source units and FPGA+MCU control, the problems of complex wiring and slow switching speed of the light source controller are solved, realizing rapid light source switching and efficient detection, thereby improving detection efficiency and production capacity.
Patent Information
- Application Number
- CN202511393156.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-27
- Publication Date
- 2025-11-04
AI Technical Summary
Existing light source controllers have complex wiring and slow switching speeds when taking multiple photos at the same location, resulting in low detection and algorithm efficiency and failing to improve production capacity.
It adopts multiple sets of LED light source units and is controlled by FPGA+MCU to meet the needs of multiple detection points for simultaneous illumination and individual illumination. The light source can be quickly switched by adjusting the control parameters, simplifying the wiring process.
It enables rapid detection of diverse test objects, reduces the difficulty and time of equipment line change testing, and improves detection efficiency and algorithm efficiency.
Smart Images

Figure CN120897302A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of light source control, and in particular to a light source editable control method. BACKGROUND
[0002] In the prior art, the light source on the market has the following problems: first, the light source controller is relatively single, and when multiple angles and multiple spectrums of a measured object need to be photographed multiple times, the wiring is complex and the control mode is complex; second, when taking pictures at different angles at the same position, the light source controller has slow switching speed and is prone to errors; and third, when the measured object is replaced, the light source controller needs to be reconnected to the control signal line due to changes in the control scheme, which is time-consuming and laborious; the above problems collectively result in reduced detection efficiency and algorithm efficiency of the light source, and the production capacity cannot be improved.
[0003] In view of the problems of low detection efficiency and algorithm efficiency of the existing light source in the related art, there is still a lack of a better technical solution. SUMMARY
[0004] Therefore, it is necessary to provide a light source editable control method to at least solve the problem of low detection efficiency and algorithm efficiency of the existing light source in the related art, which makes the production capacity unable to be improved.
[0005] The present application provides a light source editable control method, comprising the following steps: S1, configuring a light source use scenario of a detection camera, and setting multiple groups of LED light source units; S2, importing data parameters of the multiple groups of LED light source units into an FPGA+MCU, the multiple groups of LED light source units being composed of combination 1, combination 2,..., and combination m, to meet the light source use requirements of multiple detection points being irradiated at one time and the light source use requirements of multiple detection points being irradiated one by one; wherein the data parameters of each combination include light source brightness, light source lighting time, light source delay lighting time, number of channels of light source lighting, signal pulse width time of triggering the camera, signal delay output time of triggering the camera, and number of signal channels of triggering the camera; S3, selecting a single combination execution mode according to the light source use requirement of multiple detection points being irradiated at one time; S31, detecting whether there is an effective trigger signal outside; if there is no trigger signal, waiting for a trigger signal; if there is a trigger signal, proceeding to the next step; S32, executing all data parameters in the single combination, and proceeding to the next step; S33, checking whether all data parameters in the combination are executed; if the execution is completed, proceeding to the next step, otherwise, waiting for the execution of all data parameters in the combination to be completed; S34. Check again for a valid external trigger signal; if not, wait for a trigger signal; if a trigger signal is present, proceed to the next step. S35. Execute all data parameters in the next combination and proceed to the next step; S36. Check if all data parameters in this combination have been executed; if not, wait for all parameters in this combination to be executed; if executed, proceed to the next step. S37. Check whether all the combined data parameters to be executed have been executed; if not, return to step S34 to perform trigger signal detection again; if the execution has been completed, return to the initial state of step S31. S4. Select multiple combined cyclic execution modes based on the light source usage requirements of irradiating multiple detection points one by one. S41. Detect whether there is a valid trigger signal externally; if there is no trigger signal, wait for the trigger signal; if there is a trigger signal, proceed to the next step. S42. Execute all data parameters in combination 1 and proceed to the next step; S43. Check if all data parameters in this combination have been executed; if so, proceed to the next step; otherwise, wait for all data parameters in this combination to be executed. S44. Execute all data parameters in the next combination and proceed to the next step; S45. Check if all data parameters in this combination have been executed; if not, wait for all data parameters in this combination to be executed; if executed, proceed to the next step. S46. Check whether all data parameters in the required combination have been executed. If not, return to step S43 to perform trigger signal detection again. If the execution has been completed, return to the initial state in step S41.
[0006] The beneficial effects of this invention are: the design of this application is reasonable, and it solves the problems of diverse test objects, such as taking pictures from multiple angles simultaneously, sequentially, and continuously, and quickly switching the required light source parameters, so as to meet the diversity of test objects, adapt to more scenarios, and achieve the effect of rapid line change detection by simply adjusting the control parameters, which greatly saves time and manpower and reduces the difficulty of equipment line change detection. Attached Figure Description
[0007] Fig. 1 This is a flowchart of the single-step execution mode of the present invention; Fig. 2 This is a flowchart of the loop execution mode of the present invention. Detailed Implementation
[0008] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0009] It should be noted that when a component is said to be "mounted on" another component, it can be directly mounted on the other component or may be interspersed with a component. When a component is said to be "set on" another component, it can be directly set on the other component or may be interspersed with a component. When a component is said to be "fixed to" another component, it can be directly fixed to the other component or may be interspersed with a component.
[0010] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein in the specification of this invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. The term "or / and" as used herein includes any and all combinations of one or more of the associated listed items.
[0011] Please refer to Figs. 1-2 An example of an editable light source control method according to this application includes the following steps: S1. Configure the light source usage scenarios for the detection camera and set up multiple LED light source units; S2. Import the data parameters of multiple LED light source units into the FPGA+MCU. These multiple LED light source units are composed of combination 1, combination 2... combination m, to meet the light source usage requirements of multiple detection points irradiating at one time, and the light source usage requirements of multiple detection points irradiating one by one. Among them, the data parameters of each combination include light source brightness, light source emission time, light source delayed emission time, number of light source channels lit, signal pulse width time of triggering camera, signal delay output time of triggering camera, and number of signal channels of triggering camera. S3. Select a single combination execution mode based on the light source usage requirements for multiple detection points irradiated at one time; S31. Detect whether there is a valid trigger signal externally; if there is no trigger signal, wait for the trigger signal; if there is a trigger signal, proceed to the next step. S32. Execute all data parameters within a single combination and proceed to the next step; S33. Check if all data parameters in this combination have been executed; if they have been executed, proceed to the next step; otherwise, wait for all data parameters in this combination to be executed. S34. Check again for a valid external trigger signal; if not, wait for a trigger signal; if a trigger signal is present, proceed to the next step. S35. Execute all data parameters in the next combination and proceed to the next step; S36. Check if all data parameters in this combination have been executed; if not, wait for all parameters in this combination to be executed; if executed, proceed to the next step. S37. Check whether all the combined data parameters to be executed have been executed; if not, return to step S34 to perform trigger signal detection again; if the execution has been completed, return to the initial state of step S31. S4. Select multiple combined cyclic execution modes based on the light source usage requirements of irradiating multiple detection points one by one. S41. Detect whether there is a valid trigger signal externally; if there is no trigger signal, wait for the trigger signal; if there is a trigger signal, proceed to the next step. S42. Execute all data parameters in combination 1 and proceed to the next step; S43. Check if all data parameters in this combination have been executed; if so, proceed to the next step; otherwise, wait for all data parameters in this combination to be executed. S44. Execute all data parameters in the next combination and proceed to the next step; S45. Check if all data parameters in this combination have been executed; if not, wait for all data parameters in this combination to be executed; if executed, proceed to the next step. S46. Check whether all data parameters in the required combination have been executed. If not, return to step S43 to perform trigger signal detection again. If the execution has been completed, return to the initial state in step S41.
[0012] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the invention can be implemented in other specific forms without departing from its spirit or essential characteristics. Therefore, the embodiments should be considered in all respects as exemplary and non-limiting, and the scope of the invention is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be included within the present invention. No reference numerals in the claims should be construed as limiting the scope of the claims.
[0013] Furthermore, it should be understood that although this specification describes embodiments, not every embodiment contains only one independent technical solution. This narrative style is merely for clarity. Those skilled in the art should consider the specification as a whole, and the technical solutions in each embodiment can also be appropriately combined to form other embodiments that can be understood by those skilled in the art.
Claims
1. A method for editing and controlling a light source, characterized in that, Includes the following steps: S1. Configure the light source usage scenarios for the detection camera and set up multiple LED light source units; S2. Import the data parameters of multiple LED light source units into the FPGA+MCU. These multiple LED light source units are composed of combination 1, combination 2... combination m, to meet the light source usage requirements of multiple detection points irradiating at one time, and the light source usage requirements of multiple detection points irradiating one by one. Among them, the data parameters of each combination include light source brightness, light source emission time, light source delayed emission time, number of light source channels lit, signal pulse width time of triggering camera, signal delay output time of triggering camera, and number of signal channels of triggering camera. S3. Select a single combination execution mode based on the light source usage requirements for multiple detection points irradiated at one time; S31. Detect whether there is a valid trigger signal externally; if there is no trigger signal, wait for the trigger signal; if there is a trigger signal, proceed to the next step. S32. Execute all data parameters within a single combination and proceed to the next step; S33. Check if all data parameters in this combination have been executed; if they have been executed, proceed to the next step; otherwise, wait for all data parameters in this combination to be executed. S34. Check again for a valid external trigger signal; if not, wait for a trigger signal; if a trigger signal is present, proceed to the next step. S35. Execute all data parameters in the next combination and proceed to the next step; S36. Check if all data parameters in this combination have been executed; if not, wait for all parameters in this combination to be executed; if executed, proceed to the next step. S37. Check whether all the combined data parameters to be executed have been executed; if not, return to step S34 to perform trigger signal detection again; if the execution has been completed, return to the initial state of step S31. S4. Select multiple combined cyclic execution modes based on the light source usage requirements of irradiating multiple detection points one by one. S41. Detect whether there is a valid trigger signal externally; if there is no trigger signal, wait for the trigger signal; if there is a trigger signal, proceed to the next step. S42. Execute all data parameters in combination 1 and proceed to the next step; S43. Check if all data parameters in this combination have been executed; if so, proceed to the next step; otherwise, wait for all data parameters in this combination to be executed. S44. Execute all data parameters in the next combination and proceed to the next step; S45. Check if all data parameters in this combination have been executed; if not, wait for all data parameters in this combination to be executed; if executed, proceed to the next step. S46. Check whether all data parameters in the required combination have been executed. If not, return to step S43 to perform trigger signal detection again. If the execution has been completed, return to the initial state in step S41.