Solution
The FPGA Code can be as shown in the Snippet below:
![](/servlet/rtaImage?eid=ka03q000001289K&feoid=00N0Z00000HEWRt&refid=0EM0Z000000u5Sa)
Note: This image is a LabVIEW snippet, which includes LabVIEW code that you can reuse in your project. To use a snippet, right-click the image, save it to your computer, and drag the file onto your LabVIEW diagram.