|
| 1 | +/* |
| 2 | + Copyright (c) 2015 Arduino LLC. All right reserved. |
| 3 | + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. All right reserved. |
| 4 | +
|
| 5 | + This library is free software; you can redistribute it and/or |
| 6 | + modify it under the terms of the GNU Lesser General Public |
| 7 | + License as published by the Free Software Foundation; either |
| 8 | + version 2.1 of the License, or (at your option) any later version. |
| 9 | +
|
| 10 | + This library is distributed in the hope that it will be useful, |
| 11 | + but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 13 | + See the GNU Lesser General Public License for more details. |
| 14 | +
|
| 15 | + You should have received a copy of the GNU Lesser General Public |
| 16 | + License along with this library; if not, write to the Free Software |
| 17 | + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA |
| 18 | +*/ |
| 19 | + |
| 20 | +#ifndef _BOARD_DEFINITIONS_H_ |
| 21 | +#define _BOARD_DEFINITIONS_H_ |
| 22 | + |
| 23 | +/* |
| 24 | + * USB device definitions |
| 25 | + */ |
| 26 | +#define STRING_PRODUCT "Arduino Zero" |
| 27 | +#define USB_VID_HIGH 0x23 |
| 28 | +#define USB_VID_LOW 0x41 |
| 29 | +#define USB_PID_HIGH 0x00 |
| 30 | +#define USB_PID_LOW 0x4D |
| 31 | + |
| 32 | +/* |
| 33 | + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by |
| 34 | + * quickly tapping two times on the reset button. |
| 35 | + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not |
| 36 | + * be touched from the loaded application. |
| 37 | + */ |
| 38 | +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) |
| 39 | +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) |
| 40 | + |
| 41 | +/* |
| 42 | + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected |
| 43 | + * pin is tied LOW. |
| 44 | + */ |
| 45 | +//#define BOOT_LOAD_PIN PIN_PA21 // Pin 7 |
| 46 | +//#define BOOT_LOAD_PIN PIN_PA15 // Pin 5 |
| 47 | + |
| 48 | +#define BOOT_USART_MODULE SERCOM0 |
| 49 | +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM0 |
| 50 | +#define BOOT_USART_PER_CLOCK_INDEX GCLK_ID_SERCOM0_CORE |
| 51 | +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 |
| 52 | +#define BOOT_USART_PAD3 PINMUX_PA11C_SERCOM0_PAD3 |
| 53 | +#define BOOT_USART_PAD2 PINMUX_PA10C_SERCOM0_PAD2 |
| 54 | +#define BOOT_USART_PAD1 PINMUX_UNUSED |
| 55 | +#define BOOT_USART_PAD0 PINMUX_UNUSED |
| 56 | + |
| 57 | + |
| 58 | +/* Master clock frequency */ |
| 59 | +#define CPU_FREQUENCY (48000000ul) |
| 60 | +#define VARIANT_MCK CPU_FREQUENCY |
| 61 | + |
| 62 | +/* Frequency of the board main oscillator */ |
| 63 | +#define VARIANT_MAINOSC (32768ul) |
| 64 | + |
| 65 | +/* Calibration values for DFLL48 pll */ |
| 66 | +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) |
| 67 | +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) |
| 68 | + |
| 69 | +/* |
| 70 | + * LEDs definitions |
| 71 | + */ |
| 72 | +#define BOARD_LED_PORT (0) |
| 73 | +#define BOARD_LED_PIN (17) |
| 74 | + |
| 75 | +#define BOARD_LEDRX_PORT (1) |
| 76 | +#define BOARD_LEDRX_PIN (3) |
| 77 | + |
| 78 | +#define BOARD_LEDTX_PORT (0) |
| 79 | +#define BOARD_LEDTX_PIN (27) |
| 80 | + |
| 81 | +#endif // _BOARD_DEFINITIONS_H_ |
0 commit comments