Shop OBEX P1 Docs P2 Docs Learn Events
series resistors on I/O pins? — Parallax Forums

series resistors on I/O pins?

TWRackersTWRackers Posts: 33
edited 2009-02-03 14:21 in BASIC Stamp
I've noticed on some example schematics for the BASIC Stamps that a 220 ohm resistor is placed in series between a Stamp's I/O pin and a pin on an external device, yet other times no resistor is used. For example, every sample schematic I've seen using the Memsic 2125 2-axis accelerometer chip puts resistors between the chip's Xout and Yout pins and the Stamp's I/O pins. Schematics for the H48C 3-axis accelerometer chip, however, do not show series resistors. The Memory Stick Datalogger also does not show resistors being used. (I mention the H48C and the Datalogger because my current project uses both of them.) What is the difference between these two devices that requires the use of series resistors on one and not the other.

Another application I've seen that uses a series resistor (not necessarily 220 ohms) is when a Stamp's I/O pin is driving the gate of a MOSFET. I believe this is done to form a short time-constant RC circuit with the resistor and the MOSFET's inherent gate-to-source capacitance, thus limiting the inrush current when switching the MOSFET. Is my understanding of the purpose of this resistor correct?

Comments

  • FranklinFranklin Posts: 4,747
    edited 2009-02-03 04:37
    The resistors are there to create a current limit into the pins on the stamp in case the pin is shorted to power or ground when it is an output. This keeps the pin safe. if the device connected to the pin passes signal only you can get away without the resistor but in design situations it is cheap insurance.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • TWRackersTWRackers Posts: 33
    edited 2009-02-03 04:51
    (woot! another penguin avatar!)

    Why would the 2125 schematics show the resistors while the H48C schematics don't? Could it have something to do with the fact that the 2125 pins put out pulses whose widths must be measured, whereas the H48C pins basically form an SPI interface? (I just noticed that difference while looking over the datasheets again.)
  • Beau SchwabeBeau Schwabe Posts: 6,560
    edited 2009-02-03 08:14
    TWRackers,

    The H48C Tri-axis accelerometer is equipped with an internal 1K resistor on the DOUT line of the MCP3204 where as the Memsic 2125 does not have a current limiting resistor. This is why you see an external resistor for the 2125 and not on the H48C.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
    1015 x 929 - 123K
    1013 x 935 - 122K
  • MoskogMoskog Posts: 554
    edited 2009-02-03 13:47
    Usually I see there is a limiting resistor on the Data line, but would you recommend a current limiting resistor to the Chip Select and the Clock line too?
  • Beau SchwabeBeau Schwabe Posts: 6,560
    edited 2009-02-03 14:21
    Moskog,

    "would you recommend a current limiting resistor to the Chip Select and the Clock line too" - No, the only time that you would use a current limiting resistor is when there is a chance of a "bit-collision" where both signals can be outputs and potentially be driven in opposite directions.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
Sign In or Register to comment.