pic16f1787 C语言程序,mplab x ide 搭配xc8 ,给PIC16F1787芯片驱动12864LCD液晶屏显示一串数字...

// CONFIG1

#pragma config FOSC = XT        // Oscillator Selection (XT Oscillator, Crystal/resonator connected between OSC1 and OSC2 pins)

#pragma config WDTE = OFF       // Watchdog Timer Enable (WDT enabLED)

#pragma config PWRTE = OFF      // Power-up Timer Enable (PWRT disabled)

#pragma config MCLRE = ON       // MCLR Pin Function Select (MCLR/VPP pin function is MCLR)

#pragma config CP = OFF         // Flash Program Memory Code Protection (Program memory code protection is disabled)

#pragma config CPD = OFF        // Data Memory Code Protection (Data memory code protection is disabled)

#pragma config BOREN = ON       // Brown-out Reset Enable (Brown-out Reset enabled)

#pragma config CLKOUTEN = OFF   // clock Out Enable (CLKOUT function is disabled. I/O or oscillator function on the CLKOUT pin)

#pragma config IESO = ON        // Internal/External Switchover (Internal/External Switchover mode is enabled)

#pragma config FCMEN = ON       // Fail-Safe Clock Monitor Enable (Fail-Safe Clock Monitor is enabled)

// CONFIG2

#pragma config WRT = OFF        // Flash Memory Self-Write Protection (Write protection off)

#pragma config VCAPEN = OFF     // Voltage Regulator Capacitor Enable bit (Vcap functionality is disabled on RA6.)

#pragma config PLLEN = ON       // PLL Enable (4x PLL enabled)

#pragma config STVREN = ON      // Stack OveRFlow/Underflow Reset Enable (Stack Overflow or Underflow will cause a Reset)

#pragma config BORV = LO        // Brown-out Reset Voltage Selection (Brown-out Reset Voltage (Vbor), low trip point selected.)

#pragma config LPBOR = OFF      // Low Power Brown-Out Reset Enable Bit (Low power brown-out is disabled)

#pragma config LVP = ON

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值