replaced 12mhz oscillator with 4mhz and disabled USB voltage regulator because experimental board has an external 3.3v regulator
This commit is contained in:
@@ -25,17 +25,18 @@
|
||||
//#include "usb.h"
|
||||
|
||||
|
||||
// PIC18F4550 Configuration Bit Settings
|
||||
|
||||
// PIC18F2550 Configuration Bit Settings
|
||||
|
||||
// 'C' source line config statements
|
||||
|
||||
// CONFIG1L
|
||||
#pragma config PLLDIV = 3 // PLL Prescaler Selection bits (Divide by 3 (12 MHz oscillator input))
|
||||
#pragma config CPUDIV = OSC2_PLL3// System Clock Postscaler Selection bits ([Primary Oscillator Src: /4][96 MHz PLL Src: /6])
|
||||
#pragma config PLLDIV = 1 // PLL Prescaler Selection bits (No prescale (4 MHz oscillator input drives PLL directly))
|
||||
#pragma config CPUDIV = OSC3_PLL4// System Clock Postscaler Selection bits ([Primary Oscillator Src: /3][96 MHz PLL Src: /4])
|
||||
#pragma config USBDIV = 2 // USB Clock Selection bit (used in Full-Speed USB mode only; UCFG:FSEN = 1) (USB clock source comes from the 96 MHz PLL divided by 2)
|
||||
|
||||
// CONFIG1H
|
||||
#pragma config FOSC = HS // Oscillator Selection bits (HS oscillator (HS))
|
||||
#pragma config FOSC = HSPLL_HS // Oscillator Selection bits (HS oscillator, PLL enabled (HSPLL))
|
||||
#pragma config FCMEN = OFF // Fail-Safe Clock Monitor Enable bit (Fail-Safe Clock Monitor disabled)
|
||||
#pragma config IESO = OFF // Internal/External Oscillator Switchover bit (Oscillator Switchover mode disabled)
|
||||
|
||||
@@ -43,7 +44,7 @@
|
||||
#pragma config PWRT = OFF // Power-up Timer Enable bit (PWRT disabled)
|
||||
#pragma config BOR = ON // Brown-out Reset Enable bits (Brown-out Reset enabled in hardware only (SBOREN is disabled))
|
||||
#pragma config BORV = 3 // Brown-out Reset Voltage bits (Minimum setting 2.05V)
|
||||
#pragma config VREGEN = ON // USB Voltage Regulator Enable bit (USB voltage regulator enabled)
|
||||
#pragma config VREGEN = OFF // USB Voltage Regulator Enable bit (USB voltage regulator disabled)
|
||||
|
||||
// CONFIG2H
|
||||
#pragma config WDT = OFF // Watchdog Timer Enable bit (WDT disabled (control is placed on the SWDTEN bit))
|
||||
@@ -58,9 +59,6 @@
|
||||
// CONFIG4L
|
||||
#pragma config STVREN = ON // Stack Full/Underflow Reset Enable bit (Stack full/underflow will cause Reset)
|
||||
#pragma config LVP = OFF // Single-Supply ICSP Enable bit (Single-Supply ICSP disabled)
|
||||
#ifdef PIC18F4550
|
||||
#pragma config ICPRT = OFF // Dedicated In-Circuit Debug/Programming Port (ICPORT) Enable bit (ICPORT disabled)
|
||||
#endif
|
||||
#pragma config XINST = OFF // Extended Instruction Set Enable bit (Instruction set extension and Indexed Addressing mode disabled (Legacy mode))
|
||||
|
||||
// CONFIG5L
|
||||
@@ -96,4 +94,6 @@
|
||||
// #pragma config statements should precede project file includes.
|
||||
// Use project enums instead of #define for ON and OFF.
|
||||
|
||||
#include <xc.h>
|
||||
#include <xc.h>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user