semf
stm32criticalsection.cpp
Go to the documentation of this file.
1
11
#include <
semf/hardwareabstraction/stm32/stm32criticalsection.h
>
12
#include <
semf/utils/core/debug.h
>
13
14
#if defined(STM32)
15
namespace
semf
16
{
17
void
Stm32CriticalSection::halEnter
()
18
{
19
SEMF_INFO
(
"will enter now"
);
20
do
21
{
22
if
(m_criticalCount++ == 0)
23
{
24
__disable_irq();
25
}
26
}
while
(0);
27
}
28
29
void
Stm32CriticalSection::halExit
()
30
{
31
do
32
{
33
if
(--m_criticalCount == 0)
34
{
35
__enable_irq();
36
}
37
}
while
(0);
38
SEMF_INFO
(
"left"
);
39
}
40
}
/* namespace semf */
41
#endif
semf::Stm32CriticalSection::halExit
void halExit() override
Definition:
stm32criticalsection.cpp:29
semf::Stm32CriticalSection::halEnter
void halEnter() override
Definition:
stm32criticalsection.cpp:17
debug.h
SEMF_INFO
#define SEMF_INFO(...)
Definition:
debug.h:41
semf
Definition:
batterymodelwithoutdataset.h:18
stm32criticalsection.h
semf
hardwareabstraction
stm32
stm32criticalsection.cpp
Generated by
1.9.4