Skip to content

Commit ee7db6a

Browse files
sandeepmistrycmaglie
authored andcommitted
Change return value of I2S:: availableForWrite to match new Print API
1 parent 3d51b54 commit ee7db6a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libraries/I2S/src/I2S.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ size_t I2SClass::write(const uint8_t *buffer, size_t size)
280280
return write((const void*)buffer, size);
281281
}
282282

283-
size_t I2SClass::availableForWrite()
283+
int I2SClass::availableForWrite()
284284
{
285285
if (_state != I2S_STATE_TRANSMITTER) {
286286
enableTransmitter();

libraries/I2S/src/I2S.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ class I2SClass : public Stream
5151
virtual size_t write(uint8_t);
5252
virtual size_t write(const uint8_t *buffer, size_t size);
5353

54-
virtual size_t availableForWrite();
54+
virtual int availableForWrite();
5555

5656
int read(void* buffer, size_t size);
5757

0 commit comments

Comments
 (0)