I've been using the 12f629 on few home hobby projects and now I need more I/O and I found that the 16f630 is about the same as the 629 but with more I/O and should fill the need. what little programing I do I use PBP-CDlite
this is how I was shown to config. the I/O , set to digital and turn weak pull ups on. But Iam not sure how to do it with the 16f630. Any help?. Looking at the data sheet I can read that RC0-RC5 do not have weak pulls.
If some one would show me how to read the data sheet to config the I/O and pullups I would be very thankful
@ DEVICE pic12F629
TRISIO = %00001100 ' make gpio 2 / 3 inputs
' FOR REFERENCE ONLY
'00111111 = ALL PINS INPUTS
'00100000= GPIO.5 PIN 2 IS A INPUT
'00010000= GPIO.4 PIN 3 IS A INPUT
'00001000= GPIO.3 PIN 4 IS A INPUT
'00000100= GPIO.2 PIN 5 IS A INPUT
'00000010= GPIO.1 PIN 6 IS A INPUT
'00000001= GPIO.0 PIN 7 IS A INPUT
OPTION_REG.7 = 0 ' gpio 0 - 2 digital
WPU = 255 ' week pull ups on all pins
CMCON = 7 ' turn weak pull ups on
SYMBOL RED = GPIO.0 'PIN 7
SYMBOL GREEEN = GPIO.1 'PIN 6
SYMBOL PB = GPIO.2 'PIN 5
SYMBOL BLUE = GPIO.4 'PIN 3
SYMBOL ORANGE = GPIO.5 'PIN 2
Bookmarks