cfg_usbdev_default.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 Kees Bakker, SODAQ
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
9 #pragma once
10 
21 #include <stdint.h>
22 
23 #include "cpu.h"
24 #include "periph_cpu.h"
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
34 static const sam0_common_usb_config_t sam_usbdev_config[] = {
35  {
36  .dm = GPIO_PIN(PA, 24),
37  .dp = GPIO_PIN(PA, 25),
38  .d_mux = GPIO_MUX_G,
39  .device = &USB->DEVICE,
40  .gclk_src = SAM0_GCLK_MAIN,
41  }
42 };
45 #ifdef __cplusplus
46 }
47 #endif
48 
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
Definition: periph_cpu.h:45
@ PA
port A
@ GPIO_MUX_G
select peripheral function G
#define SAM0_GCLK_MAIN
120 MHz main clock
Definition: periph_cpu.h:73
USB peripheral parameters.