mirror of https://github.com/ARMmbed/mbed-os.git
Modify the arrangement of "{" that shows the function start
Regarding "{" that show the function start, I modified the the arrangement from right of function to new line.pull/6056/head
parent
856737cb74
commit
32ed0f7593
|
@ -31,11 +31,13 @@
|
|||
#include "MBRZA1LU.h"
|
||||
#include "irq_ctrl.h"
|
||||
|
||||
void NVIC_SetVector(IRQn_Type IRQn, uint32_t vector) {
|
||||
void NVIC_SetVector(IRQn_Type IRQn, uint32_t vector)
|
||||
{
|
||||
InterruptHandlerRegister(IRQn, (IRQHandler)vector);
|
||||
}
|
||||
|
||||
uint32_t NVIC_GetVector(IRQn_Type IRQn) {
|
||||
uint32_t NVIC_GetVector(IRQn_Type IRQn)
|
||||
{
|
||||
uint32_t vectors = (uint32_t)IRQ_GetHandler(IRQn);
|
||||
return vectors;
|
||||
}
|
||||
|
|
|
@ -213,14 +213,16 @@ uint32_t ITM_SendChar (uint32_t ch)
|
|||
}
|
||||
|
||||
|
||||
int32_t ITM_ReceiveChar (void) {
|
||||
int32_t ITM_ReceiveChar (void)
|
||||
{
|
||||
/* Not support this function */
|
||||
/* Use mbed Serial */
|
||||
return (-1); /* no character available */
|
||||
}
|
||||
|
||||
|
||||
int32_t ITM_CheckChar (void) {
|
||||
int32_t ITM_CheckChar (void)
|
||||
{
|
||||
/* Not support this function */
|
||||
/* Use mbed Serial */
|
||||
return (0); /* no character available */
|
||||
|
|
|
@ -47,7 +47,8 @@ static uint8_t OSTM_PendIRQ; // Timer interrupt pending flag
|
|||
|
||||
|
||||
// Setup OS Tick.
|
||||
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler) {
|
||||
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler)
|
||||
{
|
||||
uint32_t clock;
|
||||
uint32_t prio;
|
||||
uint32_t bits;
|
||||
|
@ -130,7 +131,8 @@ int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler) {
|
|||
}
|
||||
|
||||
/// Enable OS Tick.
|
||||
int32_t OS_Tick_Enable (void) {
|
||||
int32_t OS_Tick_Enable (void)
|
||||
{
|
||||
|
||||
if (OSTM_PendIRQ != 0U) {
|
||||
OSTM_PendIRQ = 0U;
|
||||
|
@ -158,33 +160,39 @@ int32_t OS_Tick_Disable (void) {
|
|||
}
|
||||
|
||||
// Acknowledge OS Tick IRQ.
|
||||
int32_t OS_Tick_AcknowledgeIRQ (void) {
|
||||
int32_t OS_Tick_AcknowledgeIRQ (void)
|
||||
{
|
||||
return (IRQ_ClearPending (OSTM_IRQn));
|
||||
}
|
||||
|
||||
// Get OS Tick IRQ number.
|
||||
int32_t OS_Tick_GetIRQn (void) {
|
||||
int32_t OS_Tick_GetIRQn (void)
|
||||
{
|
||||
return (OSTM_IRQn);
|
||||
}
|
||||
|
||||
// Get OS Tick clock.
|
||||
uint32_t OS_Tick_GetClock (void) {
|
||||
uint32_t OS_Tick_GetClock (void)
|
||||
{
|
||||
return (OSTM_Clock);
|
||||
}
|
||||
|
||||
// Get OS Tick interval.
|
||||
uint32_t OS_Tick_GetInterval (void) {
|
||||
uint32_t OS_Tick_GetInterval (void)
|
||||
{
|
||||
return (OSTM.OSTMnCMP + 1U);
|
||||
}
|
||||
|
||||
// Get OS Tick count value.
|
||||
uint32_t OS_Tick_GetCount (void) {
|
||||
uint32_t OS_Tick_GetCount (void)
|
||||
{
|
||||
uint32_t cmp = OSTM.OSTMnCMP;
|
||||
return (cmp - OSTM.OSTMnCNT);
|
||||
}
|
||||
|
||||
// Get OS Tick overflow status.
|
||||
uint32_t OS_Tick_GetOverflow (void) {
|
||||
uint32_t OS_Tick_GetOverflow (void)
|
||||
{
|
||||
return (IRQ_GetPending(OSTM_IRQn));
|
||||
}
|
||||
|
||||
|
|
|
@ -31,11 +31,13 @@
|
|||
#include "MBRZA1H.h"
|
||||
#include "irq_ctrl.h"
|
||||
|
||||
void NVIC_SetVector(IRQn_Type IRQn, uint32_t vector) {
|
||||
void NVIC_SetVector(IRQn_Type IRQn, uint32_t vector)
|
||||
{
|
||||
InterruptHandlerRegister(IRQn, (IRQHandler)vector);
|
||||
}
|
||||
|
||||
uint32_t NVIC_GetVector(IRQn_Type IRQn) {
|
||||
uint32_t NVIC_GetVector(IRQn_Type IRQn)
|
||||
{
|
||||
uint32_t vectors = (uint32_t)IRQ_GetHandler(IRQn);
|
||||
return vectors;
|
||||
}
|
||||
|
|
|
@ -213,14 +213,16 @@ uint32_t ITM_SendChar (uint32_t ch)
|
|||
}
|
||||
|
||||
|
||||
int32_t ITM_ReceiveChar (void) {
|
||||
int32_t ITM_ReceiveChar (void)
|
||||
{
|
||||
/* Not support this function */
|
||||
/* Use mbed Serial */
|
||||
return (-1); /* no character available */
|
||||
}
|
||||
|
||||
|
||||
int32_t ITM_CheckChar (void) {
|
||||
int32_t ITM_CheckChar (void)
|
||||
{
|
||||
/* Not support this function */
|
||||
/* Use mbed Serial */
|
||||
return (0); /* no character available */
|
||||
|
|
|
@ -47,7 +47,8 @@ static uint8_t OSTM_PendIRQ; // Timer interrupt pending flag
|
|||
|
||||
|
||||
// Setup OS Tick.
|
||||
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler) {
|
||||
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler)
|
||||
{
|
||||
uint32_t clock;
|
||||
uint32_t prio;
|
||||
uint32_t bits;
|
||||
|
@ -130,7 +131,8 @@ int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler) {
|
|||
}
|
||||
|
||||
/// Enable OS Tick.
|
||||
int32_t OS_Tick_Enable (void) {
|
||||
int32_t OS_Tick_Enable (void)
|
||||
{
|
||||
|
||||
if (OSTM_PendIRQ != 0U) {
|
||||
OSTM_PendIRQ = 0U;
|
||||
|
@ -144,7 +146,8 @@ int32_t OS_Tick_Enable (void) {
|
|||
}
|
||||
|
||||
/// Disable OS Tick.
|
||||
int32_t OS_Tick_Disable (void) {
|
||||
int32_t OS_Tick_Disable (void)
|
||||
{
|
||||
|
||||
// Stop the OSTM counter
|
||||
OSTM.OSTMnTT = 0x01U;
|
||||
|
@ -158,33 +161,39 @@ int32_t OS_Tick_Disable (void) {
|
|||
}
|
||||
|
||||
// Acknowledge OS Tick IRQ.
|
||||
int32_t OS_Tick_AcknowledgeIRQ (void) {
|
||||
int32_t OS_Tick_AcknowledgeIRQ (void)
|
||||
{
|
||||
return (IRQ_ClearPending (OSTM_IRQn));
|
||||
}
|
||||
|
||||
// Get OS Tick IRQ number.
|
||||
int32_t OS_Tick_GetIRQn (void) {
|
||||
int32_t OS_Tick_GetIRQn (void)
|
||||
{
|
||||
return (OSTM_IRQn);
|
||||
}
|
||||
|
||||
// Get OS Tick clock.
|
||||
uint32_t OS_Tick_GetClock (void) {
|
||||
uint32_t OS_Tick_GetClock (void)
|
||||
{
|
||||
return (OSTM_Clock);
|
||||
}
|
||||
|
||||
// Get OS Tick interval.
|
||||
uint32_t OS_Tick_GetInterval (void) {
|
||||
uint32_t OS_Tick_GetInterval (void)
|
||||
{
|
||||
return (OSTM.OSTMnCMP + 1U);
|
||||
}
|
||||
|
||||
// Get OS Tick count value.
|
||||
uint32_t OS_Tick_GetCount (void) {
|
||||
uint32_t OS_Tick_GetCount (void)
|
||||
{
|
||||
uint32_t cmp = OSTM.OSTMnCMP;
|
||||
return (cmp - OSTM.OSTMnCNT);
|
||||
}
|
||||
|
||||
// Get OS Tick overflow status.
|
||||
uint32_t OS_Tick_GetOverflow (void) {
|
||||
uint32_t OS_Tick_GetOverflow (void)
|
||||
{
|
||||
return (IRQ_GetPending(OSTM_IRQn));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue