upl_err.h File Reference

Copyright (c) 2006, All Contributing Authors. More...

#include <string>

Go to the source code of this file.

Data Structures

struct  sUplErrCodes

Typedefs

typedef enum UplErrCodes UPL_ERR_CODES
 Error Codes for the USBP Lib.
typedef sUplErrCodes UPL_ERR_CODES_STR

Enumerations

enum  UplErrCodes {
  UPL_OK = 0, UPL_ERR = -1, UPL_FNF = -2, UPL_USB_ERR = -2000,
  UPL_USB_FNA = -2001, UPL_USB_NA = -2002, UPL_USB_OPEN_FAILED = -2003
}
 Error Codes for the USBP Lib. More...

Variables

const UPL_ERR_CODES_STR err_code_str []
 NOTE! Not necissarily in order, ie err_code_str[100] may not equal error code 100 use the lookup function (TBD).


Detailed Description

Copyright (c) 2006, All Contributing Authors.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

This file simply contains an enumeration of error codes and description strings.

UPL was used instead of USBP, slightly shorter (D'OH), USB Prototype Library Universal Prototype Library USB Pancake Lotto etc.

Definition in file upl_err.h.


Typedef Documentation

typedef enum UplErrCodes UPL_ERR_CODES

Error Codes for the USBP Lib.

This files extends past column 80, if printing print in landscape format!.

typedef struct sUplErrCodes UPL_ERR_CODES_STR


Enumeration Type Documentation

enum UplErrCodes

Error Codes for the USBP Lib.

This files extends past column 80, if printing print in landscape format!.

Enumerator:
UPL_OK  All is ok.
UPL_ERR  Generic, try not and use.
UPL_FNF  File Not Found, tried to access a file that didn't exist.
UPL_USB_ERR  Catch all error code, try not and use.
UPL_USB_FNA  Function not implemented for this driver.
UPL_USB_NA  USB Device Not Available.
UPL_USB_OPEN_FAILED  Failed to open the USB device.

Definition at line 49 of file upl_err.h.


Variable Documentation

const UPL_ERR_CODES_STR err_code_str[]

Initial value:

  {
    {UPL_OK,                      "All is Good"},
    {UPL_FNF,                     "File Not Found"},
    
    {UPL_USB_ERR,                 "Generic USB error, sorry lamo didn't provice more info"},
    {UPL_USB_FNA,                 "Function (method) not implemented for this driver (for a particular implementation of CPugUsb abstract class"},
    {UPL_USB_NA,                  "USB device to open, try reopening the device.  Then if successful check the device status"},
    {UPL_USB_OPEN_FAILED,         "Failed to open the USB device"},
  }
NOTE! Not necissarily in order, ie err_code_str[100] may not equal error code 100 use the lookup function (TBD).

Todo:
create a class for the error codes and strings.

Definition at line 75 of file upl_err.h.


Generated on Mon Mar 5 20:44:20 2007 for usbp by  doxygen 1.5.1-p1