View previous topic :: View next topic |
Author |
Message |
Joshua Lai
Joined: 19 Jul 2004 Posts: 42 Location: Malaysia, PJ
|
Pin A2 and A4 spoilt ?? |
Posted: Tue Oct 04, 2005 11:29 pm |
|
|
PIC 16F876, Compiler 2.734
I spent whole night, eeprom not working. Then found SDA always low.
I tested port A pin by pin using LED, and found that A2 and A4 always low, cannot output high or float.
Anyone has this problem before? Some pins spoilt and some ok? |
|
|
ckielstra
Joined: 18 Mar 2004 Posts: 3680 Location: The Netherlands
|
|
Posted: Wed Oct 05, 2005 12:58 am |
|
|
Have you studied the description of port-A pins in the datasheet? If you did you would have discovered these pins are mixed with comparator and ADC functions. Did you disable both the comparator and analog function blocks?
Pin-A4 on most chips has an open collector output, you'll have to adjust your electronics for this. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
|
Joshua Lai
Joined: 19 Jul 2004 Posts: 42 Location: Malaysia, PJ
|
|
Posted: Wed Oct 05, 2005 10:34 pm |
|
|
I bought a new PIC, running the same program, everything is ok. Why?
That prove my old PIC really spoilt? But other port still working fine.
I bought PIC from fanell, what difference for 1 timer and 3 timers? |
|
|
Joshua Lai
Joined: 19 Jul 2004 Posts: 42 Location: Malaysia, PJ
|
|
Posted: Wed Oct 05, 2005 10:40 pm |
|
|
I saw the pin diagram, I used 1k pull-up resistors.
Software i2c can use any pin right? |
|
|
Mark
Joined: 07 Sep 2003 Posts: 2838 Location: Atlanta, GA
|
|
Posted: Thu Oct 06, 2005 6:14 am |
|
|
Joshua Lai wrote: | I bought a new PIC, running the same program, everything is ok. Why?
|
Umm... cause you broke it! |
|
|
Joshua Lai
Joined: 19 Jul 2004 Posts: 42 Location: Malaysia, PJ
|
|
Posted: Fri Oct 07, 2005 9:33 pm |
|
|
|
|
|
|