MCLR as input?

For general Flowcode discussion that does not belong in the other sections.
Post Reply
jan.didden
Posts: 82
http://meble-kuchenne.info.pl
Joined: Thu Dec 17, 2020 3:16 pm
Has thanked: 20 times
Been thanked: 12 times

MCLR as input?

Post by jan.didden »

I want to use the MCLR enable pin on the PIC16F15355 as input pin (Port E pin 3).
I set the appropriate config bit in the Build|Project Options.
But depending on the signal at that pin, the controller still resets unexpectedly.
Is there anything else I need to do to disable the MCLR and enable the input?

Jan Didden

jan.didden
Posts: 82
Joined: Thu Dec 17, 2020 3:16 pm
Has thanked: 20 times
Been thanked: 12 times

Re: MCLR as input?

Post by jan.didden »

Whooa! This has been resolved. There is a config bit for LVP (Low Voltage Programming), and if this is enabled, it overrides the setting for MCLR/E3 input. Set LVP to disable, set MCLR to '.. is input pin' and all works as intended.

Jan Didden

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: MCLR as input?

Post by BenR »

Hi Jan, Glad you got it working and thanks for letting us know.

For me LVP is a setting to always avoid if you can, it can essentially put the running chip into none running program mode if left floating and worst case has the potental to erase/reprogram the device given the correct sequence of inputs or noise on the programming pins.

Post Reply