CN115793515B - FPGA-based phase synchronization method for MEMS galvanometer driving signals - Google Patents
FPGA-based phase synchronization method for MEMS galvanometer driving signals Download PDFInfo
- Publication number
- CN115793515B CN115793515B CN202211341060.0A CN202211341060A CN115793515B CN 115793515 B CN115793515 B CN 115793515B CN 202211341060 A CN202211341060 A CN 202211341060A CN 115793515 B CN115793515 B CN 115793515B
- Authority
- CN
- China
- Prior art keywords
- psw
- phase
- axis
- synchronization
- signal
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 14
- 238000013507 mapping Methods 0.000 claims description 7
- 230000000630 rising effect Effects 0.000 claims description 6
- 230000000737 periodic effect Effects 0.000 claims description 4
- 238000005070 sampling Methods 0.000 claims description 3
- 230000002411 adverse Effects 0.000 abstract description 3
- 230000000694 effects Effects 0.000 abstract description 3
- 238000010586 diagram Methods 0.000 description 3
- 230000003287 optical effect Effects 0.000 description 3
- 230000015572 biosynthetic process Effects 0.000 description 2
- 239000000696 magnetic material Substances 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- 230000001360 synchronised effect Effects 0.000 description 2
- 238000003786 synthesis reaction Methods 0.000 description 2
- 239000004020 conductor Substances 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
Landscapes
- Control Of Stepping Motors (AREA)
Abstract
The invention relates to a synchronization method of MEMS galvanometer driving signals based on FPGA, wherein signal waveforms are stored in FPGAROM to control PSW to read signals in ROM; control of PSW by the phase accumulator; the ROM generates driving signals to perform phase synchronization to obtain initial phase difference; when the value of the fast axis driving signal PSW is from PSW1-PSW max/2n to PSW1, the fast axis synchronization enable signal sync_ready_out1 is pulled high; when the slow axis driving signal PSW value is from PSW2-PSWmax/2 n to PSW2, the slow axis synchronization enable signal sync_ready_out2 is pulled high; and obtaining the superposition part of the two-axis signals, and returning to the initial phase at the same time to complete synchronization. The invention can obviously improve the abrupt change of the shape of the driving signal caused by direct phase synchronization, ensure the phase continuity of the driving signal during phase synchronization and reduce the adverse effect of the phase synchronization on the MEMS galvanometer.
Description
Technical field:
The invention relates to the field of micro-galvanometer control, in particular to a phase synchronization method of MEMS galvanometer driving signals based on FPGA.
The background technology is as follows:
The development of the MEMS (Micro-Electro-MECHANICAL SYSTEM, micro-electromechanical systems) industry has a significant impact on the fields of information, medical treatment, space technology, etc., and in this context, many MEMS products have been developed, in which MEMS galvanometers are drivable micromirrors fabricated based on MEMS technology, and the mirror diameter is usually only a few millimeters. Compared with the traditional optical scanning mirror, the optical scanning mirror has the advantages of light weight, small volume, easy mass production and lower production cost. The method has more outstanding performance in the aspects of optical performance, mechanical performance and power consumption, and has wide application prospect in the fields of high-definition projection, laser radar, three-dimensional scanning and the like.
According to the driving principle, the MEMS galvanometer can be divided into electrostatic driving, electromagnetic driving, piezoelectric driving and thermoelectric driving, and at present, two types of electrostatic driving and electromagnetic driving are common. The electrostatic driving is to utilize electrostatic attractive force generated between charged conductors, the force acts on the mirror surface, and torsion movement is performed under the action of moment; the electromagnetic drive is to drive the mirror surface to twist by utilizing the Lorentz force, and in the structure, the electromagnetic drive type MEMS vibrating mirror is added with a magnetic material, and electromagnetic force is generated by the interaction of current and a magnetic field generated by the magnetic material so as to enable the mirror surface to twist. Regardless of the manner of driving, a certain driving signal is required to be generated from the outside to obtain the torsion force required for vibration. From the operational mode, MEMS mirrors can be divided into two categories, a resonant state and a non-resonant state. The working frequency of the non-resonant working mode can be freely adjusted, and the real-time adjustment can be carried out from zero to the range of the inherent resonant frequency of the micro-mirror structure; the resonant mode requires that the MEMS galvanometer needs to work under the resonant frequency point, and the scanning angle of the scanning frequency deviating from the resonant frequency point can be greatly reduced, and even the MEMS galvanometer cannot work normally.
For a two-dimensional MEMS galvanometer, the scanning can be performed in two directions perpendicular to each other, namely, the X-axis (fast axis) direction and the Y-axis (slow axis) direction. Under the condition that both shafts adopt resonant mode operation modes, the fast shaft and the slow shaft of the MEMS galvanometer operate in respective frequency ranges. When the two shafts vibrate simultaneously, the vibration track is in a Lissajous figure, and the shape of the track depends on the frequency ratio, the amplitude ratio and the initial phase difference of the two-shaft vibration. The three factors are determined by driving signals driving the micro-mirrors to vibrate, wherein the frequency and the amplitude can be intuitively adjusted, when the driving signals of the two shafts set the initial phase difference, the phase synchronization is needed, usually, the initial phases of the driving signals of the two shafts are respectively preset, and then the phases of the two signals are simultaneously reset to the initial phases at a moment to obtain a specific initial phase difference. Because the moment of selecting the phase synchronization has randomness, the driving signal can be jumped, thereby influencing the normal working state of the vibrating mirror and even damaging the structure of the vibrating mirror.
The invention comprises the following steps:
aiming at the defects of the prior art, the invention aims to provide a phase synchronization method of MEMS (micro-electromechanical system) vibrating mirror driving signals based on an FPGA (field programmable gate array), which utilizes the high-speed processing characteristic of the FPGA when the initial phase difference of the two-axis driving signals is set, and enables the two-axis driving signals of the MEMS vibrating mirror to return to the initial phase simultaneously when the fast-axis driving signal and the slow-axis driving signal of the MEMS vibrating mirror are about to reach the initial phase, so that the two-axis driving signals of the MEMS vibrating mirror are synchronized under the condition that the phases are relatively continuous, and the specific initial phase difference is obtained.
In order to achieve the above purpose, the present invention adopts the following technical scheme:
The MEMS galvanometer driving signal synchronization method based on the FPGA is characterized by comprising the following steps of:
a. The method comprises the steps that a DDS signal generator is realized by adopting an FPGA to generate a driving signal, periodic signal waveforms are stored in a ROM of the FPGA, the depth of the ROM is the sampling point number of one period, a linear mapping relation exists between ROM addresses and PSW, and signals in the ROM can be circularly read out by controlling the PSW;
b. The PSW is controlled by a phase accumulator, namely, at each rising edge of a clock, the PSW value is added with a frequency control word FSW (Frequency Setting Word), when the PSW value is larger than PSWmax, the PSW value returns to PSW-PSWmax, and the PSW value is mapped to a ROM address in such a cycle, so that a signal with a required frequency can be read out, and the frequency f out of an output signal can be obtained according to the DDS principle
Wherein f clk is the working clock frequency of DDS, FSW is a frequency control word, PSW max is a maximum phase control word;
controlling the two-axis vibration of the MEMS vibrating mirror requires two ROMs in the FPGA to generate driving signals, and the two ROMs are controlled by mutually independent phase accumulators.
C. The method comprises the steps of carrying out phase synchronization on two-axis driving signals of an MEMS vibrating mirror to obtain a specific initial phase difference, obtaining initial phases of the two-axis driving signals according to the initial phase difference of the two-axis driving signals, obtaining initial phase control words of the two-axis driving signals according to a mapping relation, wherein the initial phase control words of fast-axis driving signals are represented by PSW1, and the initial phase control words of slow-axis driving signals are represented by PSW 2;
d. Setting a window period of phase synchronization to be PSW max/2n, n=0, 1,2,3, …;
e. when the PSW value of the fast axis drive signal is at PSW1-PSW max/2n to PSW1, the fast axis synchronization enable signal sync_ready_out1 is pulled high; similarly, when the PSW value of the slow axis drive signal is from PSW2-PSWmax/2 n to PSW2, the slow axis synchronization enable signal sync_ready_out2 is pulled high;
f. The overlapping portion of the two-axis synchronization enable signal is obtained,
sync_ready=sync_ready_out1&sync_ready_out2 (2)
The sync_ready is a phase synchronization enable signal, the sync_ready is valid at a high level, which indicates that the phase synchronization operation can be performed, and the PSW value of the fast axis is set to PSW1 and the PSW value of the slow axis is set to PSW2 at the rising edge of the sync_ready signal, so that the phases of the driving signals of the fast axis and the slow axis return to the initial phase at the same time, and the phase synchronization operation is completed.
The technical scheme is as follows:
the driving signals are voltage signals or current signals for driving the MEMS galvanometer to vibrate, and comprise a fast axis driving signal for driving the MEMS galvanometer to vibrate in a fast axis mode and a slow axis driving signal for driving the MEMS galvanometer to vibrate in a slow axis mode, wherein the two axis driving signals are periodic signals, and the phases of the two axis driving signals are periodically circulated between 0 and 360 degrees.
The phase synchronization refers to that a fast axis driving signal and a slow axis driving signal of the MEMS galvanometer return to an initial phase at the same time, so as to obtain a specific initial phase difference, and the initial phase can be set to any value between 0 and 360 degrees.
In the present invention, the phase of the signal at any time may be represented by PSW (PHASE SETTING Word, phase control Word), where the phase and the phase control Word have a linear mapping relationship, and the phase corresponds to the maximum value PSW max of the phase control Word when the phase is 360 degrees. The window period of phase synchronization of the driving signal is PSW max/2n (n=0, 1,2,3 …), and the phase value at the time of phase synchronization is closer to the initial phase when the value of n is larger.
The initial phase of the fast axis driving signal is set as PSW1, the initial phase of the slow axis driving signal is set as PSW2, and in order to ensure the continuity of the signals, the phase synchronization should be performed when the phase is about to reach the initial phase, and the phase value during the synchronization should be as close to the initial phase as possible. When the phase value of the fast axis drive signal is between PSW1-PSW max/2n and PSW1, the fast axis enters a synchronization ready state. Similarly, when the phase value of the slow axis drive signal is between PSW2-PSW max/2n and PSW2, the slow axis enters a synchronization ready state. And when the two shafts are in a synchronous preparation state at the same time, performing phase synchronization operation.
When n is equal to 0, the window period of phase synchronization of the drive signal is any period of the whole signal period, which is equivalent to directly performing the phase synchronization operation. When the value of n is larger, the phase value at the time of phase synchronization is closer to the initial phase, the influence on signal continuity is smaller, but the time to wait for the completion of the phase synchronization operation is longer.
The invention has the advantages that: the invention can obviously improve the abrupt change of the shape of the driving signal caused by direct phase synchronization, ensure the phase continuity of the driving signal during phase synchronization and reduce the adverse effect on the MEMS galvanometer during phase synchronization.
Description of the drawings:
FIG. 1 is a schematic diagram of a phase accumulator according to an embodiment of the present invention;
FIG. 2 is a flow chart of a phase synchronization method according to an embodiment of the invention;
FIG. 3 is a timing diagram of a phase control word and a synchronization enable signal according to an embodiment of the present invention;
the specific embodiment is as follows:
The embodiments of the present invention are described in detail below.
The invention relates to a synchronization method of MEMS vibrating mirror driving signals based on FPGA, in the embodiment, the driving signals are generated by adopting FPGA to realize DDS (DIRECT DIGITAL SYNTHESIS, direct frequency synthesis) signal generator. Firstly, storing periodic signal waveforms into a ROM of an FPGA, wherein the depth of the ROM is the number of sampling points of one period, and the ROM address and the PSW have linear mapping relation, so that signals in the ROM can be circularly read out by controlling the PSW.
As shown in fig. 1, the control of the PSW is achieved by a phase accumulator, i.e. at each clock rising edge, the PSW value is incremented by one FSW (Frequency Setting Word, frequency control word), and when the PSW value is greater than PSW max, the PSW value is returned to PSW-PSW max, and so on. The PSW value is mapped to the ROM address, so that the signal with the required frequency can be read out, and the frequency f out of the output signal can be obtained according to the DDS principle to be
Where f clk is the operating clock frequency of the DDS, FSW is the frequency control word, and PSW max is the maximum phase control word.
Controlling the two-axis vibration of the MEMS galvanometer requires the two ROMs to generate driving signals, and the two ROMs are controlled by mutually independent phase accumulators.
The two-axis driving signals of the MEMS galvanometer are subjected to phase synchronization to obtain a specific initial phase difference, and the steps are shown in figure 2.
First, the initial phase of the two-axis driving signal is obtained from the initial phase difference of the two-axis driving signal, and the initial phase control word of the two-axis driving signal is obtained according to the mapping relation. The primary phase control word of the fast axis drive signal is denoted by PSW1 and the primary phase control word of the slow axis drive signal is denoted by PSW 2.
Further, the window period of the phase synchronization is set to PSW max/2n (n=0, 1,2,3 …), wherein the larger the value of n, the smaller the window period, which means that the phase value at the time of the phase synchronization is closer to the initial phase, and thus the influence on the signal continuity is smaller. The adverse effect is that the window period overlapping of the two-axis phase synchronization becomes smaller, and the waiting time of the phase synchronization becomes longer. When the synchronization time is not required, a larger n value can be set initially; when the signal is sensitive to the synchronization time, the initial value of n can be determined according to two factors of the phase synchronization time of the signal and the continuity of the signal.
Further, when the PSW value of the fast axis drive signal is in PSW1-PSW max/2n to PSW1, i.e., the Δt1 period in FIG. 3, the fast axis synchronization enable signal sync_ready_out1 is pulled high; similarly, when the PSW value of the slow axis driving signal is in PSW2-PSW max/2n to PSW2, i.e., the period Deltat 2 in FIG. 3, the slow axis synchronization enable signal sync_ready_out2 is pulled high.
Further, a coincident portion of the two-axis synchronization enable signal, that is, Δt time period in fig. 3, is obtained.
sync_ready=sync_ready_out1&sync_ready_out2 (2)
Where sync_ready is the phase synchronization enable signal, sync_ready is active high, indicating that phase synchronization operations can be performed. On the rising edge of the sync_ready signal, the PSW value of the fast axis is set to PSW1 and the PSW value of the slow axis is set to PSW2. Thus, the phases of the driving signals of the fast axis and the slow axis return to the initial phase at the same time, and the phase synchronization operation is completed.
The flowcharts and diagrams in the figures illustrate the FPGA algorithm flow and functional architecture of embodiments of the present invention, where each block of the flowchart may represent a module, segment, or portion of instructions.
Claims (1)
1. The MEMS galvanometer driving signal synchronization method based on the FPGA is characterized by comprising the following steps of:
a. The method comprises the steps that a DDS signal generator is realized by adopting an FPGA to generate a driving signal, periodic signal waveforms are stored in a ROM of the FPGA, the depth of the ROM is the sampling point number of one period, a linear mapping relation exists between ROM addresses and PSW, and signals in the ROM can be circularly read out by controlling the PSW;
b. The PSW is controlled by a phase accumulator, namely, at each clock rising edge, the PSW value is added with a frequency control word FSW, when the PSW value is larger than PSWmax, the PSW value returns to PSW-PSWmax, and the PSW value is mapped to a ROM address in such a cycle, so that a signal with a required frequency can be read out, and the frequency f out of an output signal can be obtained according to the DDS principle
Wherein f clk is the working clock frequency of DDS, FSW is a frequency control word, PSW max is a maximum phase control word;
controlling the two-axis vibration of the MEMS vibrating mirror requires two ROMs in the FPGA to generate driving signals, wherein the two ROMs are controlled by mutually independent phase accumulators;
c. The method comprises the steps of carrying out phase synchronization on two-axis driving signals of an MEMS vibrating mirror to obtain a specific initial phase difference, obtaining initial phases of the two-axis driving signals according to the initial phase difference of the two-axis driving signals, obtaining initial phase control words of the two-axis driving signals according to a mapping relation, wherein the initial phase control words of fast-axis driving signals are represented by PSW1, and the initial phase control words of slow-axis driving signals are represented by PSW 2;
d. Setting a window period of phase synchronization to be PSW max/2n, n=0, 1,2,3, …;
e. when the PSW value of the fast axis drive signal is at PSW1-PSW max/2n to PSW1, the fast axis synchronization enable signal sync_ready_out1 is pulled high; similarly, when the PSW value of the slow axis drive signal is from PSW2-PSWmax/2 n to PSW2, the slow axis synchronization enable signal sync_ready_out2 is pulled high;
f. The overlapping portion of the two-axis synchronization enable signal is obtained,
sync_ready=sync_ready_out1&sync_ready_out2 (2)
The sync_ready is a phase synchronization enable signal, the sync_ready is valid at a high level, which indicates that the phase synchronization operation can be performed, and the PSW value of the fast axis is set to PSW1 and the PSW value of the slow axis is set to PSW2 at the rising edge of the sync_ready signal, so that the phases of the driving signals of the fast axis and the slow axis return to the initial phase at the same time, and the phase synchronization operation is completed.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211341060.0A CN115793515B (en) | 2022-10-30 | 2022-10-30 | FPGA-based phase synchronization method for MEMS galvanometer driving signals |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211341060.0A CN115793515B (en) | 2022-10-30 | 2022-10-30 | FPGA-based phase synchronization method for MEMS galvanometer driving signals |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115793515A CN115793515A (en) | 2023-03-14 |
CN115793515B true CN115793515B (en) | 2024-09-27 |
Family
ID=85434410
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211341060.0A Active CN115793515B (en) | 2022-10-30 | 2022-10-30 | FPGA-based phase synchronization method for MEMS galvanometer driving signals |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115793515B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109788264A (en) * | 2018-12-20 | 2019-05-21 | 歌尔股份有限公司 | Frame synchronizing signal generation method and projection device |
CN110794572A (en) * | 2019-10-15 | 2020-02-14 | 歌尔股份有限公司 | Collection method, driving method and system of feedback signal of MEMS galvanometer |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9784601B2 (en) * | 2014-11-20 | 2017-10-10 | Computational Systems, Inc. | Apparatus and method for signal synchronization |
CN111277265A (en) * | 2020-04-03 | 2020-06-12 | 四川鸿创电子科技有限公司 | Multi-channel DA signal synchronization device and method based on FPGA |
CN114050597B (en) * | 2021-11-19 | 2024-05-14 | 山东大学 | Cooperative active heat control system and method for multiple grid-connected inverters |
-
2022
- 2022-10-30 CN CN202211341060.0A patent/CN115793515B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109788264A (en) * | 2018-12-20 | 2019-05-21 | 歌尔股份有限公司 | Frame synchronizing signal generation method and projection device |
CN110794572A (en) * | 2019-10-15 | 2020-02-14 | 歌尔股份有限公司 | Collection method, driving method and system of feedback signal of MEMS galvanometer |
Also Published As
Publication number | Publication date |
---|---|
CN115793515A (en) | 2023-03-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8395633B2 (en) | Scanning type image display apparatus | |
US10935640B2 (en) | Multiplexed LIDAR transceiver | |
Chong et al. | Development of a vector display system based on a surface-micromachined micromirror | |
JP2016001275A (en) | Optical scanner | |
US20080007811A1 (en) | Scanning apparatus and method | |
CN110749894A (en) | Laser radar system and method for increasing scanning line number of laser radar system | |
US8270057B2 (en) | Oscillator device, optical deflecting device and method of controlling the same | |
JPH10197819A (en) | Optical scanner | |
Ruotsalainen et al. | Resonating AlN-thin film MEMS mirror with digital control | |
CN115793515B (en) | FPGA-based phase synchronization method for MEMS galvanometer driving signals | |
US10642025B2 (en) | Method for controlling position of a linear MEMS mirror with variable resolution and/or light intensity | |
US10209510B2 (en) | Compact modular scanners for scanning laser devices | |
JPS61251362A (en) | Image scan clock generator for optical scanner | |
Roscher et al. | Low-cost projection device with a 2D resonant microscanning mirror | |
US9759909B1 (en) | Scanning platforms for scanning laser devices | |
EP3136153B1 (en) | Actuator controlling device, drive system, video device, image projection device, and actuator controlling method | |
US20230305116A1 (en) | Optical scanning device, driving method of optical scanning device, and distance measurement device | |
JP2010008614A (en) | Projection type display device and display method used for the same | |
JP2023151550A (en) | Optical scanner, driving method of optical scanner and image drawing system | |
Kuijpers et al. | Towards embedded control for resonant scanning MEMS micromirror | |
CN108922461A (en) | Micro- laser-projector, the signal processing method based on micro- laser-projector and equipment | |
CN113703003B (en) | Laser scanning control method and device and storage medium | |
WO2015109273A4 (en) | Coupling schemes for gimbaled scanning mirror arrays | |
EP4080268A1 (en) | Piezoelectric based mems device with time sharing actuation and sensing circuitry | |
US20220411255A1 (en) | Driving circuits for a piezoelectric microelectromechanical system mirror |
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 |