board_sam9g20ek.c (236989) | board_sam9g20ek.c (238189) |
---|---|
1/*- 2 * Copyright (c) 2009 Greg Ansley. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 15 unchanged lines hidden (view full) --- 24 */ 25 26/* 27 * This board file can be used for both: 28 * Atmel SAM9G20-EK Development Card 29 */ 30 31#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2009 Greg Ansley. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 15 unchanged lines hidden (view full) --- 24 */ 25 26/* 27 * This board file can be used for both: 28 * Atmel SAM9G20-EK Development Card 29 */ 30 31#include <sys/cdefs.h> |
32__FBSDID("$FreeBSD: head/sys/arm/at91/board_sam9g20ek.c 236989 2012-06-13 04:52:19Z imp $"); | 32__FBSDID("$FreeBSD: head/sys/arm/at91/board_sam9g20ek.c 238189 2012-07-07 05:02:39Z imp $"); |
33#include <sys/param.h> 34#include <sys/systm.h> 35 | 33#include <sys/param.h> 34#include <sys/systm.h> 35 |
36#include <machine/board.h> |
|
36#include <arm/at91/at91board.h> 37#include <arm/at91/at91reg.h> 38#include <arm/at91/at91var.h> 39#include <arm/at91/at91sam9g20reg.h> 40#include <arm/at91/at91_piovar.h> 41#include <arm/at91/at91_pio_sam9g20.h> 42//#include <arm/at91/at91_led.h> 43 | 37#include <arm/at91/at91board.h> 38#include <arm/at91/at91reg.h> 39#include <arm/at91/at91var.h> 40#include <arm/at91/at91sam9g20reg.h> 41#include <arm/at91/at91_piovar.h> 42#include <arm/at91/at91_pio_sam9g20.h> 43//#include <arm/at91/at91_led.h> 44 |
44long | 45BOARD_INIT long |
45board_init(void) 46{ 47 /* PIOB's A periph: Turn USART 0's TX/RX pins */ 48 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB14_DRXD, 0); 49 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB15_DTXD, 1); 50 51 /* PIOB's A periph: Turn USART 0's TX/RX pins */ 52 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB4_TXD0, 1); --- 64 unchanged lines hidden (view full) --- 117 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA25_ERX2, 0); 118 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA26_ERX3, 0); 119 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA27_ERXCK, 0); 120 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA28_ECRS, 0); 121 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA29_ECOL, 0); 122 123 return (at91_ramsize()); 124} | 46board_init(void) 47{ 48 /* PIOB's A periph: Turn USART 0's TX/RX pins */ 49 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB14_DRXD, 0); 50 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB15_DTXD, 1); 51 52 /* PIOB's A periph: Turn USART 0's TX/RX pins */ 53 at91_pio_use_periph_a(AT91SAM9G20_PIOB_BASE, AT91C_PB4_TXD0, 1); --- 64 unchanged lines hidden (view full) --- 118 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA25_ERX2, 0); 119 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA26_ERX3, 0); 120 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA27_ERXCK, 0); 121 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA28_ECRS, 0); 122 at91_pio_use_periph_b(AT91SAM9G20_PIOA_BASE,AT91C_PA29_ECOL, 0); 123 124 return (at91_ramsize()); 125} |
126 127ARM_BOARD(AT91SAM9G20, "Atmel SAM9G20-EK Development Card"); |
|