Arduino PulseWire Transceiver Library
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes
pulsewire::RxDriverInt Class Referenceabstract

Interrupt-capable IR RX driver interface for platforms without attachInterruptArg. More...

#include <RxDriverArduino.h>

Inheritance diagram for pulsewire::RxDriverInt:
Inheritance graph
[legend]
Collaboration diagram for pulsewire::RxDriverInt:
Collaboration graph
[legend]

Public Member Functions

virtual void handleInterrupt ()=0
 
virtual void setFrameSize (uint16_t size)=0
 Set the expected frame size for dynamic data reception.
 
virtual bool begin (uint32_t bitFrequencyHz)=0
 Start the receiver.
 
virtual void end ()=0
 Stop the receiver.
 
virtual size_t readBytes (uint8_t *data, size_t size)=0
 
virtual int available ()=0
 Get the number of bytes available in the internal buffer.
 
virtual void setRxBufferSize (size_t size)=0
 Set the size of the internal RX buffer.
 
void setTimeout (uint32_t timeoutMs)
 Defines the read timeout for readBytes() in milliseconds.
 

Protected Attributes

uint32_t _readTimeoutMs = 50
 

Detailed Description

Interrupt-capable IR RX driver interface for platforms without attachInterruptArg.

This class extends RxDriver with a pure virtual method handleInterrupt(), which must be implemented by derived classes to handle the interrupt logic. It is used in conjunction with ISRManager to manage multiple ISR instances on platforms that do not support attachInterruptArg (e.g., AVR).

Definition at line 23 of file RxDriverArduino.h.

Member Function Documentation

◆ available()

virtual int pulsewire::RxDriver::available ( )
pure virtualinherited

Get the number of bytes available in the internal buffer.

Implemented in pulsewire::RxDriverArduino, pulsewire::RxDriverESP32, and pulsewire::RxDriverRP2040.

◆ begin()

virtual bool pulsewire::RxDriver::begin ( uint32_t  bitFrequencyHz)
pure virtualinherited

Start the receiver.

Implemented in pulsewire::RxDriverESP32, and pulsewire::RxDriverArduino.

◆ end()

virtual void pulsewire::RxDriver::end ( )
pure virtualinherited

Stop the receiver.

Implemented in pulsewire::RxDriverArduino, and pulsewire::RxDriverESP32.

◆ readBytes()

virtual size_t pulsewire::RxDriver::readBytes ( uint8_t data,
size_t  size 
)
pure virtualinherited

Read up to 'size' bytes from the internal buffer into 'data'. Returns number of bytes read.

Implemented in pulsewire::RxDriverArduino, pulsewire::RxDriverESP32, and pulsewire::RxDriverRP2040.

◆ setFrameSize()

virtual void pulsewire::RxDriver::setFrameSize ( uint16_t  size)
pure virtualinherited

Set the expected frame size for dynamic data reception.

Implemented in pulsewire::RxDriverArduino, pulsewire::RxDriverESP32, and pulsewire::RxDriverRP2040.

◆ setRxBufferSize()

virtual void pulsewire::RxDriver::setRxBufferSize ( size_t  size)
pure virtualinherited

Set the size of the internal RX buffer.

Implemented in pulsewire::RxDriverArduino, and pulsewire::RxDriverESP32.

◆ setTimeout()

void pulsewire::RxDriver::setTimeout ( uint32_t  timeoutMs)
inlineinherited

Defines the read timeout for readBytes() in milliseconds.

Definition at line 26 of file RxDriver.h.

Field Documentation

◆ _readTimeoutMs

uint32_t pulsewire::RxDriver::_readTimeoutMs = 50
protectedinherited

Definition at line 29 of file RxDriver.h.


The documentation for this class was generated from the following file: