Hello y'all,
I've got a problem with a circuit and I don't know how to solve it.
I'm trying to read and write data on a 24V DC Bus Line.
First there is a voltage divider (for the receiving part) to lower the voltage to around 3V (1M + 147K).
Seems to be fine in general - but as soon as it's connected to GPIO17 its pulled down to around 0.3V which is not enough at all because it should be a high signal by default and go down for a low signal for a few milliseconds.
Then there is the sending part which has a transistor to short the 24V Bus Line to ground for a few milliseconds for each bit. Maybe there is a better way (I hope so) to do it because I only need to pull it down to around 20V for a low signal. But as I'm quite inexperienced with all that I can't do better.
Anyways... When I connect the Transmit Part to GPIO16 its immediately triggering the transistor and shorting the bus line to ground which shouldnt be like that either.
The ESP is not even powered on at this point.
I tried it with a D1 Mini with ESP8266 (Pin D5, D6) and a NodeMCU with ESP32 (GPIO16, GPIO17) as well without success.
Here's the schematic for the circuit (The ESP Part is simlified an incomplete just to show):
It's based on this Video:
Another Project based on it:
All of them seem to work just fine - not in my case tho.
Maybe I do something wrong.
I'd be very happy if there is somebody that could help me a little.
Best regards

