diff --git a/api/mraa/types.h b/api/mraa/types.h index 6d954ceca..d588119f1 100644 --- a/api/mraa/types.h +++ b/api/mraa/types.h @@ -206,7 +206,6 @@ typedef enum { MRAA_ERROR_NO_DATA_AVAILABLE = 9, /**< No data available */ MRAA_ERROR_INVALID_PLATFORM = 10, /**< Platform not recognised */ MRAA_ERROR_PLATFORM_NOT_INITIALISED = 11, /**< Board information not initialised */ - MRAA_ERROR_PLATFORM_ALREADY_INITIALISED = 0, /**< Board is already initialised, same as MRAA_SUCESS */ MRAA_ERROR_UART_OW_SHORTED = 12, /**< UART OW Short Circuit Detected*/ MRAA_ERROR_UART_OW_NO_DEVICES = 13, /**< UART OW No devices detected */ MRAA_ERROR_UART_OW_DATA_ERROR = 14, /**< UART OW Data/Bus error detected */ diff --git a/api/mraa/types.hpp b/api/mraa/types.hpp index 19feb11d4..a1c936f4f 100644 --- a/api/mraa/types.hpp +++ b/api/mraa/types.hpp @@ -204,7 +204,6 @@ typedef enum { ERROR_NO_DATA_AVAILABLE = 9, /**< No data available */ ERROR_INVALID_PLATFORM = 10, /**< Platform not recognised */ ERROR_PLATFORM_NOT_INITIALISED = 11, /**< Board information not initialised */ - ERROR_PLATFORM_ALREADY_INITIALISED = 0, /**< Board is already initialised, same as SUCCESS */ ERROR_UART_OW_SHORTED = 12, /**< UART OW Short Circuit Detected*/ ERROR_UART_OW_NO_DEVICES = 13, /**< UART OW No devices detected */ ERROR_UART_OW_DATA_ERROR = 14, /**< UART OW Data/Bus error detected */ diff --git a/src/mraa.c b/src/mraa.c index 0bfbe111a..fc0401617 100644 --- a/src/mraa.c +++ b/src/mraa.c @@ -90,7 +90,7 @@ mraa_result_t imraa_init() { if (plat != NULL) { - return MRAA_ERROR_PLATFORM_ALREADY_INITIALISED; + return MRAA_SUCCESS; } uid_t proc_euid = geteuid(); @@ -187,7 +187,7 @@ mraa_result_t __attribute__((constructor)) mraa_init() { if (plat != NULL) { - return MRAA_ERROR_PLATFORM_ALREADY_INITIALISED; + return MRAA_SUCCESS; } else { return imraa_init(); }