IRremoteIDF
Infrared send & receive for ESP-IDF
Loading...
Searching...
No Matches
Functions
IRplatform.cpp File Reference

Functions

uint32_t IRAM_ATTR irMicros (void)
 Microseconds since boot. Wraps every ~71.6 minutes.
 
uint32_t irMillis (void)
 Milliseconds since boot. Wraps every ~49.7 days, like Arduino's millis().
 
void IRAM_ATTR irDelayUs (uint32_t usec)
 Busy-wait. Accurate, but blocks the core it runs on.
 
void irDelayMs (uint32_t msec)
 Sleep, yielding the CPU to other FreeRTOS tasks.
 
void irYield (void)
 Feed the task watchdog without giving up the CPU for long.
 
bool irGpioOutput (uint16_t pin)
 Configure a GPIO as a push-pull output.
 
bool irGpioInput (uint16_t pin, bool pullup)
 Configure a GPIO as an input, optionally with the internal pull-up.
 
void IRAM_ATTR irGpioWrite (uint16_t pin, uint8_t level)
 Set the level of an output GPIO.
 
uint8_t IRAM_ATTR irGpioRead (uint16_t pin)
 Read the level of a GPIO.
 
void irRestart (void)
 Reboot the chip. Used when a buffer allocation fails.
 
void irDebugPrint (const char *str)
 
void irDebugPrint (const String &str)
 
void irDebugPrint (char c)
 
void irDebugPrint (uint64_t value)
 
void irDebugPrint (int64_t value)
 

Function Documentation

◆ irDebugPrint() [1/5]

void irDebugPrint ( char  c)

◆ irDebugPrint() [2/5]

void irDebugPrint ( const char *  str)

◆ irDebugPrint() [3/5]

void irDebugPrint ( const String &  str)

◆ irDebugPrint() [4/5]

void irDebugPrint ( int64_t  value)

◆ irDebugPrint() [5/5]

void irDebugPrint ( uint64_t  value)

◆ irDelayMs()

void irDelayMs ( uint32_t  msec)

Sleep, yielding the CPU to other FreeRTOS tasks.

◆ irDelayUs()

void IRAM_ATTR irDelayUs ( uint32_t  usec)

Busy-wait. Accurate, but blocks the core it runs on.

◆ irGpioInput()

bool irGpioInput ( uint16_t  pin,
bool  pullup 
)

Configure a GPIO as an input, optionally with the internal pull-up.

Returns
true on success.

◆ irGpioOutput()

bool irGpioOutput ( uint16_t  pin)

Configure a GPIO as a push-pull output.

Returns
true on success.

◆ irGpioRead()

uint8_t IRAM_ATTR irGpioRead ( uint16_t  pin)

Read the level of a GPIO.

◆ irGpioWrite()

void IRAM_ATTR irGpioWrite ( uint16_t  pin,
uint8_t  level 
)

Set the level of an output GPIO.

◆ irMicros()

uint32_t IRAM_ATTR irMicros ( void  )

Microseconds since boot. Wraps every ~71.6 minutes.

◆ irMillis()

uint32_t irMillis ( void  )

Milliseconds since boot. Wraps every ~49.7 days, like Arduino's millis().

◆ irRestart()

void irRestart ( void  )

Reboot the chip. Used when a buffer allocation fails.

◆ irYield()

void irYield ( void  )

Feed the task watchdog without giving up the CPU for long.