dutchengineer
Newbie

Hello everyone,
I have a question about a circuit I'm designing for my project.
First i'll explain what I want to achieve: I want a programma low-side current sink. (https://www.ti.com/lit/an/slaa868a/slaa868a.pdf?ts=1744035225495)
The PWMInput1 signal goes through a voltage divider to scale it down from 3.3v to 1.65v. Then there's an RC-circuit to create a DC-voltage. This DC voltage can be a maximum of 1.65v.
R17, C35 and R25 I looked around on the internet to find these values, I'm not sure how important they are if I change them.
Then there is Q2 and R43 as MOSFET and sense resistor. The load is hooked up to a voltage that can be anywhere between 0 - 48 V, goes through a series of LEDs, and then arrives at the MOSFET drain (EndLedChannel1).
Finally I have a 150k / 10k resistor divider to scale this 48 V (in case there's a short circuit between my LEDs and the 48V is connected straight to the drain) down to 0 - 3 V, so I can measure it with my ADC.
I built this circuit on a breadboard to test if. It works as expected to set a desired current by changing the duty cycle of the PWM signal.
However my problem is this.
In situation A: I connect PWMInput1 with a wire straight to ground. The opamp output now measures around 910 mV.
In situation B: I connect PWMInput1 with a probe to a 50-ohm impedance waveform generator. I set this waveform generator to output a DC voltage of 0V. The opamp output now measures at 0V.
In both situations the opamp non-inverting input (+) is connected to ground via (R15 + R13 // R21) or (R15 + (R13 + 50 ohm impedance waveform generator) // R21). However, in situation A the output voltage is around 910 mV, and in situation B the output voltage is my expected 0V.
Can someone explain why connecting the PWMInput1 straight to ground causes an unexpected 910 mV at the output? I would greatly appreciate it.
I have a question about a circuit I'm designing for my project.
First i'll explain what I want to achieve: I want a programma low-side current sink. (https://www.ti.com/lit/an/slaa868a/slaa868a.pdf?ts=1744035225495)
The PWMInput1 signal goes through a voltage divider to scale it down from 3.3v to 1.65v. Then there's an RC-circuit to create a DC-voltage. This DC voltage can be a maximum of 1.65v.
R17, C35 and R25 I looked around on the internet to find these values, I'm not sure how important they are if I change them.
Then there is Q2 and R43 as MOSFET and sense resistor. The load is hooked up to a voltage that can be anywhere between 0 - 48 V, goes through a series of LEDs, and then arrives at the MOSFET drain (EndLedChannel1).
Finally I have a 150k / 10k resistor divider to scale this 48 V (in case there's a short circuit between my LEDs and the 48V is connected straight to the drain) down to 0 - 3 V, so I can measure it with my ADC.
I built this circuit on a breadboard to test if. It works as expected to set a desired current by changing the duty cycle of the PWM signal.
However my problem is this.
In situation A: I connect PWMInput1 with a wire straight to ground. The opamp output now measures around 910 mV.
In situation B: I connect PWMInput1 with a probe to a 50-ohm impedance waveform generator. I set this waveform generator to output a DC voltage of 0V. The opamp output now measures at 0V.
In both situations the opamp non-inverting input (+) is connected to ground via (R15 + R13 // R21) or (R15 + (R13 + 50 ohm impedance waveform generator) // R21). However, in situation A the output voltage is around 910 mV, and in situation B the output voltage is my expected 0V.
Can someone explain why connecting the PWMInput1 straight to ground causes an unexpected 910 mV at the output? I would greatly appreciate it.