PAL
A Platform Abstraction Layer connects the mbed-client with the underlying platform.
Enumerations
pal_errors.h File Reference
#include "pal_types.h"

Go to the source code of this file.

Enumerations

enum  palErrorModules_t {
  PAL_ERR_MODULE_GENERAL = 0x4, PAL_ERR_MODULE_PAL = 0x6, PAL_ERR_MODULE_C = 0x8, PAL_ERR_MODULE_RTOS = 0xC,
  PAL_ERR_MODULE_NET = 0x10, PAL_ERR_MODULE_TLS = 0x14, PAL_ERR_MODULE_CRYPTO = 0x18, PAL_ERR_MODULE_UPDATE = 0x1C
}
 
enum  palError_t {
  PAL_ERR_GENERAL_BASE = (-1 << PAL_ERR_MODULE_GENERAL), PAL_ERR_GENERIC_FAILURE = PAL_ERR_GENERAL_BASE, PAL_ERR_INVALID_ARGUMENT = PAL_ERR_GENERAL_BASE + 1, PAL_ERR_NO_MEMORY = PAL_ERR_GENERAL_BASE + 2,
  PAL_ERR_BUFFER_TOO_SMALL = PAL_ERR_GENERAL_BASE + 3, PAL_ERR_NOT_SUPPORTED = PAL_ERR_GENERAL_BASE + 4, PAL_ERR_TIMEOUT_EXPIRED = PAL_ERR_GENERAL_BASE + 5, PAL_ERR_NOT_INITIALIZED = PAL_ERR_GENERAL_BASE + 6,
  PAL_ERR_NULL_POINTER = PAL_ERR_GENERAL_BASE + 7, PAL_ERR_CREATION_FAILED = PAL_ERR_GENERAL_BASE + 8, PAL_ERR_NOT_IMPLEMENTED = (-1 << PAL_ERR_MODULE_PAL), PAL_ERR_RTOS_ERROR_BASE = (-1 << PAL_ERR_MODULE_RTOS),
  PAL_ERR_RTOS_PARAMETER = PAL_ERR_RTOS_ERROR_BASE + 0x80, PAL_ERR_RTOS_RESOURCE = PAL_ERR_RTOS_ERROR_BASE + 0x81, PAL_ERR_RTOS_TIMEOUT = PAL_ERR_RTOS_ERROR_BASE + 0xC1, PAL_ERR_RTOS_ISR = PAL_ERR_RTOS_ERROR_BASE + 0x82,
  PAL_ERR_RTOS_ISR_RECURSIVE = PAL_ERR_RTOS_ERROR_BASE + 0x83, PAL_ERR_RTOS_PRIORITY = PAL_ERR_RTOS_ERROR_BASE + 0x84, PAL_ERR_RTOS_NO_MEMORY = PAL_ERR_RTOS_ERROR_BASE + 0x85, PAL_ERR_RTOS_VALUE = PAL_ERR_RTOS_ERROR_BASE + 0x86,
  PAL_ERR_RTOS_OS = PAL_ERR_RTOS_ERROR_BASE + 0xFF, PAL_ERR_SOCKET_ERROR_BASE = (-1 << PAL_ERR_MODULE_NET), PAL_ERR_SOCKET_GENERIC = PAL_ERR_SOCKET_ERROR_BASE, PAL_ERR_SOCKET_NO_BUFFERS = PAL_ERR_SOCKET_ERROR_BASE + 1,
  PAL_ERR_SOCKET_HOST_UNREACHABLE = PAL_ERR_SOCKET_ERROR_BASE + 2, PAL_ERR_SOCKET_IN_PROGRES = PAL_ERR_SOCKET_ERROR_BASE + 3, PAL_ERR_SOCKET_INVALID_VALUE = PAL_ERR_SOCKET_ERROR_BASE + 4, PAL_ERR_SOCKET_WOULD_BLOCK = PAL_ERR_SOCKET_ERROR_BASE + 5,
  PAL_ERR_SOCKET_ADDRESS_IN_USE = PAL_ERR_SOCKET_ERROR_BASE + 6, PAL_ERR_SOCKET_ALREADY_CONNECTED = PAL_ERR_SOCKET_ERROR_BASE + 7, PAL_ERR_SOCKET_CONNECTION_ABORTED = PAL_ERR_SOCKET_ERROR_BASE + 8, PAL_ERR_SOCKET_CONNECTION_RESET = PAL_ERR_SOCKET_ERROR_BASE + 9,
  PAL_ERR_SOCKET_NOT_CONNECTED = PAL_ERR_SOCKET_ERROR_BASE + 10, PAL_ERR_SOCKET_INPUT_OUTPUT_ERROR = PAL_ERR_SOCKET_ERROR_BASE + 11, PAL_ERR_SOCKET_CONNECTION_CLOSED = PAL_ERR_SOCKET_ERROR_BASE + 12, PAL_ERR_SOCKET_FAILED_TO_SET_SOCKET_TO_NON_BLOCKING = PAL_ERR_SOCKET_ERROR_BASE + 13,
  PAL_ERR_SOCKET_INVALID_ADDRESS_FAMILY = PAL_ERR_SOCKET_ERROR_BASE + 14, PAL_ERR_SOCKET_INVALID_ADDRESS = PAL_ERR_SOCKET_ERROR_BASE + 15, PAL_ERR_SOCKET_DNS_ERROR = PAL_ERR_SOCKET_ERROR_BASE + 16, PAL_ERR_SOCKET_HDCP_ERROR = PAL_ERR_SOCKET_ERROR_BASE + 17,
  PAL_ERR_SOCKET_AUTH_ERROR = PAL_ERR_SOCKET_ERROR_BASE + 18, PAL_ERR_SOCKET_OPTION_NOT_SUPPORTED = PAL_ERR_SOCKET_ERROR_BASE + 19, PAL_ERR_UPDATE_ERROR_BASE = (-1 << PAL_ERR_MODULE_UPDATE), PAL_ERR_UPDATE_ERROR = PAL_ERR_UPDATE_ERROR_BASE,
  PAL_ERR_UPDATE_BUSY = PAL_ERR_UPDATE_ERROR_BASE + 1, PAL_ERR_UPDATE_TIMEOUT = PAL_ERR_UPDATE_ERROR_BASE + 2, PAL_ERR_UPDATE_OUT_OF_BOUNDS = PAL_ERR_UPDATE_ERROR_BASE + 3, PAL_ERR_UPDATE_PALFROM_API = PAL_ERR_UPDATE_ERROR_BASE + 4,
  PAL_ERR_UPDATE_PALFROM_IO = PAL_ERR_UPDATE_ERROR_BASE + 5, PAL_ERR_UPDATE_END_OF_IMAGE = PAL_ERR_UPDATE_ERROR_BASE + 6, PAL_ERR_UPDATE_CHUNK_TO_SMALL = PAL_ERR_UPDATE_ERROR_BASE + 7
}
 

