mirror of https://github.com/ARMmbed/mbed-os.git
Implement SystemcoreClock
We implemented SystemcoreClock which is defined in CMSIS.pull/1848/head
parent
bddce7ce7e
commit
1e2e14e11d
|
@ -51,6 +51,7 @@ void FPUEnable(void);
|
||||||
|
|
||||||
uint32_t IRQNestLevel;
|
uint32_t IRQNestLevel;
|
||||||
unsigned char seen_id0_active = 0; // single byte to hold a flag used in the workaround for GIC errata 733075
|
unsigned char seen_id0_active = 0; // single byte to hold a flag used in the workaround for GIC errata 733075
|
||||||
|
uint32_t SystemCoreClock = CM0_RENESAS_RZ_A1_I_CLK; /*!< System Clock Frequency (Core Clock) */
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -198,6 +199,20 @@ uint32_t InterruptHandlerUnregister (IRQn_Type irq)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update SystemCoreClock variable
|
||||||
|
*
|
||||||
|
* @param none
|
||||||
|
* @return none
|
||||||
|
*
|
||||||
|
* @brief Updates the SystemCoreClock with current core Clock.
|
||||||
|
*/
|
||||||
|
void SystemCoreClockUpdate (void)
|
||||||
|
{
|
||||||
|
SystemCoreClock = CM0_RENESAS_RZ_A1_I_CLK;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize the system
|
* Initialize the system
|
||||||
*
|
*
|
||||||
|
|
|
@ -43,6 +43,8 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
|
||||||
|
|
||||||
typedef void(*IRQHandler)();
|
typedef void(*IRQHandler)();
|
||||||
uint32_t InterruptHandlerRegister(IRQn_Type, IRQHandler);
|
uint32_t InterruptHandlerRegister(IRQn_Type, IRQHandler);
|
||||||
uint32_t InterruptHandlerUnregister(IRQn_Type);
|
uint32_t InterruptHandlerUnregister(IRQn_Type);
|
||||||
|
|
|
@ -51,6 +51,7 @@ void FPUEnable(void);
|
||||||
|
|
||||||
uint32_t IRQNestLevel;
|
uint32_t IRQNestLevel;
|
||||||
unsigned char seen_id0_active = 0; // single byte to hold a flag used in the workaround for GIC errata 733075
|
unsigned char seen_id0_active = 0; // single byte to hold a flag used in the workaround for GIC errata 733075
|
||||||
|
uint32_t SystemCoreClock = CM0_RENESAS_RZ_A1_I_CLK; /*!< System Clock Frequency (Core Clock) */
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -198,6 +199,20 @@ uint32_t InterruptHandlerUnregister (IRQn_Type irq)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update SystemCoreClock variable
|
||||||
|
*
|
||||||
|
* @param none
|
||||||
|
* @return none
|
||||||
|
*
|
||||||
|
* @brief Updates the SystemCoreClock with current core Clock.
|
||||||
|
*/
|
||||||
|
void SystemCoreClockUpdate (void)
|
||||||
|
{
|
||||||
|
SystemCoreClock = CM0_RENESAS_RZ_A1_I_CLK;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize the system
|
* Initialize the system
|
||||||
*
|
*
|
||||||
|
|
|
@ -43,6 +43,8 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
|
||||||
|
|
||||||
typedef void(*IRQHandler)();
|
typedef void(*IRQHandler)();
|
||||||
uint32_t InterruptHandlerRegister(IRQn_Type, IRQHandler);
|
uint32_t InterruptHandlerRegister(IRQn_Type, IRQHandler);
|
||||||
uint32_t InterruptHandlerUnregister(IRQn_Type);
|
uint32_t InterruptHandlerUnregister(IRQn_Type);
|
||||||
|
|
Loading…
Reference in New Issue