Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

18F4431 - RC6 not reading the input

Status
Not open for further replies.

atferrari

Well-Known Member
Most Helpful Member
18F4431 - DIP chip

I have made:

TRISC = '11111111' (all pins IN) and applied 10K pullup resistors to RC<7:0>.

The sole modules involving RC6 (AFAIK), SSPCON and RCSTA, = '00000000'.

My problem:

Reading PORTC is correct for all pins but RC6 which always reads '0'.

I measured the voltage at the pin, getting 0.28 V.

Also checked Silicon revision 3 to no avail.

Tested with two different chips.

What I am overlooking here?
 
Sounds like you have a short on your board. With a 10k pullup and the pin set to input you should have 5V. Can you remove the chip and measure the voltage to see if it is a short?

Mike.
 
Checked already, Mike. No short.

All peripherals except Power PWM control are disabled so I do not know what else to do. Wherever that pin is alluded to in the datasheet, it is shown involved with the EUSART only.

Any further idea will be welcome.

Gracias.
 
Last edited:
Can you chop your code down to a bare minimum that still shows the same behavior and post it here?

Mike.
 
Problem solved

Hola Mike again,

It was not a short but an open circuit!. The pin was floating, not seeing the 5V. I started to suspect that when found that for the first two seconds it was reading a 1 and then a 0.

Measured the voltage directly on the pin, with the micro in RESET and found that.

I just regret the so many hours checking software. :mad:

Gracias for replying.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top