5
\$\begingroup\$

I have a board which contains a microcontroller and a 10k NTC thermistor (B57421V2103J62) wired to two external terminals, one of which is common with the board ground plane. The terminals are exposed on the outside of the case and, when the case is docked with a host device, the thermistor is connected to 12v via a 10k series resistor (on the host side). Apart from it being common with VSS the thermistor is not otherwise wired into the logic on the board.

I want to use the presence of voltage across the thermistor to detect when the case is docked (as there's no other reliable means of doing so). Within the operating temperature range of the hardware the voltage I would normally see on the thermistor contact could be in the range of roughly 10v down to 3v.

What I need to do is pull a 2.5v line either high or low (doesn't matter which) when the above voltage is applied and hand that to the micro. In the process of doing so I cannot pull any meaningful current from the thermistor circuit as doing so would alter its behavior.

I expect this is pretty straightforward with a FET but given the terminals are exposed (can be touched for example) I need to ensure it's properly protected, and I'm unsure about the most appropriate approach.

I was thinking of using an e.g. BSS138 with S tied to VSS, D to the 2.5v rail via a 1M series resistor and a 10k resistor in series with the gate which is then tied to the thermistor.

Does this sound reasonable? If so is there anything else I could/should do (such as add a zener?)

Edit: The micro is a PIC24H running at 2.5v. Speed isn't an issue.

rough concept

\$\endgroup\$
  • \$\begingroup\$ Is the microcontroller running from 2.5V? What type of MCU is it? \$\endgroup\$ – Andy aka Sep 20 '13 at 9:38
  • \$\begingroup\$ Instead of using words, your question would be much clearer if you'd include a diagram. I think your solution will work, but I'd be inclined to swap the two resistors -- use the 1M on the gate and the 10K as the 2.5V pullup. I'd also be tempted to put a small capacitor between the gate and ground to form a low-pass filter for protection against ESD events. I assume speed is not terribly critical in this application. \$\endgroup\$ – Dave Tweed Sep 20 '13 at 10:59
  • \$\begingroup\$ Thanks for the advice. I've added a diagram as you suggested. \$\endgroup\$ – chris Sep 20 '13 at 15:10
2
\$\begingroup\$

This would probably work, but to be on the safe side, I'd use an optocoupler, or a similar electrical isolation device in place of using a single MOSFET. The problem is the GD capacitance of the MOSFET, which, if in a case of a high frequency gate voltage rise may result in a transient voltage rise on the microcontroller pin before this parasitic capacitor has a chance to charge up.

Using a series resistor to the gate will only make the gate capacitor charge slower, so I'd drop it completely. With a FET device, you almost never need a series resistor, since the gate is not composed of a diode which you need to protect from drawing too much current, as in a bipolar device. The size of the pullup resistor will dictate how fast the parasitic capacitance will charge, so choosing it to be as small as possible seems like a good option, but it'll increase the static power consumption of your circuit considerably.

\$\endgroup\$
  • \$\begingroup\$ Wouldn't an optocoupler place a load on the thermistor circuit, though? I need to avoid disturbing that too much as doing so could lead to erroneous readings by the host. I probably could add a 12v TVS diode, though. \$\endgroup\$ – chris Sep 21 '13 at 4:27
  • \$\begingroup\$ Fair point; I didn't draw the entire circuit on the host side (as then it would get too large). On the host side there is a microprocessor which monitors the voltage; i.e. it treats the two resistors (the fixed 10k one and the thermistor) as a voltage divider, referring the voltage at the junction to the 12v source. \$\endgroup\$ – chris Sep 22 '13 at 2:29
  • \$\begingroup\$ Sorry about that, I think I missed the 10k resistor when I was last looking at your circuit, which makes my above comment completely invalid. And yes, any resistive load would bring an offset to your reading, and if that load is prone to changing by temperature as well, your reading would be way off. A high impedance device (a MOSFET) seems to be the best option here. Then again, you could use the MOSFET to power the optocoupler, which would provide the best of the two worlds. \$\endgroup\$ – deadude Sep 22 '13 at 2:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.