Revision:
3:e02ec42cf9c8
Parent:
0:0f5a52711275
--- a/LPC2368/drv/zg2100/zg_err.h	Thu Jul 22 11:31:59 2010 +0000
+++ b/LPC2368/drv/zg2100/zg_err.h	Fri Aug 06 10:42:05 2010 +0000
@@ -21,23 +21,33 @@
 THE SOFTWARE.
 */
 
-//ZG2100 Low-level driver definitions
+/**
+@file
+ZG2100 driver errors
+*/
 //Donatien Garnier 2010
 
 #ifndef ZG_ERR_H
 #define ZG_ERR_H
 
+#include "zg_defs.h"
+
+///ZG2100 Wi-Fi Module driver error codes
 typedef enum __zg_err 
 {
-  ZG_OK = 1,
-  ZG_RESOURCES = 12, //Not enough resources
-  ZG_TIMEOUT,
-  ZG_FRAME_ERROR,
-  ZG_AUTH_REFUSED,
-  ZG_ASSOC_REFUSED,
-  ZG_IN_PROGRESS,
-  ZG_SUPPLICANT_FAILED = 21
+  __ZG_MIN = -0xFFFF,
+  ZG_RESOURCES, ///< Not enough resources
+  ZG_TIMEOUT, ///< Timeout
+  ZG_FRAME_ERROR, ///< Framing error
+  ZG_AUTH_REFUSED, ///< Authentication refused
+  ZG_ASSOC_REFUSED, ///< Association refused
+  ZG_IN_PROGRESS, ///< Command is being processed
+  ZG_SUPPLICANT_FAILED, ///< Error with WPA-handling
+  ZG_UNKNOWN, ///< Unknown error
+  ZG_OK = 0 ///< Success
 
 } zg_err;
 
+zg_err zg_errcode(ZG_INT_ERR int_err); //Errcodes conversion
+
 #endif