Hey, >For input only lines I'd recommend resistors (100K to 1M) in series >with the inputs and placed near the chip. The internal pull-ups >can't be used then, add pullup resistors on the "outside" end of the >isolation resistors. I am using the internal pull-ups, as I need to keep the amount of external components to a minimum. The I/O lines, because they run through very long wires (we're talking 120 feet to the switch), are going to have some resistance. In fact, because the machine I am building uses a specialized standard, the resistance can go up to 100 ohms when the switch is closed and the machine should still detect the change. >For real heavy-duty protection split the resistors in two and put a >zener, MOV, or similar device between the midpoint and ground. Also >be sure the resistors have adequate voltage capacity so they won't >flash over internally. Stay away from physically small resistors >like 1/8W or SMD ones. Small capacitors on the PIC pins to ground >would further attenuate static spikes that may couple capacitively >through the resistors. The design is not terribly heavy-duty. I am not taking direct hits from lightning or anything like that. I can't use the capacitors because I am pulsing the I/O lines at a very high rate and I don't want to filter all that out. >Bidirectional lines are tougher to isolate. A series resistor may >still be tolerable if the loading is light. For example if its a >matrix scan, make the pullup resistors rather large and add some >delay so the long RC times can settle. I suppose the series resistor is the best technique. About 2K for each line should do? Data lines look something like this: -| |----------o| | |-- P|----------o| | | I| -o| | |-- C|----------o| | _| This is an example setup and is not quite like the real application. The real application has six I/O lines for switches and the controller must detect contact between them and in any combination. I send out a pulse into a data line and see where it comes back. So you see my problem... If I put series resistors on each of the lines, I double the resistance. That gives my 4K series resistance for TTL logic levels. The Microchip application note for static control said that all you need is a capacitor from power to ground. I hope this is all I need. Thanks for you help, though. Later, Eric P.S. The environment that this machine will be used in is basically a regular wooden gym floor with people wearing rubber shoes. One of the I/O lines may go to a tremendous metal floor pad with people walking all over it. ______________________________ Reply Separator _________________________________ Subject: Re: Static control Author: Mike Keitz at INTERNET Date: 9/24/97 1:13 AM On Tue, 23 Sep 1997 14:22:29 -0700 ERIC SCHLAEPFER writes: > Hi All, > > Does anyone here know a really good static control method that >works > with the PIC16F84? I have six I/O lines that go outside of the > project's case and go through really long wires to switches. Some >of > the wires are exposed and will be fiddled with by people, and I >don't > want the chip damaged. I've checked the Microchip application >notes, > and they say to put at 10000 pf capacitor from power to ground. >Is > this all that is necessary? For input only lines I'd recommend resistors (100K to 1M) in series with the inputs and placed near the chip. The internal pull-ups can't be used then, add pullup resistors on the "outside" end of the isolation resistors. For real heavy-duty protection split the resistors in two and put a zener, MOV, or similar device between the midpoint and ground. Also be sure the resistors have adequate voltage capacity so they won't flash over internally. Stay away from physically small resistors like 1/8W or SMD ones. Small capacitors on the PIC pins to ground would further attenuate static spikes that may couple capacitively through the resistors. > > I thought of putting in a TTL buffer or an optoisolator, but the >data > lines need to bidirectional. Bidirectional lines are tougher to isolate. A series resistor may still be tolerable if the loading is light. For example if its a matrix scan, make the pullup resistors rather large and add some delay so the long RC times can settle.