diff --git a/src/util/inv_mpu.c b/src/util/inv_mpu.c index 0410390..79b89d9 100644 --- a/src/util/inv_mpu.c +++ b/src/util/inv_mpu.c @@ -24,6 +24,14 @@ #include #include "inv_mpu.h" +#ifdef ESP32 +#define min(a,b) ((a)<(b)?(a):(b)) +#endif + +#ifdef ESP8266 +#define min(a,b) ((a)<(b)?(a):(b)) +#endif + /* The following functions must be defined for this platform: * i2c_write(unsigned char slave_addr, unsigned char reg_addr, * unsigned char length, unsigned char const *data)