rtos cortex: fix astyle

pull/8365/head
Martin Kojtal 2018-10-10 15:26:50 -05:00
parent f90f1fc01d
commit e80f2ff18a
4 changed files with 17 additions and 14 deletions

View File

@ -121,7 +121,7 @@ static void mbed_cpy_nvic(void)
#if !defined(__CORTEX_M0) && !defined(__CORTEX_A9) #if !defined(__CORTEX_M0) && !defined(__CORTEX_A9)
#ifdef NVIC_RAM_VECTOR_ADDRESS #ifdef NVIC_RAM_VECTOR_ADDRESS
uint32_t *old_vectors = (uint32_t *)SCB->VTOR; uint32_t *old_vectors = (uint32_t *)SCB->VTOR;
uint32_t *vectors = (uint32_t*)NVIC_RAM_VECTOR_ADDRESS; uint32_t *vectors = (uint32_t *)NVIC_RAM_VECTOR_ADDRESS;
for (int i = 0; i < NVIC_NUM_VECTORS; i++) { for (int i = 0; i < NVIC_NUM_VECTORS; i++) {
vectors[i] = old_vectors[i]; vectors[i] = old_vectors[i];
} }

View File

@ -51,7 +51,7 @@ extern "C" {
/* Define stack sizes if they haven't been set already */ /* Define stack sizes if they haven't been set already */
#if !defined(ISR_STACK_SIZE) #if !defined(ISR_STACK_SIZE)
#define ISR_STACK_SIZE ((uint32_t)1024) #define ISR_STACK_SIZE ((uint32_t)1024)
#endif #endif
/* Heap limits - only used if set */ /* Heap limits - only used if set */

View File

@ -42,7 +42,7 @@ static rtos::internal::SysTimer *os_timer;
static uint64_t os_timer_data[sizeof(rtos::internal::SysTimer) / 8]; static uint64_t os_timer_data[sizeof(rtos::internal::SysTimer) / 8];
/// Enable System Timer. /// Enable System Timer.
void OS_Tick_Enable (void) void OS_Tick_Enable(void)
{ {
// Do not use SingletonPtr since this relies on the RTOS // Do not use SingletonPtr since this relies on the RTOS
if (NULL == os_timer) { if (NULL == os_timer) {
@ -55,35 +55,38 @@ void OS_Tick_Enable (void)
} }
/// Disable System Timer. /// Disable System Timer.
void OS_Tick_Disable (void) void OS_Tick_Disable(void)
{ {
os_timer->cancel_tick(); os_timer->cancel_tick();
} }
/// Acknowledge System Timer IRQ. /// Acknowledge System Timer IRQ.
void OS_Tick_AcknowledgeIRQ (void) void OS_Tick_AcknowledgeIRQ(void)
{ {
} }
/// Get System Timer count. /// Get System Timer count.
uint32_t OS_Tick_GetCount (void) uint32_t OS_Tick_GetCount(void)
{ {
return os_timer->get_time() & 0xFFFFFFFF; return os_timer->get_time() & 0xFFFFFFFF;
} }
// Get OS Tick IRQ number. // Get OS Tick IRQ number.
int32_t OS_Tick_GetIRQn (void) { int32_t OS_Tick_GetIRQn(void)
{
return -1; return -1;
} }
// Get OS Tick overflow status. // Get OS Tick overflow status.
uint32_t OS_Tick_GetOverflow (void) { uint32_t OS_Tick_GetOverflow(void)
{
return 0; return 0;
} }
// Get OS Tick interval. // Get OS Tick interval.
uint32_t OS_Tick_GetInterval (void) { uint32_t OS_Tick_GetInterval(void)
{
return 1000; return 1000;
} }