Shop OBEX P1 Docs P2 Docs Learn Events
Safe way to interface with 12 volts — Parallax Forums

Safe way to interface with 12 volts

glentechglentech Posts: 35
edited 2007-01-06 21:21 in Propeller 1
What is a good way to interface with a 5 to 14 volt (automotive vehicle speed sensor) source?· A voltage divider is not really the answer here.· Would a pull up on a npn transistor work?· Or would it be better to use a 3.3v zener with lets say a 100K resistor.·

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2007-01-06 19:22
    I assume you've got a digital sensor (a series of 5-14V pulses) rather than an analog sensor. Just the 100K resistor would work fine. The Propeller has protective diodes from the input pin to +3.3V to clamp any inputs to slightly above +3.3V (and similarly clamp negative inputs). The 100K resistor would limit the diode current to under 140ua which the Propeller can easily tolerate. You could even use a higher value resistor if you want. I'd recommend using an R-C low pass filter based on the maximum speed sensor pulse rate to help attenuate noise.
  • Vertex78Vertex78 Posts: 51
    edited 2007-01-06 20:10
    I've read a lot of posts about limiting the current of higher voltages to something that the propellor can tolerate. Does this mean that as long as the current is low enough the propellor can take any voltage?
  • Mike GreenMike Green Posts: 23,101
    edited 2007-01-06 21:21
    Within reasonable limits that's true. As mentioned, the Propeller input circuitry has protective diodes to the Vcc and Vss supply lines on-chip. These will conduct whenever the input voltage goes above +3.6V or below -0.3V. They're small diodes and can conduct on the order of tens of milliamps, but too much current injected into the Vcc lines on the chip will raise or lower the Vcc voltage to the rest of the chip and can either create noise, cause unreliable operation, or damage the chip. Something on the order of a fraction of a milliamp should be just fine.
Sign In or Register to comment.