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.

PIC16F876A problems

Status
Not open for further replies.

Kingpin094

New Member
Is there something special that needs to be done in order to get the chip to make PORTB 3,6, and 7 to
be general purpose I/O?

I am aware that the PORTB pins are used in the debugger but I have turned off..... I think.
Is all that you have to do to turn the debuger of is to set the right bit in the config word?

This is the _CONFIG that I am using:
__CONFIG _CP_OFF & _WDT_OFF & _BODEN_OFF & _PWRTE_OFF & _DEBUG_OFF
& _HS_OSC & _LVP_OFF & _CPD_OFF

I have waded through the data sheet but still can't explain why the pins are acting strange. PB3 stays
high regardless of what the code does to it. PB6,7 are acting like they are connected and will turn on and
off but only at the same time.

Does anyone have any ideas? I can post the code but it is pretty lengthy.

Thanks.
kingpin094
 
Nevermind, figured it out. The chip is dead. Tried to reprogram it and it didn't verify. And when I put it in
the circuit I realized that I had a wire in the wrong place that put PORTB 3 in parrallel with a motor.

OOPS....

Thanks
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top