ArDrone SDK 1.8 added
[mardrone] / mardrone / ARDrone_SDK_Version_1_8_20110726 / ARDroneLib / VP_SDK / VP_Com / vp_com_error.h
1 /**
2  *  \brief    Com Api for video sdk. Error handling.
3  *  \author   Sylvain Gaeremynck <sylvain.gaeremynck@parrot.fr>
4  *  \version  2.0
5  *  \date     20/12/2006
6  */
7
8 #ifndef _VP_COM_ERROR_H_
9 #define _VP_COM_ERROR_H_
10
11
12 #include <VP_Os/vp_os_error_handling.h>
13
14
15 #define VP_COM_CHECK(res) if(res != VP_COM_OK) return res
16
17 enum {
18   VP_COM_ERROR = -1,
19   VP_COM_OK = (VP_COM_SDK_SIGNATURE << 16),
20   VP_COM_UNKNOW_ERROR,
21   VP_COM_ADAPTORNOTFOUND,
22   VP_COM_PARAMERROR,
23   VP_COM_NOTSUPPORTED,
24   VP_COM_INITERROR,
25   VP_COM_ADAPTORERROR,
26   VP_COM_HOSTNOTREACHABLE,
27   VP_COM_SOCKETERROR,
28   VP_COM_NOTCONNECTED,
29   VP_COM_MAX_NUM_ERROR
30 };
31
32 const char* vp_com_formatMessage(int32_t errorCode);
33
34 #endif // _VP_COM_ERROR_H_