532 : std::runtime_error(message)
745 [[nodiscard]] std::string
BlockName()
const;
Device not found via DCP.
DCPDeviceNotFoundError(const std::string &message)
Construct with a human-readable message.
DCPError(const std::string &message)
Construct with a human-readable message.
DCPTimeoutError(const std::string &message)
Construct with a human-readable message.
Invalid IP address format.
InvalidIPError(const std::string &message)
Construct with a human-readable message.
Invalid MAC address format.
InvalidMACError(const std::string &message)
Construct with a human-readable message.
PNIO application error with error codes.
static void extracted(const std::uint8_t &errorCode1, const std::uint8_t &errorCode2, std::string &message)
Shared implementation for FromBytes()/FromArgsStatus(): look up the error message and construct the P...
std::uint8_t errorCode1
Raw ErrorCode1 byte (category / block type).
static PNIOError CreateFromCodes(std::uint8_t errorCode, std::uint8_t errorDecode, std::uint8_t errorCode1, std::uint8_t errorCode2)
std::uint8_t errorCode
Raw ErrorCode byte (see class-level.
std::uint8_t errorDecode
Raw ErrorDecode byte; selects which ErrorCode1/ErrorCode2 table applies.
std::string BlockName() const
Human-readable name of the PNIO-CM block referenced by ErrorCode1.
bool IsCmError() const
Whether this error came from the PNIO-CM (connection management) table.
static PNIOError FromBytes(std::span< const std::uint8_t, 4 > data)
Create a PNIOError from a raw 4-byte error status.
std::uint8_t errorCode2
Raw ErrorCode2 byte (specific error within the category).
static PNIOError FromArgsStatus(std::uint32_t argsStatus)
Create a PNIOError from the little-endian ArgsStatus field carried in a DCE/RPC PDU.
PNIOError(const std::string &message, std::uint8_t errorCode, std::uint8_t errorDecode, std::uint8_t errorCode1, std::uint8_t errorCode2)
Construct directly from the four raw error-status bytes.
Insufficient permissions for raw socket.
PermissionDeniedError(const std::string &message)
Construct with a human-readable message.
Base exception for all PROFINET errors.
ProfinetError(const std::string &message)
Construct with a human-readable message.
Failed to establish RPC connection.
RPCConnectionError(const std::string &message)
Construct with a human-readable message.
RPCError(const std::string &message)
Construct with a human-readable message.
RPC returned a fault response.
std::uint32_t faultCode
DCE/RPC fault code reported by the peer.
RPCFaultError(const std::string &message, std::uint32_t faultCode=0)
Construct with a message and the fault code reported by the peer.
RPCTimeoutError(const std::string &message)
Construct with a human-readable message.
SocketError(const std::string &message)
Construct with a human-readable message.
ValidationError(const std::string &message)
Construct with a human-readable message.
std::string GetPnioRwErrorCode1Name(PnioRwErrorCode1 errorCodeRw1)
Get the human-readable name for a PNIORW ErrorCode1.
PnioCmErrorCode1
PNIO-CM ErrorCode1 values.
@ ArServerResponse
ARServerBlock response.
@ CmCtl
Connection management control.
@ IodControlResponse
IODControl response.
@ PrmServer
Parameter server.
@ FaultyRecord
Faulty record data.
@ AlarmCr
AlarmCRBlock request.
@ CmRpc
Connection management RPC.
@ IodControlRequest
IODControl request.
@ ModuleDiff
ModuleDiffBlock.
@ ArResponse
ARBlock response.
@ CmDev
Connection management device.
@ ExpectedSubmodule
ExpectedSubmoduleBlock request.
@ IocrResponse
IOCRBlock response.
@ AlarmCrResponse
AlarmCRBlock response.
@ FaultyBlock
Faulty block structure.
@ FaultyAr
Faulty application relation.
@ ModuleDiffResponse
ModuleDiffBlock response.
PnioRwWriteLengthErrorCode2
PNIORW WriteLength ErrorCode2 values.
@ WriteProtected
Write access is denied because the data is write protected.
@ DataTooLong
Write data is too long.
@ WriteLengthError
General write length error.
@ DataTooShort
Write data is too short.
ErrorDecode
PROFINET error decode values.
@ Pnio
General PNIO error.
@ PnioRw
PNIO read/write error.
@ PnioCm
PNIO connection management error.
std::string GetPnioErrorMessage(PnioRmpmErrorCode2 errorCode2)
Get the human-readable message for an RMPM ErrorCode2.
std::string GetPnioCmErrorCode1Name(PnioCmErrorCode1 errorCodeCm1)
Get the human-readable name for a PNIO-CM ErrorCode1.
PnioPrmServerErrorCode2
PNIO Parameter Server ErrorCode2 values.
@ StateConflict
The parameter server is in an invalid state for the requested operation.
PnioRwAccessErrorCode2
PNIORW Access ErrorCode2 values.
@ InvalidArea
Access denied because the area is invalid.
@ AccessDenied
Access denied.
@ LocalControl
Access denied because of local control.
@ InvalidState
Access denied because the device is in an invalid state.
@ InvalidRange
Access denied because the range is invalid.
std::string GetPnioRwErrorMessage(PnioRwInvalidIndexErrorCode2 errorCode2)
Get the human-readable message for an InvalidIndex error.
std::string GetPnioErrorCode1Name(PnioErrorCode1 errorCode1)
Get the human-readable name of a PNIO ErrorCode1.
PnioErrorCode1
PNIO ErrorCode1 values.
@ Rmpm
Runtime parameter and module management (RMPM) error.
PnioCmIocrErrorCode2
PNIO-CM IOCR ErrorCode2 values.
@ NoIocrResources
No IOCR resources are available.
@ InvalidIocrType
Invalid IOCR type.
@ InvalidIoDataLength
The IO data length is invalid.
@ CycleTimeConflict
A cycle time conflict occurred.
@ InvalidFrameId
The frame ID is invalid.
@ WatchdogConfigurationError
The watchdog configuration is invalid.
@ InvalidRtClass
The RT class is invalid.
PnioRmpmErrorCode2
PNIO RMPM ErrorCode2 values.
@ WrongAlarmCrBlockCount
The number of AlarmCR blocks is incorrect.
@ RequiredIocrBlockMissing
A required IOCR block is missing.
@ OutOfArResources
No application relation resources are available.
@ InvalidArgumentsLength
Invalid arguments length.
@ UnknownBlocksInRequest
Unknown blocks were found in the request.
PnioRwInvalidIndexErrorCode2
PNIORW InvalidIndex ErrorCode2 values.
@ IndexNotWritten
Index exists but has not been written.
@ IndexNotSupported
Index is not supported.
PnioRwResourceErrorCode2
PNIORW Resource ErrorCode2 values.
@ ModuleHasNoData
Module has no data.
@ InvalidSlot
Slot number is invalid.
@ ResourceNotAvailable
Resource is not available.
@ InvalidSubslot
Subslot number is invalid.
PnioCmExpectedSubmoduleErrorCode2
PNIO-CM Expected Submodule ErrorCode2 values.
@ IoDataLengthMismatch
IO data length does not match the expected length.
@ WrongModuleIdentNumber
Module identification number does not match.
@ WrongSubmoduleIdentNumber
Submodule identification number does not match.
PnioCmAlarmCrErrorCode2
PNIO-CM Alarm CR ErrorCode2 values.
@ NoAlarmCrResources
No Alarm CR resources are available.
@ InvalidAlarmCrType
Invalid Alarm CR type.
std::string GetPnioCmErrorMessage(PnioCmArErrorCode2 errorCode2)
Get the human-readable message for a PNIO-CM AR error.
PnioRwErrorCode1
PNIO read/write ErrorCode1 values.
@ WriteLength
Write length error.
@ Resource
Resource error.
@ Application
Application error.
@ InvalidIndex
Invalid or unsupported index.
PnioCmDeviceErrorCode2
PNIO-CM Device ErrorCode2 values.
@ ConnectionResourceUnavailable
No connection management resources are available.
@ DeviceStateConflict
Device state conflict.
@ ArSetAborted
The application relation set was aborted.
@ AlreadyOwned
The device is already owned.
std::string GetErrorDecodeName(ErrorDecode errorDecodeName)
Get the human-readable name for an ErrorDecode value.
PnioCmArErrorCode2
PNIO-CM AR ErrorCode2 values.
@ InvalidSessionKey
The session key is invalid.
@ NoAlarmResources
No alarm resources are available.
@ NoConsumerResources
No consumer resources are available.
@ InvalidArType
Invalid AR type.
@ ArAlreadyActive
AR is already active.
@ NoMemory
No memory is available.
@ NoArResources
No AR resources are available.
@ NoProviderResources
No provider resources are available.
@ ArUuidConflict
The AR UUID conflicts with an existing AR.
PnioRwApplicationErrorCode2
PNIORW Application ErrorCode2 values.
@ ModuleFailure
Module failure.
@ ResourceBusy
Resource is busy.
@ AlarmPending
An alarm is pending.
@ BackupNotAllowed
Backup is not allowed.
@ VersionConflict
Version conflict.
@ InvalidApi
API number is invalid.
PnioCmFaultyBlockErrorCode2
PNIO-CM Faulty Block ErrorCode2 values.
@ FaultyBlockStructure
Faulty block structure.