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.

a problem with pic16f877a

Status
Not open for further replies.

jena

New Member
help me guys

i have a problem with my smally pic16f877a , i don't know what is the error ? , i tries all tests and all changes i change the pic , nothing chages , the led is not blinking , i care for the frequency so i tries to ligh it on only , nothing changes :confused: , i use pic16f877a , mplab v8.00
and i thke the hex file and burn it on the chip using winpic , i don't know where is the error ? by the way i use assembly to write the code .

but i export the hex file it dosen't appear on buildup so i export from

file tab
and then export is this right ?:confused:

thank you very much :confused:
 
what programmer are you using from mplab 8.0?
if you are using pickit2 can you try to exit the mplab and start pickit application? Does pickit2 detect the target platform?

are you using 16f877a on some dev board or you made a prototype yourself, can you draw schematic on how you connected everything ...

was it ever working?
 
p16f877a

PROCESSOR 16F877A
#include "P16F877A.inc"
__CONFIG _HS_OSC & _LVP_OFF & _WDT_OFF
ERRORLEVEL -302

cblock 0x20
brojac1
brojac2
brojac3
brojac4
endc
org 0x00

banksel TRISB
clrf TRISB
banksel PORTB
loop

movlw b'10101010'
movwf PORTB
movlw 0xff
movwf brojac2
loop2
movlw 0xff
movwf brojac1
loop1

decfsz brojac1
goto loop1
decfsz brojac2
goto loop2
movlw b'01010101'
movwf PORTB
movlw 0xff
movwf brojac2
loop4
movlw 0xff
movwf brojac1
loop3
decfsz brojac1
goto loop3
decfsz brojac2
goto loop4
goto loop
end


this is how u change the blinking status on your leds
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top