Connecting a electric valve to esp32

sksanthosh
Posts: 1
Joined: Sat Jun 15, 2024 2:02 pm

Connecting a electric valve to esp32

Postby sksanthosh » Sat Jun 15, 2024 2:10 pm

Hi

I am trying to connect a operate a electrical valve with a esp32
The circuit of the valve is as follows.
https://www.sensoware.com/docs/electric ... ons/sa501/

In this the green has to be supplied with +12 V trigger. So I will connect the +5V output using a transistor.
My question is the feedback output on the blue and yellow has +12V DC.
How should I connect to the esp32 pins which can only accept +5V DC right.

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

Re: Connecting a electric valve to esp32

Postby MicroController » Mon Jun 17, 2024 1:54 pm

sksanthosh wrote:
Sat Jun 15, 2024 2:10 pm
In this the green has to be supplied with +12 V trigger. So I will connect the +5V output using a transistor.
Since you need to switch the positive +12V, you'll need a 'high-side switch'; one transistor is probably not going to cut it.
My question is the feedback output on the blue and yellow has +12V DC.
How should I connect to the esp32 pins which can only accept +5V DC right.
The ESP's pins accept 3.3V input max. The easiest way would be to use two resistors as a voltage divider. Something in the range of 10k-100kOhm seems reasonable (e.g. 24k + 9.1k, or 62k + 22k).

Who is online

Users browsing this forum: No registered users and 65 guests