diff --git a/src/BAAudioControlWM8731.cpp b/src/BAAudioControlWM8731.cpp index e506ee5..f5b2ae4 100644 --- a/src/BAAudioControlWM8731.cpp +++ b/src/BAAudioControlWM8731.cpp @@ -315,9 +315,9 @@ void BAAudioControlWM8731::resetCodec(void) } // Direct write control to the codec -void BAAudioControlWM8731::writeI2C(unsigned int addr, unsigned int val) +bool BAAudioControlWM8731::writeI2C(unsigned int addr, unsigned int val) { - write(addr, val); + return write(addr, val); } // Low level write control for the codec via the Teensy I2C interface diff --git a/src/BAAudioControlWM8731.h b/src/BAAudioControlWM8731.h index a43560d..af00261 100644 --- a/src/BAAudioControlWM8731.h +++ b/src/BAAudioControlWM8731.h @@ -110,7 +110,7 @@ public: /// @details See WM8731 datasheet for register map details. /// @param addr The register address you wish to write to, range 0 to 15. /// @param val the 9-bit data value you wish to write at the address specifed. - void writeI2C(unsigned int addr, unsigned int val); + bool writeI2C(unsigned int addr, unsigned int val); protected: // A shadow array for the registers on the codec since the interface is write-only.