mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-21 10:26:06 +03:00
ETS_INTR_ENABLED & ETS_INT_PENDING as inline
This commit is contained in:
parent
8393dfcc8f
commit
95da465eb7
@ -73,12 +73,14 @@ typedef void (*int_handler_t)(void*);
|
||||
#define ETS_INTR_DISABLE(inum) \
|
||||
ets_isr_mask((1<<inum))
|
||||
|
||||
inline uint32_t ETS_INTR_ENABLED(void)
|
||||
{
|
||||
uint32_t enabled;
|
||||
__asm__ __volatile__("esync; rsr %0,intenable":"=a" (enabled));
|
||||
return enabled;
|
||||
}
|
||||
|
||||
inline uint32_t ETS_INTR_PENDING(void)
|
||||
{
|
||||
uint32_t pending;
|
||||
__asm__ __volatile__("esync; rsr %0,interrupt":"=a" (pending));
|
||||
|
Loading…
x
Reference in New Issue
Block a user