Enumeration Type Documentation

enum palError_t
Enumerator
PAL_ERR_GENERAL_BASE 
PAL_ERR_GENERIC_FAILURE 
PAL_ERR_INVALID_ARGUMENT 

generic failure

PAL_ERR_NO_MEMORY 

one or more of the functions arguments is invalid

PAL_ERR_BUFFER_TOO_SMALL 

failure due to a failed attempt to allocate memory

PAL_ERR_NOT_SUPPORTED 

buffer given is too small

PAL_ERR_TIMEOUT_EXPIRED 

operation not supported by PAL for the current configuration

PAL_ERR_NOT_INITIALIZED 

timeout for the operation has expired

PAL_ERR_NULL_POINTER 

timeout for the operation has expired

PAL_ERR_CREATION_FAILED 

received a null pointer when it should be initialized

PAL_ERR_NOT_IMPLEMENTED 

failure in creation of given type, like: mutex, thread , etc

PAL_ERR_RTOS_ERROR_BASE 

Currently not implemented will be in the future

PAL_ERR_RTOS_PARAMETER 

generic failure in RTOS module

PAL_ERR_RTOS_RESOURCE 

PAL mapping of CMSIS error osErrorParameter : parameter error: a mandatory parameter was missing or specified an incorrect object.

PAL_ERR_RTOS_TIMEOUT 

PAL mapping of CMSIS error osErrorResource : resource not available: a specified resource was not available.

PAL_ERR_RTOS_ISR 

PAL mapping of CMSIS error osErrorTimeoutResource : resource not available within given time: a specified resource was not available within the timeout period

