gjs_rsdi
Joined: 06 Feb 2006 Posts: 468 Location: Bali
|
PIC16F648A configuration problem |
Posted: Tue Mar 29, 2016 7:24 pm |
|
|
Hi
My compiler is CCS PCM C Compiler, Version 3.249
I have the configuration set using CCS wizard and my additions as below:
Code: | #FUSES WDT
//***************FUSES for 8MHz external clock*********************
#FUSES EC_IO//for external clock
#use delay(clock=8000000,RESTART_WDT)//for external clock
//***************FUSES for 4MHz internal RC oscilator**************
//#FUSES INTRC_IO//for internal oscilator
//#use delay(clock=4000000,RESTART_WDT)//for internal oscilator
//*****************************************************************
#FUSES BROWNOUT,MCLR,NOLVP,PUT
//*****************************************************************
//#FUSES PROTECT//for code protection
#FUSES NOPROTECT//no code protection
//*****************************************************************
#FUSES NOCPD//Data EEPROM NOT Code Protected
//#FUSES CPD//Data EEPROM Code Protected
//*****************************************************************
#use rs232(baud=9600,parity=N,xmit=PIN_B2,rcv=PIN_B1,bits=8,restart_wdt)//for external clock
//#use rs232(baud=4800,parity=N,xmit=PIN_B2,rcv=PIN_B1,bits=8,restart_wdt)//for internal oscilator
//***************************************************************** |
When opening MPLAB v8.85 > Configure >Configuration Bits...
I am getting some of the bits wrong:
WDTE WDT disabled
BOREN BOD disabled
In C:
Code: | setup_timer_0(RTCC_EXT_L_TO_H);
setup_wdt(WDT_144MS); |
Testing physically the board with 2.2V, everything functioning so BOD really disabled.
Can somebody tell me what I am doing wrong?
Best wishes
Joe |
|