|
arduino-audio-tools
|
Basic I2S API - for the Arduino Nano BLE Sense See https://content.arduino.cc/assets/Nano_BLE_MCU-nRF52840_PS_v1.1.pdf Douplex mode (RXTX_MODE) is currently not supported, but it should be quite easy to implement. More...
#include <I2SDriverNanoSenseBLE.h>
Public Member Functions | |
| I2SDriverNanoBLE ()=default | |
| int | available () |
| int | availableForWrite () |
| virtual bool | begin (I2SConfig cfg)=0 |
| bool | begin (I2SConfigStd cfg) |
| starts the I2S | |
| bool | begin (RxTxMode mode=TX_MODE) |
| starts the I2S with the default config in TX Mode | |
| void | clearStream () |
| Deactivate alternative API: don't forget to call begin() | |
| I2SConfigStd | config () |
| provides the actual configuration | |
| I2SConfigStd | defaultConfig (RxTxMode mode) |
| Provides the default configuration. | |
| void | end () |
| stops the I2S | |
| size_t | readBytes (void *dest, size_t size_bytes) |
| reads the data from the I2S buffer | |
| bool | setAudioInfo (AudioInfo) |
| Potentially updates the sample rate (if supported) | |
| void | setBufferSize (int size) |
| void | setStream (Stream &stream) |
| alternative API which provides the data directly via a Stream | |
| size_t | writeBytes (const void *src, size_t size_bytes) |
| writes the data to the I2S buffer | |
Protected Member Functions | |
| int | digitalPinToPinName (int pin) |
| unsigned long | getINTENSET () |
| Determine the INTENSET value. | |
| int | getPinName (int pin) |
| Provides the arduino or unconverted pin name. | |
| void | releaseBuffers () |
| Release buffers. | |
| void | setupBitWidth (I2SConfigStd cfg) |
| setup SWIDTH | |
| bool | setupBuffers () |
| dynamic buffer management | |
| void | setupClock (I2SConfigStd cfg) |
| setup MCKFREQ and RATIO | |
| void | setupMode (I2SConfigStd cfg) |
| setup format and align | |
| void | setupPins (I2SConfigStd cfg) |
| setup pins | |
| bool | setupRxTx (I2SConfigStd cfg) |
| setup TXEN or RXEN | |
| void | startI2SActive () |
| Start IRQ and I2S. | |
Protected Attributes | |
| I2SConfigStd | cfg |
| bool | is_active = false |
Friends | |
| class | I2SStream |
Basic I2S API - for the Arduino Nano BLE Sense See https://content.arduino.cc/assets/Nano_BLE_MCU-nRF52840_PS_v1.1.pdf Douplex mode (RXTX_MODE) is currently not supported, but it should be quite easy to implement.
|
default |
|
inlinevirtual |
Implements I2SDriverBase.
|
inlinevirtual |
Implements I2SDriverBase.
Implemented in I2SDriverESP32.
|
inline |
starts the I2S
|
inlinevirtual |
provides the actual configuration
Implements I2SDriverBase.
|
inlinevirtual |
Provides the default configuration.
Implements I2SDriverBase.
|
inlinevirtual |
stops the I2S
Implements I2SDriverBase.
reads the data from the I2S buffer
Implements I2SDriverBase.
|
inlineprotected |
Release buffers.
Potentially updates the sample rate (if supported)
Implements I2SDriverBase.
alternative API which provides the data directly via a Stream
|
inlineprotected |
setup SWIDTH
|
inlineprotected |
dynamic buffer management
|
inlineprotected |
setup MCKFREQ and RATIO
|
inlineprotected |
setup format and align
|
inlineprotected |
setup pins
|
inlineprotected |
setup TXEN or RXEN
|
inlineprotected |
Start IRQ and I2S.
writes the data to the I2S buffer
Implements I2SDriverBase.
|
protected |