Hello,
I would like to know if it's possible to create a sinusoidal voltage using an arduino with the PWM pins ? And if possible, the required libraries.
Or if it's easier to use a Function generator to create a sinusoidal voltage.
It would be for a project where I would like to measure a frequency variation due to the inductance phenomenon.
Yes that’s it. Ok, I though that some librairary can help to create fake sine curve like the power inverter that convert direct current to alternating current.
Thanks for your answer. I will have a look how DAC work.
of course. dead easy. Send values from a lookup table as described here
This describes a characteristic tester that uses pwm to send a ramp voltage to the device under test. An RC filter converts the PWM to a DC value. You can easily change the sketch to output a sinewave instead.
Then you really need a DAC and an amplifier. Smoothing PWM won't work particularly well at such a high rate.
You say you want to create a sine wave, but you also say you want to measure frequency variation. If you create the wave, you know the frequency. Perhaps you mean measure phase variation due to inductive circuit?
If you explain what you are actually trying to do this will help avoid the xyproblem.