PDA

View Full Version : Pic12f683 Mclre



jmbanales21485
- 30th March 2007, 22:32
Hello to all,

I have had many problems with PIC's in the past and usually have been able to find my way through looking through these forums. However, I have been having a small problem with MCLRE on the 12F683 PIC.

I want to utilize GP3/MCLRE as a digital Input so that if it reads HIGH do something, if it reads LOW then do something else.

From what I understand GP3 is considered only an input (i.e a '1' bit), however the MCLRE state can be changed from the 'MCLRE' state to the 'Digital Input' state using the Configuration bits (address: 2007h). This is what I have not been able to figure out. How can I modify the Configuration bits using the PicBasic Pro compiler to obtain the MCLRE as a digital input.

So far this is the test code that I have to test the pic and have been unsuccessful. Thank you in advanced



pulse VAR GPIO.0

loop:
if GPIO.3 = 1 then
HIGH pulse
else
LOW pulse
endif
goto loop

mackrackit
- 30th March 2007, 23:37
http://www.picbasic.co.uk/forum/showthread.php?t=543