PDA

View Full Version : I/O pin and MCLR



Dwayne
- 13th July 2004, 21:09
Hello folks...

One of the things that I get caught on every once in a while, MCLR being set to Reset.


If you look in the Chips instrution set, you can read whether a port is for I/O, PWM, AD, MCLR, or another purpose. You must tell it whether it is a digital or analog port. If you assign that port something that it is not, don't expect it to work!...
For example, the 12f675 has GPIO.3 is a INPUT pin, as well as a MCLR pin. Do not attempt to use GPIO.3 as a output pin.

When you program your chip, make sure you program your MCLR as a INPUT pin, not a RESET.

If you program the MCLR as a Input pin, your chip will power up by itself. If you program the MCLR as a RESET, you must use a resister and put some voltage to that MCLR pin to activate your chip.

As they say... A chip with no Spark, Looks pretty Dark.

Do not get caught in the trap of NOT checking to see if the pin is defaulted to INPUT on your programmer.

Melanie
- 15th July 2004, 10:52
See also thread Pin RA4 doesn't work and the section within that thread Why doesn't the POT Command and RCTIME Command work?. Those commands will NOT WORK PROPERLY on INPUT ONLY pins (such as the MCLR pin, which, where permitted to be used for I/O, tends to appear as INPUT ONLY). As always check with your PICs Datasheet.