mayasunny
Member level 3
Hi members,
im working on PIC16F877A micro controller with 20Mhz crystal and with xc8 compiler , my problem is the lcd working properly with icd3 connected(i flash the code into micro controller), when i remove icd3 tool and power off/on the main unit lcd not displaying anything, until I touch the MCLR pin to GND point through a wire once / pressing push button switch connected to MCLR , i dont know why? one more thing how to set MCLR in software, i tried #pragma config MCLRE = ON, but is showing error to me, i need help? here are my configuration bits
im working on PIC16F877A micro controller with 20Mhz crystal and with xc8 compiler , my problem is the lcd working properly with icd3 connected(i flash the code into micro controller), when i remove icd3 tool and power off/on the main unit lcd not displaying anything, until I touch the MCLR pin to GND point through a wire once / pressing push button switch connected to MCLR , i dont know why? one more thing how to set MCLR in software, i tried #pragma config MCLRE = ON, but is showing error to me, i need help? here are my configuration bits
Code:
#pragma config FOSC = HS // Oscillator Selection bits (HS oscillator)
#pragma config WDTE = OFF // Watchdog Timer Enable bit (WDT disabled)
#pragma config PWRTE = ON // Power-up Timer Enable bit (PWRT enabled)
#pragma config BOREN = OFF // Brown-out Reset Enable bit (BOR enabled)
#pragma config LVP = ON // Low-Voltage (Single-Supply) In-Circuit Serial Programming Enable bit (RB3 is digital I/O, HV on MCLR must be used for programming)
#pragma config CPD = OFF // Data EEPROM Memory Code Protection bit (Data EEPROM code protection off)
#pragma config WRT = OFF // Flash Program Memory Write Enable bits (Write protection off; all program memory may be written to by EECON control)
#pragma config CP = OFF // Flash Program Memory Code Protection bit (Code protection off)
[\ code]
Last edited: