rusEFI
The most advanced open source ECU
Loading...
Searching...
No Matches
Functions
ST

Functions

 OSAL_IRQ_HANDLER (SysTick_Handler)
 System Timer vector.
 
void st_lld_init (void)
 Low level ST driver initialization.
 
static systime_t st_lld_get_counter (void)
 Returns the time counter value.
 
static void st_lld_start_alarm (systime_t time)
 Starts the alarm.
 
static void st_lld_stop_alarm (void)
 Stops the alarm interrupt.
 
static void st_lld_set_alarm (systime_t time)
 Sets the alarm time.
 
static systime_t st_lld_get_alarm (void)
 Returns the current alarm time.
 
static bool st_lld_is_alarm_active (void)
 Determines if the alarm is active.
 

Detailed Description

Function Documentation

◆ OSAL_IRQ_HANDLER()

OSAL_IRQ_HANDLER ( SysTick_Handler  )

System Timer vector.

This interrupt is used for system tick in periodic mode.

@isr

Definition at line 61 of file hal_st_lld.c.

61 {
62
63 OSAL_IRQ_PROLOGUE();
64
65 osalSysLockFromISR();
66 osalOsTimerHandlerI();
67 osalSysUnlockFromISR();
68
69 OSAL_IRQ_EPILOGUE();
70}

◆ st_lld_get_alarm()

static systime_t st_lld_get_alarm ( void  )
inlinestatic

Returns the current alarm time.

Returns
The currently set alarm time.

@notapi

Definition at line 136 of file hal_st_lld.h.

136 {
137
138 return (systime_t)0;
139}

◆ st_lld_get_counter()

static systime_t st_lld_get_counter ( void  )
inlinestatic

Returns the time counter value.

Returns
The counter value.

@notapi

Definition at line 89 of file hal_st_lld.h.

89 {
90
91 return (systime_t)0;
92}

◆ st_lld_init()

void st_lld_init ( void  )

Low level ST driver initialization.

@notapi

Definition at line 82 of file hal_st_lld.c.

82 {
83#if OSAL_ST_MODE == OSAL_ST_MODE_PERIODIC
84 /* Periodic systick mode, the Cortex-Mx internal systick timer is used
85 in this mode.*/
86 SysTick->LOAD = (KINETIS_SYSCLK_FREQUENCY / OSAL_ST_FREQUENCY) - 1;
87 SysTick->VAL = 0;
88 SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk |
89 SysTick_CTRL_ENABLE_Msk |
90 SysTick_CTRL_TICKINT_Msk;
91
92 /* IRQ enabled.*/
93 nvicSetSystemHandlerPriority(HANDLER_SYSTICK, KINETIS_ST_IRQ_PRIORITY);
94#endif /* OSAL_ST_MODE == OSAL_ST_MODE_PERIODIC */
95}

◆ st_lld_is_alarm_active()

static bool st_lld_is_alarm_active ( void  )
inlinestatic

Determines if the alarm is active.

Returns
The alarm status.
Return values
falseif the alarm is not active.
trueis the alarm is active

@notapi

Definition at line 150 of file hal_st_lld.h.

150 {
151
152 return false;
153}

◆ st_lld_set_alarm()

static void st_lld_set_alarm ( systime_t  time)
inlinestatic

Sets the alarm time.

Parameters
[in]timethe time to be set for the next alarm

@notapi

Definition at line 124 of file hal_st_lld.h.

124 {
125
126 (void)time;
127}

◆ st_lld_start_alarm()

static void st_lld_start_alarm ( systime_t  time)
inlinestatic

Starts the alarm.

Note
Makes sure that no spurious alarms are triggered after this call.
Parameters
[in]timethe time to be set for the first alarm

@notapi

Definition at line 103 of file hal_st_lld.h.

103 {
104
105 (void)time;
106}

◆ st_lld_stop_alarm()

static void st_lld_stop_alarm ( void  )
inlinestatic

Stops the alarm interrupt.

@notapi

Definition at line 113 of file hal_st_lld.h.

113 {
114
115}