Changes for a clean build of configs/sam4s-xplained

This commit is contained in:
Gregory Nutt 2013-06-11 17:33:43 -06:00
parent a40b739260
commit 3c7e2e18cb
6 changed files with 32 additions and 29 deletions

View File

@ -76,14 +76,14 @@
/* USB UTMI PLL start-up time */
#define BOARD_CKGR_UCKR_UPLLCOUNT (3 << PMC_CKGR_UCKR_UPLLCOUNT_SHIFT)
#define BOARD_CKGR_UCKR_UPLLCOUNT (3 << PMC_CKGR_UCKR_UPLLCOUNT_SHIFT)
/* Resulting frequencies */
#define SAM_MAINOSC_FREQUENCY (12000000)
#define SAM_MCK_FREQUENCY (48000000)
#define SAM_PLLA_FREQUENCY (96000000)
#define SAM_CPU_FREQUENCY (48000000)
#define BOARD_MAINOSC_FREQUENCY (12000000)
#define BOARD_MCK_FREQUENCY (48000000)
#define BOARD_PLLA_FREQUENCY (96000000)
#define BOARD_CPU_FREQUENCY (48000000)
/* HSMCI clocking
*

View File

@ -7,7 +7,8 @@ README
The SAM4S Xplained features:
- 12MHz crystal (no 32.768KHz crystal)S
- 120 MHz Cortex-M4 with MPU
- 12MHz crystal (no 32.768KHz crystal)
- Segger J-Link JTAG emulator on-board for program and debug
- MICRO USB A/B connector for USB connectivity
- IS66WV51216DBLL ISSI SRAM 8Mb 512K x 16 55ns PSRAM 2.5v-3.6v

View File

@ -72,35 +72,37 @@
/* Clocking *************************************************************************/
/* After power-on reset, the sam3u device is running on a 4MHz internal RC. These
* definitions will configure clocking with MCK = 48MHz, PLLA = 96, and CPU=48MHz.
* definitions will configure clocking with MCK = 48MHz, PLLA = 96, and CPU=120MHz.
*/
/* Main oscillator register settings */
#define BOARD_CKGR_MOR_MOSCXTST (63 << PMC_CKGR_MOR_MOSCXTST_SHIFT) /* Start-up Time */
/* PLLA configuration */
/* PLLA configuration:
*
* Source: 12MHz crystall at 12MHz
* PLLdiv: 10
* PLLmul: 1 (bypassed)
* Fpll: (12MHz * 10) / 1 = 120MHz
*/
#define BOARD_CKGR_PLLAR_MUL (7 << PMC_CKGR_PLLAR_MUL_SHIFT)
#define BOARD_CKGR_PLLAR_STMODE PMC_CKGR_PLLAR_STMODE_FAST
#define BOARD_CKGR_PLLAR_COUNT (63 << PMC_CKGR_PLLAR_COUNT_SHIFT)
#define BOARD_MAINOSC_FREQUENCY (12000000)
#define BOARD_CKGR_PLLAR_MUL (9 << PMC_CKGR_PLLAR_MUL_SHIFT)
#define BOARD_CKGR_PLLAR_DIV PMC_CKGR_PLLAR_DIV_BYPASS
#define BOARD_CKGR_PLLAR_COUNT (63 << PMC_CKGR_PLLAR_COUNT_SHIFT)
#define BOARD_PLLA_FREQUENCY (10*BOARD_MAINOSC_FREQUENCY)
/* PMC master clock register settings */
#define BOARD_PMC_MCKR_CSS PMC_MCKR_CSS_PLLA
#define BOARD_PMC_MCKR_PRES PMC_MCKR_PRES_DIV2
#define BOARD_PMC_MCKR_PRES PMC_MCKR_PRES_DIV1
#define BOARD_MCK_FREQUENCY (BOARD_PLLA_FREQUENCY/1)
#define BOARD_CPU_FREQUENCY (BOARD_PLLA_FREQUENCY/1)
/* USB UTMI PLL start-up time */
#define BOARD_CKGR_UCKR_UPLLCOUNT (3 << PMC_CKGR_UCKR_UPLLCOUNT_SHIFT)
/* Resulting frequencies */
#define SAM_MAINOSC_FREQUENCY (12000000)
#define SAM_MCK_FREQUENCY (48000000)
#define SAM_PLLA_FREQUENCY (96000000)
#define SAM_CPU_FREQUENCY (48000000)
#define BOARD_CKGR_UCKR_UPLLCOUNT (3 << PMC_CKGR_UCKR_UPLLCOUNT_SHIFT)
/* HSMCI clocking
*

View File

@ -193,7 +193,7 @@ CONFIG_ARCH_HAVE_RAMVECTORS=y
CONFIG_BOARD_LOOPSPERMSEC=4768
# CONFIG_ARCH_CALIBRATION is not set
CONFIG_DRAM_START=0x20000000
CONFIG_DRAM_SIZE=32768
CONFIG_DRAM_SIZE=131072
CONFIG_ARCH_HAVE_INTERRUPTSTACK=y
CONFIG_ARCH_INTERRUPTSTACK=0

View File

@ -87,10 +87,10 @@
*/
#define GPIO_D9 (GPIO_OUTPUT | GPIO_PULL_UP | GPIO_OUTPUT_SET | \
GPIO_PORTC | GPIO_PIN10)
#define GPIO_D10 (GPIO_OUTPUT | GPIO_PULL_UP | GPIO_OUTPUT_SET | \
GPIO_PORTC | GPIO_PIN17)
#define GPIO_D9 (GPIO_OUTPUT | GPIO_CFG_PULLUP | GPIO_OUTPUT_SET | \
GPIO_PORT_PIOC | GPIO_PIN10)
#define GPIO_D10 (GPIO_OUTPUT | GPIO_CFG_PULLUP | GPIO_OUTPUT_SET | \
GPIO_PORT_PIOC | GPIO_PIN17)
/* Mechanical buttons:
*
@ -101,9 +101,9 @@
* PA5 BP2
*/
#define GPIO_BP2 (GPIO_INPUT | GPIO_PULL_UP | GPIO_GLITCH_FILTER | \
GPIO_PORTA | GPIO_PIN5)
#define IRQ_BP2 SAM_IRQ_PA5
#define GPIO_BP2 (GPIO_INPUT | GPIO_CFG_PULLUP | GPIO_CFG_DEGLITCH | \
GPIO_PORT_PIOA | GPIO_PIN5)
#define IRQ_BP2 SAM_IRQ_PA5
/************************************************************************************
* Public Types

View File

@ -46,7 +46,7 @@
#include <arch/board/board.h>
#include "chip.h"
#include "sam_gpip.h"
#include "sam_gpio.h"
#include "sam4s-xplained.h"
#ifdef CONFIG_ARCH_LEDS