A bundled STM32F10x Std Periph and CMSIS library
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

67 lines
2.1 KiB

  1. /**************************************************************************//**
  2. * @file system_ARMSC300.c
  3. * @brief CMSIS Device System Source File for
  4. * ARMSC300 Device Series
  5. * @version V1.07
  6. * @date 30. January 2012
  7. *
  8. * @note
  9. * Copyright (C) 2012 ARM Limited. All rights reserved.
  10. *
  11. * @par
  12. * ARM Limited (ARM) is supplying this software for use with Cortex-M
  13. * processor based microcontrollers. This file can be freely distributed
  14. * within development tools that are supporting such ARM based processors.
  15. *
  16. * @par
  17. * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
  18. * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
  19. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
  20. * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR
  21. * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
  22. *
  23. ******************************************************************************/
  24. #include "ARMSC300.h"
  25. /*----------------------------------------------------------------------------
  26. Define clocks
  27. *----------------------------------------------------------------------------*/
  28. #define __HSI ( 8000000UL)
  29. #define __XTAL ( 5000000UL) /* Oscillator frequency */
  30. #define __SYSTEM_CLOCK (5*__XTAL)
  31. /*----------------------------------------------------------------------------
  32. Clock Variable definitions
  33. *----------------------------------------------------------------------------*/
  34. uint32_t SystemCoreClock = __SYSTEM_CLOCK;/*!< System Clock Frequency (Core Clock)*/
  35. /*----------------------------------------------------------------------------
  36. Clock functions
  37. *----------------------------------------------------------------------------*/
  38. void SystemCoreClockUpdate (void) /* Get Core Clock Frequency */
  39. {
  40. SystemCoreClock = __SYSTEM_CLOCK;
  41. }
  42. /**
  43. * Initialize the system
  44. *
  45. * @param none
  46. * @return none
  47. *
  48. * @brief Setup the microcontroller system.
  49. * Initialize the System.
  50. */
  51. void SystemInit (void)
  52. {
  53. SystemCoreClock = __SYSTEM_CLOCK;
  54. }