Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Categories > Micro Controllers


Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc.

Reply
 
LinkBack Thread Tools Display Modes
Old 1st October 2004, 01:37 PM   (permalink)
Default GPIO 0 on PIC12F629

I have just started using the PIC12F629.

Everything I have done so far works fine except GP0 (pin 7)

I have wired it up with a pull up resistor but it always reads 0 in software no matter what.

It is not a wiring problem (voltage is normally at 5 and goes to 0 when button is pressed) and GP0 has been set as an input.

Are there any other issues associated with this pin on the 12F629 ?



I have looked through the datasheet but found nothing so far.


Many thanks for your help.

John
__________________
The first rule of mstechca club is do not talk about mstechca club.
http://www.electro-tech-online.com/s...induser&u=1245
2camjohn is offline  
Old 1st October 2004, 02:46 PM   (permalink)
Default

Are you correctly setting the ANSEL and CMCON registers?, see example 3-1 on page 21 of the datasheet.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 1st October 2004, 02:59 PM   (permalink)
Default

I am now thanks to you Nigel. ops:


Its working
__________________
The first rule of mstechca club is do not talk about mstechca club.
http://www.electro-tech-online.com/s...induser&u=1245
2camjohn is offline  
Reply

Bookmarks

Thread Tools
Display Modes





All times are GMT. The time now is 07:49 AM.


Electronic Circuits  |  Learning Electronics
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.

eXTReMe Tracker