From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Example Code

Resolver Signal Simulation and Measurement in LabVIEW FPGA

Code and Documents

Attachment

Overview


Examples of how to both simulate and demodulate a resolver signal using LabVIEW FPGA on CompactRIO and PXI.

This LabVIEW example has examples of resolver simulation and measurement on both Windows and FPGA targets.

Resolvers produce a sine / cosine signal that is modulated with a carrier frequency. Decoding the sine and cosine signal is done using the arc-tangent function available in LabVIEW FPGA (which uses a cordic algorithm).

Simulation in the example produces an excitation signal (carrier frequency) and sine / cosine signals based on a input position in degrees. Fixed point math is used.

In the FPGA examples, 1 cycle of the carrier frequency sine wave is generated from the host VI and stored in a LUT (Look Up Table) in FPGA. The sine and cosine values are multiplied by the LUT values to create the appropriate modulated output signal. 

 

 
 

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Contributors