system_gd32f10x.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. /*!
  2. \file system_gd32f10x.h
  3. \brief CMSIS Cortex-M3 Device Peripheral Access Layer Header File for
  4. GD32F10x Device Series
  5. */
  6. /*
  7. Copyright (c) 2012 ARM LIMITED
  8. All rights reserved.
  9. Redistribution and use in source and binary forms, with or without modification,
  10. are permitted provided that the following conditions are met:
  11. 1. Redistributions of source code must retain the above copyright notice, this
  12. list of conditions and the following disclaimer.
  13. 2. Redistributions in binary form must reproduce the above copyright notice,
  14. this list of conditions and the following disclaimer in the documentation
  15. and/or other materials provided with the distribution.
  16. 3. Neither the name of the copyright holder nor the names of its contributors
  17. may be used to endorse or promote products derived from this software without
  18. specific prior written permission.
  19. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  20. AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  21. WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  22. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  23. INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  24. NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  25. PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
  26. WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  27. ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
  28. OF SUCH DAMAGE.
  29. */
  30. /* This file refers the CMSIS standard, some adjustments are made according to GigaDevice chips */
  31. #ifndef SYSTEM_GD32F10X_H
  32. #define SYSTEM_GD32F10X_H
  33. #ifdef __cplusplus
  34. extern "C" {
  35. #endif
  36. #include <stdint.h>
  37. /* system clock frequency (core clock) */
  38. extern uint32_t SystemCoreClock;
  39. /* function declarations */
  40. /* initialize the system and update the SystemCoreClock variable */
  41. extern void SystemInit(void);
  42. /* update the SystemCoreClock with current core clock retrieved from cpu registers */
  43. extern void SystemCoreClockUpdate(void);
  44. #ifdef __cplusplus
  45. }
  46. #endif
  47. #endif /* SYSTEM_GD32F10X_H */