First i will give an explanation of the class project:
I am trying to create a system that generates power and feeds it back into the power grid. To do so, one must match the frequency, voltage, and vary the phase so it lags at a constant amount. I am able to generate dc power, build an inverter to make a square wave at 60hz (used an arduino uno and FETs) and then using a low pass filter, make it a sine wave. My issue now is trying to create the phase lock loop. I will of course ramp down the voltage from the outlet so that it can be used with electronics (after reducing the current) but i need some way to compare both my sine wave and the ramped down sine wave from the outlet and adjust mine so its a constant phase lag. I am told the arduino has pll capabilities, but i can seem to find how to use it. Is there any way i can do this using an arduino uno?
Thanks in advance