PAL_ERR_RTOS_ISR_RECURSIVE 

PAL mapping of CMSIS error osErrorISR : not allowed in ISR context: the function cannot be called from interrupt service routines.

PAL_ERR_RTOS_PRIORITY 

PAL mapping of CMSIS error osErrorISRRecursive : function called multiple times from ISR with same object.c

PAL_ERR_RTOS_NO_MEMORY 

PAL mapping of CMSIS error osErrorPriority : system cannot determine priority or thread has illegal priority.

PAL_ERR_RTOS_VALUE 

PAL mapping of CMSIS error osErrorNoMemory : system is out of memory: it was impossible to allocate or reserve memory for the operation.

PAL_ERR_RTOS_OS 

PAL mapping of CMSIS error osErrorValue : value of a parameter is out of range.

PAL_ERR_SOCKET_ERROR_BASE 

PAL mapping of CMSIS error osErrorOS : unspecified RTOS error: run-time error but no other error message fits.

PAL_ERR_SOCKET_GENERIC 

generic socket error

PAL_ERR_SOCKET_NO_BUFFERS 

generic socket error

PAL_ERR_SOCKET_HOST_UNREACHABLE 

no buffers - PAL mapping of posix error ENOBUFS

PAL_ERR_SOCKET_IN_PROGRES 

host unreachable (routing error)- PAL mapping of posix error EHOSTUNREACH

PAL_ERR_SOCKET_INVALID_VALUE 

in progress- PAL mapping of posix error EINPROGRESS

PAL_ERR_SOCKET_WOULD_BLOCK 

invalid value - PAL mapping of posix error EINVAL

PAL_ERR_SOCKET_ADDRESS_IN_USE 

would block - PAL mapping of posix error EWOULDBLOCK

PAL_ERR_SOCKET_ALREADY_CONNECTED 

Address in use - PAL mapping of posix error EADDRINUSE

PAL_ERR_SOCKET_CONNECTION_ABORTED 

Already connected - PAL mapping of posix error EALREADY

PAL_ERR_SOCKET_CONNECTION_RESET 

Connection aborted - PAL mapping of posix error ECONNABORTED

PAL_ERR_SOCKET_NOT_CONNECTED 

Connection reset - PAL mapping of posix error ECONNRESET

PAL_ERR_SOCKET_INPUT_OUTPUT_ERROR 

Not connected - PAL mapping of posix error ENOTCONN

PAL_ERR_SOCKET_CONNECTION_CLOSED 

I/O error PAL mapping of posix error EIO

PAL_ERR_SOCKET_FAILED_TO_SET_SOCKET_TO_NON_BLOCKING 

connection closed

PAL_ERR_SOCKET_INVALID_ADDRESS_FAMILY 

failed to set socket to non-blocking

PAL_ERR_SOCKET_INVALID_ADDRESS 

failed to set socket to non-blocking

PAL_ERR_SOCKET_DNS_ERROR 

address given was not valid/found

PAL_ERR_SOCKET_HDCP_ERROR 

DNS lookup error

PAL_ERR_SOCKET_AUTH_ERROR 

HDCP error

PAL_ERR_SOCKET_OPTION_NOT_SUPPORTED 

authentication error

PAL_ERR_UPDATE_ERROR_BASE 

socket option not supported

PAL_ERR_UPDATE_ERROR 

generic error

PAL_ERR_UPDATE_BUSY 

unknown error

PAL_ERR_UPDATE_TIMEOUT 

unknown error

PAL_ERR_UPDATE_OUT_OF_BOUNDS 

unknown error

PAL_ERR_UPDATE_PALFROM_API 

unknown error

PAL_ERR_UPDATE_PALFROM_IO 

unknown error

PAL_ERR_UPDATE_END_OF_IMAGE 

unknown error

PAL_ERR_UPDATE_CHUNK_TO_SMALL 

unknown error

Enumerator
PAL_ERR_MODULE_GENERAL 
PAL_ERR_MODULE_PAL 
PAL_ERR_MODULE_C 
PAL_ERR_MODULE_RTOS 
PAL_ERR_MODULE_NET 
PAL_ERR_MODULE_TLS 
PAL_ERR_MODULE_CRYPTO 
PAL_ERR_MODULE_UPDATE