-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add periph_clock_config.h to handle ifndefs
- Loading branch information
Dan Evans
committed
Aug 16, 2017
1 parent
3f316f3
commit 9d7b86d
Showing
5 changed files
with
63 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
/* | ||
* Copyright (C) 2017 Daniel Evans <photonthunder@gmail.com> | ||
* | ||
* This file is subject to the terms and conditions of the GNU Lesser | ||
* General Public License v2.1. See the file LICENSE in the top level | ||
* directory for more details. | ||
*/ | ||
|
||
/** | ||
* @ingroup cpu_samd21 | ||
* @{ | ||
* | ||
* @file | ||
* @brief CPU specific definitions for default clock configuration | ||
* | ||
* @author Daniel Evans <photonthunder@gmail.com> | ||
*/ | ||
|
||
#ifndef PERIPH_CLOCK_CONFIG_H | ||
#define PERIPH_CLOCK_CONFIG_H | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
/** | ||
* @brief Default Clock configurations | ||
*/ | ||
#ifndef CLOCK_8MHZ | ||
#define CLOCK_8MHZ (8000000UL) | ||
#endif | ||
|
||
#ifndef CLOCK_XOSC32K | ||
#define CLOCK_XOSC32K (0) | ||
#endif | ||
|
||
#ifndef XOSC32_RUNSTDBY | ||
#define XOSC32_RUNSTDBY (0) | ||
#endif | ||
|
||
#ifndef GEN1_1MHZ | ||
#define GEN1_1MHZ (1) | ||
#endif | ||
|
||
#ifndef GEN2_XOSC32 | ||
#define GEN2_XOSC32 (0) | ||
#endif | ||
|
||
#ifndef GEN3_ULP32K | ||
#define GEN3_ULP32K (1) | ||
#endif | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif /* PERIPH_CLOCK_CONFIG_H */ | ||
/** @} */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters