@@ -30,14 +30,31 @@ I2S(INPUT)
30
30
Creates an I2S input port. Needs to be connected up to the
31
31
desired pins (see below) and started before any input can happen.
32
32
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
+
33
39
bool setBCLK(pin_size_t pin)
34
40
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
35
41
Sets the BCLK pin of the I2S device. The LRCLK/word clock will be ``pin + 1 ``
36
42
due to limitations of the PIO state machines. Call this before ``I2S::begin() ``
37
43
38
44
bool setDATA(pin_size_t pin)
39
45
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
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.
41
58
Call before ``I2S::begin() ``
42
59
43
60
bool setMCLK(pin_size_t pin)
@@ -115,6 +132,14 @@ void getOverUnderflow()
115
132
Returns a flag indicating if the I2S system ran our of data to send on output,
116
133
or had to throw away data on input.
117
134
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
+
118
143
size_t write(uint8_t/int8_t/int16_t/int32_t)
119
144
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
120
145
Writes a single sample of ``bitsPerSample `` to the buffer. It is up to the
0 commit comments