@@ -30,14 +30,31 @@ I2S(INPUT)
3030Creates an I2S input port. Needs to be connected up to the
3131desired pins (see below) and started before any input can happen.
3232
33+ I2S(INPUT_PULLUP)
34+ ~~~~~~~~~~~~~~~~~
35+ Creates a bi-directional I2S input and output port. Needs to be
36+ connected up to the desired pins (see below) and started before
37+ any input or output can happen.
38+
3339bool setBCLK(pin_size_t pin)
3440~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3541Sets the BCLK pin of the I2S device. The LRCLK/word clock will be ``pin + 1 ``
3642due to limitations of the PIO state machines. Call this before ``I2S::begin() ``
3743
3844bool setDATA(pin_size_t pin)
3945~~~~~~~~~~~~~~~~~~~~~~~~~~~~
40- Sets the DOUT or DIN pin of the I2S device. Any pin may be used.
46+ Sets the DOUT or DIN pin of the I2S device. Any pin may be used. In bi-directional
47+ operation, must use ``I2S::setDOUT() `` and ``I2S::setDIN `` instead.
48+ Call before ``I2S::begin() ``
49+
50+ bool setDOUT(pin_size_t pin)
51+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
52+ Sets the DOUT pin of the I2S device. Any pin may be used.
53+ Call before ``I2S::begin() ``
54+
55+ bool setDIN(pin_size_t pin)
56+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
57+ Sets the DIN pin of the I2S device. Any pin may be used.
4158Call before ``I2S::begin() ``
4259
4360bool setMCLK(pin_size_t pin)
@@ -115,6 +132,14 @@ void getOverUnderflow()
115132Returns a flag indicating if the I2S system ran our of data to send on output,
116133or had to throw away data on input.
117134
135+ void getOverflow()
136+ ~~~~~~~~~~~~~~~~~~~~~~~
137+ Returns a flag indicating if the I2S system had to throw away data on input.
138+
139+ void getUnderflow()
140+ ~~~~~~~~~~~~~~~~~~~~~~~
141+ Returns a flag indicating if the I2S system ran our of data to send on output.
142+
118143size_t write(uint8_t/int8_t/int16_t/int32_t)
119144~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
120145Writes a single sample of ``bitsPerSample `` to the buffer. It is up to the
0 commit comments