Cerebot 32MX7 Reference Manual
Appendix A: Example of Configuration Values
The following example illustrates setting the configuration values in the PIC32 microcontroller on the
Cerebot 32MX7. The microcontroller configuration should be done in a single source file in the project,
and is typically done in the ‘main’ project source file. This example sets all configuration values to
valid values for the Cerebot 32MX7 board. It sets the system clock for processor operation at 80Mhz,
and the peripheral bus at 10Mhz.
/* ------------------------------------------------------------ */
/* PIC32 Configuration Settings */
/* ------------------------------------------------------------ */
/* Oscillator Settings
*/
#pragma config FNOSC
#pragma config POSCMOD
#pragma config FPLLIDIV
#pragma config FPLLMUL
#pragma config FPLLODIV
#pragma config FPBDIV
#pragma config FSOSCEN
=
=
=
=
=
=
=
PRIPLL
EC
DIV_2
MUL_20
DIV_1
DIV_8
OFF
//
//
//
//
//
//
//
Oscillator selection
Primary oscillator mode
PLL input divider
PLL multiplier
PLL output divider
Peripheral bus clock divider
Secondary oscillator enable
/* Clock control settings
*/
#pragma config IESO = OFF
#pragma config FCKSM = CSDCMD
#pragma config OSCIOFNC = OFF
/* USB Settings
*/
// Internal/external clock switchover
// Clock switching (CSx)/Clock monitor (CMx)
// Clock output on OSCO pin enable
#pragma config UPLLEN = ON
#pragma config UPLLIDIV = DIV_2
#pragma config FVBUSONIO = OFF
#pragma config FUSBIDIO = OFF
//
//
//
//
USB PLL enable
USB PLL input divider
VBUS pin control
USBID pin control
/* Other Peripheral Device settings
*/
#pragma config FWDTEN = OFF // Watchdog timer enable
#pragma config WDTPS = PS1024 // Watchdog timer post-scaler
#pragma config FSRSSEL = PRIORITY_7 // SRS interrupt priority
#pragma config FCANIO = OFF // Standard/alternate CAN pin select
#pragma config FETHIO = ON // Standard/alternate ETH pin select
#pragma config FMIIEN = OFF // MII/RMII select (OFF=RMII)
/* Code
*/
Protection settings
#pragma
#pragma
#pragma
config CP
config BWP
config PWP
= OFF
= OFF
= OFF
// Code protection
// Boot flash write protect
// Program flash write protect
/* Debug settings
*/
#pragma config ICESEL
www.digilentinc.com
= ICS_PGx1
// ICE pin selection
page 10 of 19
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
相关PDF资料
TEACLIPPER-PIC-HV-PT PROGRAMMER TEACLIPPER/PIC HI-V
TJA1010T/N1,118 IC OCTAL LOW SIDE DRVR 28SOIC
TLC5945PWP IC LED DRIVER LINEAR 28-TSSOP
TLD1020-12 POWER SUPPLY 20W 12VDC 1.66A
TLD1020-24-C0350 POWER SUPPLY 20W 12-24VDC .350A
TLD1020-24-C0700 POWER SUPPLY 20W 12-24VDC .700A
TLD1020-24 POWER SUPPLY 20W 24VDC .830A
TLD1020-36-C0350 POWER SUPPLY 20W 18-36VDC .350A
相关代理商/技术参数
TDGL005 功能描述:子卡和OEM板 chipKIT Basic I/O Shield RoHS:否 制造商:BeagleBoard by CircuitCo 产品:BeagleBone LCD4 Boards 用于:BeagleBone - BB-Bone - Open Source Development Kit
TDGL006 功能描述:界面开发工具 chipKIT Network Shield RoHS:否 制造商:Bourns 产品:Evaluation Boards 类型:RS-485 工具用于评估:ADM3485E 接口类型:RS-485 工作电源电压:3.3 V
TDGL007 功能描述:开发板和工具包 - PIC / DSPIC DIGILENT CEREBOT MC7 MOTOR CONTROL BRD RoHS:否 制造商:Microchip Technology 产品:Starter Kits 工具用于评估:chipKIT 核心:Uno32 接口类型: 工作电源电压:
TDGL008 功能描述:开发板和工具包 - PIC / DSPIC Digilent Cerebot MX3ck Dev Brd RoHS:否 制造商:Microchip Technology 产品:Starter Kits 工具用于评估:chipKIT 核心:Uno32 接口类型: 工作电源电压:
TDGL009 功能描述:开发板和工具包 - PIC / DSPIC Digilent Cerebot MX4cK Dev Brd RoHS:否 制造商:Microchip Technology 产品:Starter Kits 工具用于评估:chipKIT 核心:Uno32 接口类型: 工作电源电压:
TDGL010 功能描述:开发板和工具包 - 其他处理器 Digilent Cerebot MX7cK Dev Brd RoHS:否 制造商:Freescale Semiconductor 产品:Development Systems 工具用于评估:P3041 核心:e500mc 接口类型:I2C, SPI, USB 工作电源电压:
TDGL011 功能描述:MODULE DIGILENT PMOD WIFI RoHS:是 类别:RF/IF 和 RFID >> RF 评估和开发套件,板 系列:Digilent 标准包装:1 系列:- 类型:GPS 接收器 频率:1575MHz 适用于相关产品:- 已供物品:模块 其它名称:SER3796
TDGL012 功能描述:MODULE DIGILENT PMODRF2 RoHS:是 类别:RF/IF 和 RFID >> RF 评估和开发套件,板 系列:Digilent 标准包装:1 系列:- 类型:GPS 接收器 频率:1575MHz 适用于相关产品:- 已供物品:模块 其它名称:SER3796