AC converter to DC

gpfacu
Posts: 1
Joined: Sun Mar 22, 2026 2:28 pm

AC converter to DC

Postby gpfacu » Sun Mar 22, 2026 2:35 pm

Hi,

I´m trying to generate an AC signal with my ESP-32 and I´m having some inconviniences. I´m going to be sending squared pulses from 0V to 3.3V, the period is going to depend on what I need at the moment, but generally it´ll be something like 10ms ON - 100ms OFF. Can anyone give me some advice on how to achieve this?

Thanks!

mikemoy
Posts: 686
Joined: Fri Jan 12, 2018 9:10 pm

Re: AC converter to DC

Postby mikemoy » Mon Mar 23, 2026 3:16 am

The ESp32 has a DAC, you should look into using that.

MicroController
Posts: 2661
Joined: Mon Oct 17, 2022 7:38 pm
Location: Europe, Germany

Re: AC converter to DC

Postby MicroController » Mon Mar 23, 2026 4:15 pm

Use a timer. Set it to e.g. 100ms. When it expires, turn output on, reset timer to 10ms; next time it expires, turn output off, reset timer to 100ms.

Who is online

Users browsing this forum: Google [Bot], PetalBot and 10 guests