ist8310: remove undef

Use PX4_ERROR instead.
This commit is contained in:
Lucas De Marchi 2017-03-22 15:10:26 -07:00 committed by Lorenz Meier
parent 04dac46eaf
commit 366ff1f3e9

View File

@ -41,6 +41,7 @@
*/
#include <px4_config.h>
#include <px4_defines.h>
#include <sys/types.h>
#include <stdint.h>
@ -178,12 +179,6 @@ enum IST8310_BUS {
IST8310_BUS_I2C_INTERNAL = 2,
};
/* oddly, ERROR is not defined for c++ */
#ifdef ERROR
# undef ERROR
#endif
static const int ERROR = -1;
#ifndef CONFIG_SCHED_WORKQUEUE
# error This requires CONFIG_SCHED_WORKQUEUE.
#endif
@ -458,7 +453,7 @@ IST8310::~IST8310()
int
IST8310::init()
{
int ret = ERROR;
int ret = PX4_ERROR;
ret = I2C::init();
@ -1143,7 +1138,7 @@ out:
if (check_scale()) {
/* failed */
PX4_WARN("FAILED: SCALE");
ret = ERROR;
ret = PX4_ERROR;
}
}
@ -1271,12 +1266,6 @@ IST8310::print_info()
namespace ist8310
{
/* oddly, ERROR is not defined for c++ */
#ifdef ERROR
# undef ERROR
#endif
const int ERROR = -1;
/*
list of supported bus configurations
*/