|
arduino-audio-driver
|
All pins for i2s, spi, i2c and other pins. More...
#include <DriverDeviceInfo.h>
Public Member Functions | |
| DriverDeviceInfo ()=default | |
| DriverDeviceInfo (const DriverDeviceInfo &)=delete | |
| bool | addI2C (InfoI2C pin) |
| bool | addI2C (PinFunction function, GpioPin scl, GpioPin sda, int port=-1, uint32_t frequency=100000, i2c_bus_handle_t wire=DEFAULT_WIRE, bool active=true) |
| bool | addI2S (InfoI2S pin) |
| bool | addI2S (PinFunction function, GpioPin mclk, GpioPin bck, GpioPin ws, GpioPin data_out, GpioPin data_in=-1, int port=0) |
| bool | addPin (InfoGPIO pin) |
| bool | addPin (PinFunction function, GpioPin pinNo, PinLogic logic, int index=0) |
| bool | addSPI (InfoSPI pin) |
| bool | addSPI (PinFunction function, GpioPin clk, GpioPin miso, GpioPin mosi, GpioPin cs, SPIClass &spi) |
| virtual bool | begin () |
| Sets up all pins e.g. by calling pinMode() | |
| void | end () |
| API_GPIO & | getGPIO () |
| audio_driver_local::Optional< InfoI2C > | getI2CPins (PinFunction function) override |
| Finds the I2C pin info with the help of the function. | |
| audio_driver_local::Optional< InfoI2S > | getI2SPins (int port) |
| Finds the I2S pin info with the help of the port. | |
| audio_driver_local::Optional< InfoI2S > | getI2SPins (PinFunction function=PinFunction::CODEC) |
| Finds the I2S pin info with the help of the function. | |
| audio_driver_local::Optional< InfoGPIO > | getPin (GpioPin pinId) |
| Get pin information by pin ID. | |
| audio_driver_local::Optional< InfoGPIO > | getPin (PinFunction function, int pos=0) |
| Get pin information by function. | |
| GpioPin | getPinID (PinFunction function, int pos=0) |
| audio_driver_local::Optional< InfoSPI > | getSPIPins (PinFunction function) |
| Finds the SPI pin info with the help of the function. | |
| bool | hasPins () |
| Returns true if some function pins have been defined. | |
| virtual bool | isKeyPressed (uint8_t key) |
| returns true if pressed | |
| bool | isSDMMCActive () |
| Check if SDMMC has been activated. | |
| bool | isSPIActiveForSD () |
| Check if SPI for SD should be started automatically. | |
| DriverDeviceInfo & | operator= (const DriverDeviceInfo &)=delete |
| bool | setI2C (InfoI2C pin) |
| Updates the I2C pin information using the function as key. | |
| bool | setI2S (InfoI2S pin) |
| Updates the I2S pin information using the function as key. | |
| bool | setPin (InfoGPIO updatedPin) |
| Updates an existing pin information using the function and index as key. | |
| bool | setPinActive (int gpioPin, bool active) |
| Updates an existing pin active flag for the indicated gpio. | |
| bool | setPinActive (PinFunction func, int idx, bool active) |
| Updates an existing pin active flag for the indicated gpio. | |
| void | setSDMMCActive (bool active) |
| Defines if SPI for SD should be started (by default true) | |
| bool | setSPI (InfoSPI pin) |
| Updates the SPI pin information using the function as key. | |
| void | setSPIActiveForSD (bool active) |
| Defines if SPI for SD should be started (by default true) | |
Protected Member Functions | |
| template<typename T > | |
| T * | getPtr (PinFunction function, audio_driver_local::Vector< T > &vect) |
| bool | hasConflict (int pin) |
| bool | hasI2CConflict (int pin) |
| bool | hasSPIConflict (int pin) |
| template<typename T > | |
| bool | set (T pin, audio_driver_local::Vector< T > &vect) |
| void | setupPinMode () |
Protected Attributes | |
| GPIOExt | gpio |
| audio_driver_local::Vector< InfoI2C > | i2c {0} |
| audio_driver_local::Vector< InfoI2S > | i2s {0} |
| audio_driver_local::Vector< InfoGPIO > | pins {0} |
| bool | sd_active = false |
| bool | sdmmc_active = false |
| audio_driver_local::Vector< InfoSPI > | spi {0} |
All pins for i2s, spi, i2c and other pins.
|
delete |
|
default |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinevirtual |
Sets up all pins e.g. by calling pinMode()
Reimplemented in PinsESP32S3AISmartSpeakerClass.
|
inline |
|
inline |
|
inlineoverridevirtual |
Finds the I2C pin info with the help of the function.
Implements IDriverDeviceInfo.
|
inline |
Finds the I2S pin info with the help of the port.
|
inline |
Finds the I2S pin info with the help of the function.
|
inline |
Get pin information by pin ID.
|
inline |
Get pin information by function.
|
inline |
|
inlineprotected |
|
inline |
Finds the SPI pin info with the help of the function.
|
inlineprotected |
|
inlineprotected |
|
inline |
Returns true if some function pins have been defined.
|
inlineprotected |
|
inlinevirtual |
returns true if pressed
Reimplemented in PinsLyratMiniClass.
|
inline |
Check if SDMMC has been activated.
|
inline |
Check if SPI for SD should be started automatically.
|
delete |
|
inlineprotected |
|
inline |
Updates the I2C pin information using the function as key.
|
inline |
Updates the I2S pin information using the function as key.
|
inline |
Updates an existing pin information using the function and index as key.
|
inline |
Updates an existing pin active flag for the indicated gpio.
|
inline |
Updates an existing pin active flag for the indicated gpio.
|
inline |
Defines if SPI for SD should be started (by default true)
|
inline |
Updates the SPI pin information using the function as key.
|
inline |
Defines if SPI for SD should be started (by default true)
|
inlineprotected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |