Try
HIGH GPIO.X
X being the pin number.
Try
HIGH GPIO.X
X being the pin number.
Dave
Always wear safety glasses while programming.
I tried this test:
TRISIO = %000000
TimeDelay CON 500
BlinkLoop:
GPIO = %111111
Pause TimeDelay
GPIO= %000000
Pause TimeDelay
Goto BlinkLoop
End
Basically, I am only interested in GPIO.0, GPIO.1 & GPIO.2. On 12f629 & 12f675, sometimes the pins will fire up and start working. Sometimes, I have to flip the switch couple times for it to work. However, it works every time on the 12f683.
This is all on 2 different breadboards with multiple 12f629 and one 12f675 and one 12f683. I don't think all the chips can be defective.
Also, when the 629 & 675 chips are not working, if I touch the chip or one of the I/O pins, the output would start working (driving an LED). I am very puzzled since I have only used the 12f683, but decided to buy cheaper 12f629 models since I don't need all the extra feature.
any more hints? Thanks.
Last edited by dfort; - 5th November 2007 at 18:26.
How are the config fuses set?
Dave
Always wear safety glasses while programming.
Hi,
And what about GPIO.3/MCLR ???
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
This is for the 12F675 using internal OSC
Code:DEFINE OSC 4 ANSEL=%00000000 CMCON=7 LOOP: HIGH GPIO.4 PAUSE 20 LOW GPIO.4 PAUSE 95 GOTO LOOP
Dave
Always wear safety glasses while programming.
for the 629 & 675:
Oscilator: INTOSC
Watchdog Timer: Enabled
Power-Up Timer: Disabled
MCLR Pin Function: Reset
Brown-Out Detect: Disabled
Code: N/P
Data EEPROM: N/P
NEVER MIND!!!!
Thanks. As I type in this message, I see that the MCLR Pin is for Reset. I changed it and reprogram and it works fine.
Thanks again for the help. I am the idiot of the day.
P.S. How come the 12f683 does not exhibit this problem? Does it have a built-in pull-up/down resistor?
All 3 of these have analog features on GPIO pins, so you'll want to disable analog for each
pin you want to use for digital output.
Bookmarks