00001
00002
00003 from opcua.ua.uaerrors import UaStatusCodeError
00004 from opcua.ua import ua_binary as uabin
00005
00006 class StatusCodes(object):
00007 Good = 0
00008 Uncertain = 0x40000000
00009 Bad = 0x80000000
00010 BadUnexpectedError = 0x80010000
00011 BadInternalError = 0x80020000
00012 BadOutOfMemory = 0x80030000
00013 BadResourceUnavailable = 0x80040000
00014 BadCommunicationError = 0x80050000
00015 BadEncodingError = 0x80060000
00016 BadDecodingError = 0x80070000
00017 BadEncodingLimitsExceeded = 0x80080000
00018 BadRequestTooLarge = 0x80B80000
00019 BadResponseTooLarge = 0x80B90000
00020 BadUnknownResponse = 0x80090000
00021 BadTimeout = 0x800A0000
00022 BadServiceUnsupported = 0x800B0000
00023 BadShutdown = 0x800C0000
00024 BadServerNotConnected = 0x800D0000
00025 BadServerHalted = 0x800E0000
00026 BadNothingToDo = 0x800F0000
00027 BadTooManyOperations = 0x80100000
00028 BadTooManyMonitoredItems = 0x80DB0000
00029 BadDataTypeIdUnknown = 0x80110000
00030 BadCertificateInvalid = 0x80120000
00031 BadSecurityChecksFailed = 0x80130000
00032 BadCertificateTimeInvalid = 0x80140000
00033 BadCertificateIssuerTimeInvalid = 0x80150000
00034 BadCertificateHostNameInvalid = 0x80160000
00035 BadCertificateUriInvalid = 0x80170000
00036 BadCertificateUseNotAllowed = 0x80180000
00037 BadCertificateIssuerUseNotAllowed = 0x80190000
00038 BadCertificateUntrusted = 0x801A0000
00039 BadCertificateRevocationUnknown = 0x801B0000
00040 BadCertificateIssuerRevocationUnknown = 0x801C0000
00041 BadCertificateRevoked = 0x801D0000
00042 BadCertificateIssuerRevoked = 0x801E0000
00043 BadCertificateChainIncomplete = 0x810D0000
00044 BadUserAccessDenied = 0x801F0000
00045 BadIdentityTokenInvalid = 0x80200000
00046 BadIdentityTokenRejected = 0x80210000
00047 BadSecureChannelIdInvalid = 0x80220000
00048 BadInvalidTimestamp = 0x80230000
00049 BadNonceInvalid = 0x80240000
00050 BadSessionIdInvalid = 0x80250000
00051 BadSessionClosed = 0x80260000
00052 BadSessionNotActivated = 0x80270000
00053 BadSubscriptionIdInvalid = 0x80280000
00054 BadRequestHeaderInvalid = 0x802A0000
00055 BadTimestampsToReturnInvalid = 0x802B0000
00056 BadRequestCancelledByClient = 0x802C0000
00057 BadTooManyArguments = 0x80E50000
00058 GoodSubscriptionTransferred = 0x002D0000
00059 GoodCompletesAsynchronously = 0x002E0000
00060 GoodOverload = 0x002F0000
00061 GoodClamped = 0x00300000
00062 BadNoCommunication = 0x80310000
00063 BadWaitingForInitialData = 0x80320000
00064 BadNodeIdInvalid = 0x80330000
00065 BadNodeIdUnknown = 0x80340000
00066 BadAttributeIdInvalid = 0x80350000
00067 BadIndexRangeInvalid = 0x80360000
00068 BadIndexRangeNoData = 0x80370000
00069 BadDataEncodingInvalid = 0x80380000
00070 BadDataEncodingUnsupported = 0x80390000
00071 BadNotReadable = 0x803A0000
00072 BadNotWritable = 0x803B0000
00073 BadOutOfRange = 0x803C0000
00074 BadNotSupported = 0x803D0000
00075 BadNotFound = 0x803E0000
00076 BadObjectDeleted = 0x803F0000
00077 BadNotImplemented = 0x80400000
00078 BadMonitoringModeInvalid = 0x80410000
00079 BadMonitoredItemIdInvalid = 0x80420000
00080 BadMonitoredItemFilterInvalid = 0x80430000
00081 BadMonitoredItemFilterUnsupported = 0x80440000
00082 BadFilterNotAllowed = 0x80450000
00083 BadStructureMissing = 0x80460000
00084 BadEventFilterInvalid = 0x80470000
00085 BadContentFilterInvalid = 0x80480000
00086 BadFilterOperatorInvalid = 0x80C10000
00087 BadFilterOperatorUnsupported = 0x80C20000
00088 BadFilterOperandCountMismatch = 0x80C30000
00089 BadFilterOperandInvalid = 0x80490000
00090 BadFilterElementInvalid = 0x80C40000
00091 BadFilterLiteralInvalid = 0x80C50000
00092 BadContinuationPointInvalid = 0x804A0000
00093 BadNoContinuationPoints = 0x804B0000
00094 BadReferenceTypeIdInvalid = 0x804C0000
00095 BadBrowseDirectionInvalid = 0x804D0000
00096 BadNodeNotInView = 0x804E0000
00097 BadServerUriInvalid = 0x804F0000
00098 BadServerNameMissing = 0x80500000
00099 BadDiscoveryUrlMissing = 0x80510000
00100 BadSempahoreFileMissing = 0x80520000
00101 BadRequestTypeInvalid = 0x80530000
00102 BadSecurityModeRejected = 0x80540000
00103 BadSecurityPolicyRejected = 0x80550000
00104 BadTooManySessions = 0x80560000
00105 BadUserSignatureInvalid = 0x80570000
00106 BadApplicationSignatureInvalid = 0x80580000
00107 BadNoValidCertificates = 0x80590000
00108 BadIdentityChangeNotSupported = 0x80C60000
00109 BadRequestCancelledByRequest = 0x805A0000
00110 BadParentNodeIdInvalid = 0x805B0000
00111 BadReferenceNotAllowed = 0x805C0000
00112 BadNodeIdRejected = 0x805D0000
00113 BadNodeIdExists = 0x805E0000
00114 BadNodeClassInvalid = 0x805F0000
00115 BadBrowseNameInvalid = 0x80600000
00116 BadBrowseNameDuplicated = 0x80610000
00117 BadNodeAttributesInvalid = 0x80620000
00118 BadTypeDefinitionInvalid = 0x80630000
00119 BadSourceNodeIdInvalid = 0x80640000
00120 BadTargetNodeIdInvalid = 0x80650000
00121 BadDuplicateReferenceNotAllowed = 0x80660000
00122 BadInvalidSelfReference = 0x80670000
00123 BadReferenceLocalOnly = 0x80680000
00124 BadNoDeleteRights = 0x80690000
00125 UncertainReferenceNotDeleted = 0x40BC0000
00126 BadServerIndexInvalid = 0x806A0000
00127 BadViewIdUnknown = 0x806B0000
00128 BadViewTimestampInvalid = 0x80C90000
00129 BadViewParameterMismatch = 0x80CA0000
00130 BadViewVersionInvalid = 0x80CB0000
00131 UncertainNotAllNodesAvailable = 0x40C00000
00132 GoodResultsMayBeIncomplete = 0x00BA0000
00133 BadNotTypeDefinition = 0x80C80000
00134 UncertainReferenceOutOfServer = 0x406C0000
00135 BadTooManyMatches = 0x806D0000
00136 BadQueryTooComplex = 0x806E0000
00137 BadNoMatch = 0x806F0000
00138 BadMaxAgeInvalid = 0x80700000
00139 BadSecurityModeInsufficient = 0x80E60000
00140 BadHistoryOperationInvalid = 0x80710000
00141 BadHistoryOperationUnsupported = 0x80720000
00142 BadInvalidTimestampArgument = 0x80BD0000
00143 BadWriteNotSupported = 0x80730000
00144 BadTypeMismatch = 0x80740000
00145 BadMethodInvalid = 0x80750000
00146 BadArgumentsMissing = 0x80760000
00147 BadTooManySubscriptions = 0x80770000
00148 BadTooManyPublishRequests = 0x80780000
00149 BadNoSubscription = 0x80790000
00150 BadSequenceNumberUnknown = 0x807A0000
00151 BadMessageNotAvailable = 0x807B0000
00152 BadInsufficientClientProfile = 0x807C0000
00153 BadStateNotActive = 0x80BF0000
00154 BadTcpServerTooBusy = 0x807D0000
00155 BadTcpMessageTypeInvalid = 0x807E0000
00156 BadTcpSecureChannelUnknown = 0x807F0000
00157 BadTcpMessageTooLarge = 0x80800000
00158 BadTcpNotEnoughResources = 0x80810000
00159 BadTcpInternalError = 0x80820000
00160 BadTcpEndpointUrlInvalid = 0x80830000
00161 BadRequestInterrupted = 0x80840000
00162 BadRequestTimeout = 0x80850000
00163 BadSecureChannelClosed = 0x80860000
00164 BadSecureChannelTokenUnknown = 0x80870000
00165 BadSequenceNumberInvalid = 0x80880000
00166 BadProtocolVersionUnsupported = 0x80BE0000
00167 BadConfigurationError = 0x80890000
00168 BadNotConnected = 0x808A0000
00169 BadDeviceFailure = 0x808B0000
00170 BadSensorFailure = 0x808C0000
00171 BadOutOfService = 0x808D0000
00172 BadDeadbandFilterInvalid = 0x808E0000
00173 UncertainNoCommunicationLastUsableValue = 0x408F0000
00174 UncertainLastUsableValue = 0x40900000
00175 UncertainSubstituteValue = 0x40910000
00176 UncertainInitialValue = 0x40920000
00177 UncertainSensorNotAccurate = 0x40930000
00178 UncertainEngineeringUnitsExceeded = 0x40940000
00179 UncertainSubNormal = 0x40950000
00180 GoodLocalOverride = 0x00960000
00181 BadRefreshInProgress = 0x80970000
00182 BadConditionAlreadyDisabled = 0x80980000
00183 BadConditionAlreadyEnabled = 0x80CC0000
00184 BadConditionDisabled = 0x80990000
00185 BadEventIdUnknown = 0x809A0000
00186 BadEventNotAcknowledgeable = 0x80BB0000
00187 BadDialogNotActive = 0x80CD0000
00188 BadDialogResponseInvalid = 0x80CE0000
00189 BadConditionBranchAlreadyAcked = 0x80CF0000
00190 BadConditionBranchAlreadyConfirmed = 0x80D00000
00191 BadConditionAlreadyShelved = 0x80D10000
00192 BadConditionNotShelved = 0x80D20000
00193 BadShelvingTimeOutOfRange = 0x80D30000
00194 BadNoData = 0x809B0000
00195 BadBoundNotFound = 0x80D70000
00196 BadBoundNotSupported = 0x80D80000
00197 BadDataLost = 0x809D0000
00198 BadDataUnavailable = 0x809E0000
00199 BadEntryExists = 0x809F0000
00200 BadNoEntryExists = 0x80A00000
00201 BadTimestampNotSupported = 0x80A10000
00202 GoodEntryInserted = 0x00A20000
00203 GoodEntryReplaced = 0x00A30000
00204 UncertainDataSubNormal = 0x40A40000
00205 GoodNoData = 0x00A50000
00206 GoodMoreData = 0x00A60000
00207 BadAggregateListMismatch = 0x80D40000
00208 BadAggregateNotSupported = 0x80D50000
00209 BadAggregateInvalidInputs = 0x80D60000
00210 BadAggregateConfigurationRejected = 0x80DA0000
00211 GoodDataIgnored = 0x00D90000
00212 BadRequestNotAllowed = 0x80E40000
00213 GoodEdited = 0x00DC0000
00214 GoodPostActionFailed = 0x00DD0000
00215 UncertainDominantValueChanged = 0x40DE0000
00216 GoodDependentValueChanged = 0x00E00000
00217 BadDominantValueChanged = 0x80E10000
00218 UncertainDependentValueChanged = 0x40E20000
00219 BadDependentValueChanged = 0x80E30000
00220 GoodCommunicationEvent = 0x00A70000
00221 GoodShutdownEvent = 0x00A80000
00222 GoodCallAgain = 0x00A90000
00223 GoodNonCriticalTimeout = 0x00AA0000
00224 BadInvalidArgument = 0x80AB0000
00225 BadConnectionRejected = 0x80AC0000
00226 BadDisconnect = 0x80AD0000
00227 BadConnectionClosed = 0x80AE0000
00228 BadInvalidState = 0x80AF0000
00229 BadEndOfStream = 0x80B00000
00230 BadNoDataAvailable = 0x80B10000
00231 BadWaitingForResponse = 0x80B20000
00232 BadOperationAbandoned = 0x80B30000
00233 BadExpectedStreamToBlock = 0x80B40000
00234 BadWouldBlock = 0x80B50000
00235 BadSyntaxError = 0x80B60000
00236 BadMaxConnectionsReached = 0x80B70000
00237
00238
00239 code_to_name_doc = {
00240 0: ('Good', 'The operation completed successfully.'),
00241 0x40000000: ('Uncertain', 'The operation completed however its outputs may not be usable.'),
00242 0x80000000: ('Bad', 'The operation failed.'),
00243 0x80010000: ('BadUnexpectedError', 'An unexpected error occurred.'),
00244 0x80020000: ('BadInternalError', 'An internal error occurred as a result of a programming or configuration error.'),
00245 0x80030000: ('BadOutOfMemory', 'Not enough memory to complete the operation.'),
00246 0x80040000: ('BadResourceUnavailable', 'An operating system resource is not available.'),
00247 0x80050000: ('BadCommunicationError', 'A low level communication error occurred.'),
00248 0x80060000: ('BadEncodingError', 'Encoding halted because of invalid data in the objects being serialized.'),
00249 0x80070000: ('BadDecodingError', 'Decoding halted because of invalid data in the stream.'),
00250 0x80080000: ('BadEncodingLimitsExceeded', 'The message encoding/decoding limits imposed by the stack have been exceeded.'),
00251 0x80B80000: ('BadRequestTooLarge', 'The request message size exceeds limits set by the server.'),
00252 0x80B90000: ('BadResponseTooLarge', 'The response message size exceeds limits set by the client.'),
00253 0x80090000: ('BadUnknownResponse', 'An unrecognized response was received from the server.'),
00254 0x800A0000: ('BadTimeout', 'The operation timed out.'),
00255 0x800B0000: ('BadServiceUnsupported', 'The server does not support the requested service.'),
00256 0x800C0000: ('BadShutdown', 'The operation was cancelled because the application is shutting down.'),
00257 0x800D0000: ('BadServerNotConnected', 'The operation could not complete because the client is not connected to the server.'),
00258 0x800E0000: ('BadServerHalted', 'The server has stopped and cannot process any requests.'),
00259 0x800F0000: ('BadNothingToDo', 'There was nothing to do because the client passed a list of operations with no elements.'),
00260 0x80100000: ('BadTooManyOperations', 'The request could not be processed because it specified too many operations.'),
00261 0x80DB0000: ('BadTooManyMonitoredItems', 'The request could not be processed because there are too many monitored items in the subscription.'),
00262 0x80110000: ('BadDataTypeIdUnknown', 'The extension object cannot be (de)serialized because the data type id is not recognized.'),
00263 0x80120000: ('BadCertificateInvalid', 'The certificate provided as a parameter is not valid.'),
00264 0x80130000: ('BadSecurityChecksFailed', 'An error occurred verifying security.'),
00265 0x80140000: ('BadCertificateTimeInvalid', 'The Certificate has expired or is not yet valid.'),
00266 0x80150000: ('BadCertificateIssuerTimeInvalid', 'An Issuer Certificate has expired or is not yet valid.'),
00267 0x80160000: ('BadCertificateHostNameInvalid', 'The HostName used to connect to a Server does not match a HostName in the Certificate.'),
00268 0x80170000: ('BadCertificateUriInvalid', 'The URI specified in the ApplicationDescription does not match the URI in the Certificate.'),
00269 0x80180000: ('BadCertificateUseNotAllowed', 'The Certificate may not be used for the requested operation.'),
00270 0x80190000: ('BadCertificateIssuerUseNotAllowed', 'The Issuer Certificate may not be used for the requested operation.'),
00271 0x801A0000: ('BadCertificateUntrusted', 'The Certificate is not trusted.'),
00272 0x801B0000: ('BadCertificateRevocationUnknown', 'It was not possible to determine if the Certificate has been revoked.'),
00273 0x801C0000: ('BadCertificateIssuerRevocationUnknown', 'It was not possible to determine if the Issuer Certificate has been revoked.'),
00274 0x801D0000: ('BadCertificateRevoked', 'The certificate has been revoked.'),
00275 0x801E0000: ('BadCertificateIssuerRevoked', 'The issuer certificate has been revoked.'),
00276 0x810D0000: ('BadCertificateChainIncomplete', 'The certificate chain is incomplete.'),
00277 0x801F0000: ('BadUserAccessDenied', 'User does not have permission to perform the requested operation.'),
00278 0x80200000: ('BadIdentityTokenInvalid', 'The user identity token is not valid.'),
00279 0x80210000: ('BadIdentityTokenRejected', 'The user identity token is valid but the server has rejected it.'),
00280 0x80220000: ('BadSecureChannelIdInvalid', 'The specified secure channel is no longer valid.'),
00281 0x80230000: ('BadInvalidTimestamp', 'The timestamp is outside the range allowed by the server.'),
00282 0x80240000: ('BadNonceInvalid', 'The nonce does appear to be not a random value or it is not the correct length.'),
00283 0x80250000: ('BadSessionIdInvalid', 'The session id is not valid.'),
00284 0x80260000: ('BadSessionClosed', 'The session was closed by the client.'),
00285 0x80270000: ('BadSessionNotActivated', 'The session cannot be used because ActivateSession has not been called.'),
00286 0x80280000: ('BadSubscriptionIdInvalid', 'The subscription id is not valid.'),
00287 0x802A0000: ('BadRequestHeaderInvalid', 'The header for the request is missing or invalid.'),
00288 0x802B0000: ('BadTimestampsToReturnInvalid', 'The timestamps to return parameter is invalid.'),
00289 0x802C0000: ('BadRequestCancelledByClient', 'The request was cancelled by the client.'),
00290 0x80E50000: ('BadTooManyArguments', 'Too many arguments were provided.'),
00291 0x002D0000: ('GoodSubscriptionTransferred', 'The subscription was transferred to another session.'),
00292 0x002E0000: ('GoodCompletesAsynchronously', 'The processing will complete asynchronously.'),
00293 0x002F0000: ('GoodOverload', 'Sampling has slowed down due to resource limitations.'),
00294 0x00300000: ('GoodClamped', 'The value written was accepted but was clamped.'),
00295 0x80310000: ('BadNoCommunication', 'Communication with the data source is defined, but not established, and there is no last known value available.'),
00296 0x80320000: ('BadWaitingForInitialData', 'Waiting for the server to obtain values from the underlying data source.'),
00297 0x80330000: ('BadNodeIdInvalid', 'The syntax of the node id is not valid.'),
00298 0x80340000: ('BadNodeIdUnknown', 'The node id refers to a node that does not exist in the server address space.'),
00299 0x80350000: ('BadAttributeIdInvalid', 'The attribute is not supported for the specified Node.'),
00300 0x80360000: ('BadIndexRangeInvalid', 'The syntax of the index range parameter is invalid.'),
00301 0x80370000: ('BadIndexRangeNoData', 'No data exists within the range of indexes specified.'),
00302 0x80380000: ('BadDataEncodingInvalid', 'The data encoding is invalid.'),
00303 0x80390000: ('BadDataEncodingUnsupported', 'The server does not support the requested data encoding for the node.'),
00304 0x803A0000: ('BadNotReadable', 'The access level does not allow reading or subscribing to the Node.'),
00305 0x803B0000: ('BadNotWritable', 'The access level does not allow writing to the Node.'),
00306 0x803C0000: ('BadOutOfRange', 'The value was out of range.'),
00307 0x803D0000: ('BadNotSupported', 'The requested operation is not supported.'),
00308 0x803E0000: ('BadNotFound', 'A requested item was not found or a search operation ended without success.'),
00309 0x803F0000: ('BadObjectDeleted', 'The object cannot be used because it has been deleted.'),
00310 0x80400000: ('BadNotImplemented', 'Requested operation is not implemented.'),
00311 0x80410000: ('BadMonitoringModeInvalid', 'The monitoring mode is invalid.'),
00312 0x80420000: ('BadMonitoredItemIdInvalid', 'The monitoring item id does not refer to a valid monitored item.'),
00313 0x80430000: ('BadMonitoredItemFilterInvalid', 'The monitored item filter parameter is not valid.'),
00314 0x80440000: ('BadMonitoredItemFilterUnsupported', 'The server does not support the requested monitored item filter.'),
00315 0x80450000: ('BadFilterNotAllowed', 'A monitoring filter cannot be used in combination with the attribute specified.'),
00316 0x80460000: ('BadStructureMissing', 'A mandatory structured parameter was missing or null.'),
00317 0x80470000: ('BadEventFilterInvalid', 'The event filter is not valid.'),
00318 0x80480000: ('BadContentFilterInvalid', 'The content filter is not valid.'),
00319 0x80C10000: ('BadFilterOperatorInvalid', 'An unregognized operator was provided in a filter.'),
00320 0x80C20000: ('BadFilterOperatorUnsupported', 'A valid operator was provided, but the server does not provide support for this filter operator.'),
00321 0x80C30000: ('BadFilterOperandCountMismatch', 'The number of operands provided for the filter operator was less then expected for the operand provided.'),
00322 0x80490000: ('BadFilterOperandInvalid', 'The operand used in a content filter is not valid.'),
00323 0x80C40000: ('BadFilterElementInvalid', 'The referenced element is not a valid element in the content filter.'),
00324 0x80C50000: ('BadFilterLiteralInvalid', 'The referenced literal is not a valid value.'),
00325 0x804A0000: ('BadContinuationPointInvalid', 'The continuation point provide is longer valid.'),
00326 0x804B0000: ('BadNoContinuationPoints', 'The operation could not be processed because all continuation points have been allocated.'),
00327 0x804C0000: ('BadReferenceTypeIdInvalid', 'The operation could not be processed because all continuation points have been allocated.'),
00328 0x804D0000: ('BadBrowseDirectionInvalid', 'The browse direction is not valid.'),
00329 0x804E0000: ('BadNodeNotInView', 'The node is not part of the view.'),
00330 0x804F0000: ('BadServerUriInvalid', 'The ServerUri is not a valid URI.'),
00331 0x80500000: ('BadServerNameMissing', 'No ServerName was specified.'),
00332 0x80510000: ('BadDiscoveryUrlMissing', 'No DiscoveryUrl was specified.'),
00333 0x80520000: ('BadSempahoreFileMissing', 'The semaphore file specified by the client is not valid.'),
00334 0x80530000: ('BadRequestTypeInvalid', 'The security token request type is not valid.'),
00335 0x80540000: ('BadSecurityModeRejected', 'The security mode does not meet the requirements set by the Server.'),
00336 0x80550000: ('BadSecurityPolicyRejected', 'The security policy does not meet the requirements set by the Server.'),
00337 0x80560000: ('BadTooManySessions', 'The server has reached its maximum number of sessions.'),
00338 0x80570000: ('BadUserSignatureInvalid', 'The user token signature is missing or invalid.'),
00339 0x80580000: ('BadApplicationSignatureInvalid', 'The signature generated with the client certificate is missing or invalid.'),
00340 0x80590000: ('BadNoValidCertificates', 'The client did not provide at least one software certificate that is valid and meets the profile requirements for the server.'),
00341 0x80C60000: ('BadIdentityChangeNotSupported', 'The Server does not support changing the user identity assigned to the session.'),
00342 0x805A0000: ('BadRequestCancelledByRequest', 'The request was cancelled by the client with the Cancel service.'),
00343 0x805B0000: ('BadParentNodeIdInvalid', 'The parent node id does not to refer to a valid node.'),
00344 0x805C0000: ('BadReferenceNotAllowed', 'The reference could not be created because it violates constraints imposed by the data model.'),
00345 0x805D0000: ('BadNodeIdRejected', 'The requested node id was reject because it was either invalid or server does not allow node ids to be specified by the client.'),
00346 0x805E0000: ('BadNodeIdExists', 'The requested node id is already used by another node.'),
00347 0x805F0000: ('BadNodeClassInvalid', 'The node class is not valid.'),
00348 0x80600000: ('BadBrowseNameInvalid', 'The browse name is invalid.'),
00349 0x80610000: ('BadBrowseNameDuplicated', 'The browse name is not unique among nodes that share the same relationship with the parent.'),
00350 0x80620000: ('BadNodeAttributesInvalid', 'The node attributes are not valid for the node class.'),
00351 0x80630000: ('BadTypeDefinitionInvalid', 'The type definition node id does not reference an appropriate type node.'),
00352 0x80640000: ('BadSourceNodeIdInvalid', 'The source node id does not reference a valid node.'),
00353 0x80650000: ('BadTargetNodeIdInvalid', 'The target node id does not reference a valid node.'),
00354 0x80660000: ('BadDuplicateReferenceNotAllowed', 'The reference type between the nodes is already defined.'),
00355 0x80670000: ('BadInvalidSelfReference', 'The server does not allow this type of self reference on this node.'),
00356 0x80680000: ('BadReferenceLocalOnly', 'The reference type is not valid for a reference to a remote server.'),
00357 0x80690000: ('BadNoDeleteRights', 'The server will not allow the node to be deleted.'),
00358 0x40BC0000: ('UncertainReferenceNotDeleted', 'The server was not able to delete all target references.'),
00359 0x806A0000: ('BadServerIndexInvalid', 'The server index is not valid.'),
00360 0x806B0000: ('BadViewIdUnknown', 'The view id does not refer to a valid view node.'),
00361 0x80C90000: ('BadViewTimestampInvalid', 'The view timestamp is not available or not supported.'),
00362 0x80CA0000: ('BadViewParameterMismatch', 'The view parameters are not consistent with each other.'),
00363 0x80CB0000: ('BadViewVersionInvalid', 'The view version is not available or not supported.'),
00364 0x40C00000: ('UncertainNotAllNodesAvailable', 'The list of references may not be complete because the underlying system is not available.'),
00365 0x00BA0000: ('GoodResultsMayBeIncomplete', 'The server should have followed a reference to a node in a remote server but did not. The result set may be incomplete.'),
00366 0x80C80000: ('BadNotTypeDefinition', 'The provided Nodeid was not a type definition nodeid.'),
00367 0x406C0000: ('UncertainReferenceOutOfServer', 'One of the references to follow in the relative path references to a node in the address space in another server.'),
00368 0x806D0000: ('BadTooManyMatches', 'The requested operation has too many matches to return.'),
00369 0x806E0000: ('BadQueryTooComplex', 'The requested operation requires too many resources in the server.'),
00370 0x806F0000: ('BadNoMatch', 'The requested operation has no match to return.'),
00371 0x80700000: ('BadMaxAgeInvalid', 'The max age parameter is invalid.'),
00372 0x80E60000: ('BadSecurityModeInsufficient', 'The operation is not permitted over the current secure channel.'),
00373 0x80710000: ('BadHistoryOperationInvalid', 'The history details parameter is not valid.'),
00374 0x80720000: ('BadHistoryOperationUnsupported', 'The server does not support the requested operation.'),
00375 0x80BD0000: ('BadInvalidTimestampArgument', 'The defined timestamp to return was invalid.'),
00376 0x80730000: ('BadWriteNotSupported', 'The server not does support writing the combination of value, status and timestamps provided.'),
00377 0x80740000: ('BadTypeMismatch', 'The value supplied for the attribute is not of the same type as the attribute"s value.'),
00378 0x80750000: ('BadMethodInvalid', 'The method id does not refer to a method for the specified object.'),
00379 0x80760000: ('BadArgumentsMissing', 'The client did not specify all of the input arguments for the method.'),
00380 0x80770000: ('BadTooManySubscriptions', 'The server has reached its maximum number of subscriptions.'),
00381 0x80780000: ('BadTooManyPublishRequests', 'The server has reached the maximum number of queued publish requests.'),
00382 0x80790000: ('BadNoSubscription', 'There is no subscription available for this session.'),
00383 0x807A0000: ('BadSequenceNumberUnknown', 'The sequence number is unknown to the server.'),
00384 0x807B0000: ('BadMessageNotAvailable', 'The requested notification message is no longer available.'),
00385 0x807C0000: ('BadInsufficientClientProfile', 'The Client of the current Session does not support one or more Profiles that are necessary for the Subscription.'),
00386 0x80BF0000: ('BadStateNotActive', 'The sub-state machine is not currently active.'),
00387 0x807D0000: ('BadTcpServerTooBusy', 'The server cannot process the request because it is too busy.'),
00388 0x807E0000: ('BadTcpMessageTypeInvalid', 'The type of the message specified in the header invalid.'),
00389 0x807F0000: ('BadTcpSecureChannelUnknown', 'The SecureChannelId and/or TokenId are not currently in use.'),
00390 0x80800000: ('BadTcpMessageTooLarge', 'The size of the message specified in the header is too large.'),
00391 0x80810000: ('BadTcpNotEnoughResources', 'There are not enough resources to process the request.'),
00392 0x80820000: ('BadTcpInternalError', 'An internal error occurred.'),
00393 0x80830000: ('BadTcpEndpointUrlInvalid', 'The Server does not recognize the QueryString specified.'),
00394 0x80840000: ('BadRequestInterrupted', 'The request could not be sent because of a network interruption.'),
00395 0x80850000: ('BadRequestTimeout', 'Timeout occurred while processing the request.'),
00396 0x80860000: ('BadSecureChannelClosed', 'The secure channel has been closed.'),
00397 0x80870000: ('BadSecureChannelTokenUnknown', 'The token has expired or is not recognized.'),
00398 0x80880000: ('BadSequenceNumberInvalid', 'The sequence number is not valid.'),
00399 0x80BE0000: ('BadProtocolVersionUnsupported', 'The applications do not have compatible protocol versions.'),
00400 0x80890000: ('BadConfigurationError', 'There is a problem with the configuration that affects the usefulness of the value.'),
00401 0x808A0000: ('BadNotConnected', 'The variable should receive its value from another variable, but has never been configured to do so.'),
00402 0x808B0000: ('BadDeviceFailure', 'There has been a failure in the device/data source that generates the value that has affected the value.'),
00403 0x808C0000: ('BadSensorFailure', 'There has been a failure in the sensor from which the value is derived by the device/data source.'),
00404 0x808D0000: ('BadOutOfService', 'The source of the data is not operational.'),
00405 0x808E0000: ('BadDeadbandFilterInvalid', 'The deadband filter is not valid.'),
00406 0x408F0000: ('UncertainNoCommunicationLastUsableValue', 'Communication to the data source has failed. The variable value is the last value that had a good quality.'),
00407 0x40900000: ('UncertainLastUsableValue', 'Whatever was updating this value has stopped doing so.'),
00408 0x40910000: ('UncertainSubstituteValue', 'The value is an operational value that was manually overwritten.'),
00409 0x40920000: ('UncertainInitialValue', 'The value is an initial value for a variable that normally receives its value from another variable.'),
00410 0x40930000: ('UncertainSensorNotAccurate', 'The value is at one of the sensor limits.'),
00411 0x40940000: ('UncertainEngineeringUnitsExceeded', 'The value is outside of the range of values defined for this parameter.'),
00412 0x40950000: ('UncertainSubNormal', 'The value is derived from multiple sources and has less than the required number of Good sources.'),
00413 0x00960000: ('GoodLocalOverride', 'The value has been overridden.'),
00414 0x80970000: ('BadRefreshInProgress', 'This Condition refresh failed, a Condition refresh operation is already in progress.'),
00415 0x80980000: ('BadConditionAlreadyDisabled', 'This condition has already been disabled.'),
00416 0x80CC0000: ('BadConditionAlreadyEnabled', 'This condition has already been enabled.'),
00417 0x80990000: ('BadConditionDisabled', 'Property not available, this condition is disabled.'),
00418 0x809A0000: ('BadEventIdUnknown', 'The specified event id is not recognized.'),
00419 0x80BB0000: ('BadEventNotAcknowledgeable', 'The event cannot be acknowledged.'),
00420 0x80CD0000: ('BadDialogNotActive', 'The dialog condition is not active.'),
00421 0x80CE0000: ('BadDialogResponseInvalid', 'The response is not valid for the dialog.'),
00422 0x80CF0000: ('BadConditionBranchAlreadyAcked', 'The condition branch has already been acknowledged.'),
00423 0x80D00000: ('BadConditionBranchAlreadyConfirmed', 'The condition branch has already been confirmed.'),
00424 0x80D10000: ('BadConditionAlreadyShelved', 'The condition has already been shelved.'),
00425 0x80D20000: ('BadConditionNotShelved', 'The condition is not currently shelved.'),
00426 0x80D30000: ('BadShelvingTimeOutOfRange', 'The shelving time not within an acceptable range.'),
00427 0x809B0000: ('BadNoData', 'No data exists for the requested time range or event filter.'),
00428 0x80D70000: ('BadBoundNotFound', 'No data found to provide upper or lower bound value.'),
00429 0x80D80000: ('BadBoundNotSupported', 'The server cannot retrieve a bound for the variable.'),
00430 0x809D0000: ('BadDataLost', 'Data is missing due to collection started/stopped/lost.'),
00431 0x809E0000: ('BadDataUnavailable', 'Expected data is unavailable for the requested time range due to an un-mounted volume, an off-line archive or tape, or similar reason for temporary unavailability.'),
00432 0x809F0000: ('BadEntryExists', 'The data or event was not successfully inserted because a matching entry exists.'),
00433 0x80A00000: ('BadNoEntryExists', 'The data or event was not successfully updated because no matching entry exists.'),
00434 0x80A10000: ('BadTimestampNotSupported', 'The client requested history using a timestamp format the server does not support (i.e requested ServerTimestamp when server only supports SourceTimestamp).'),
00435 0x00A20000: ('GoodEntryInserted', 'The data or event was successfully inserted into the historical database.'),
00436 0x00A30000: ('GoodEntryReplaced', 'The data or event field was successfully replaced in the historical database.'),
00437 0x40A40000: ('UncertainDataSubNormal', 'The value is derived from multiple values and has less than the required number of Good values.'),
00438 0x00A50000: ('GoodNoData', 'No data exists for the requested time range or event filter.'),
00439 0x00A60000: ('GoodMoreData', 'The data or event field was successfully replaced in the historical database.'),
00440 0x80D40000: ('BadAggregateListMismatch', 'The requested number of Aggregates does not match the requested number of NodeIds.'),
00441 0x80D50000: ('BadAggregateNotSupported', 'The requested Aggregate is not support by the server.'),
00442 0x80D60000: ('BadAggregateInvalidInputs', 'The aggregate value could not be derived due to invalid data inputs.'),
00443 0x80DA0000: ('BadAggregateConfigurationRejected', 'The aggregate configuration is not valid for specified node.'),
00444 0x00D90000: ('GoodDataIgnored', 'The request pecifies fields which are not valid for the EventType or cannot be saved by the historian.'),
00445 0x80E40000: ('BadRequestNotAllowed', 'The request was rejected by the server because it did not meet the criteria set by the server.'),
00446 0x00DC0000: ('GoodEdited', 'The value does not come from the real source and has been edited by the server.'),
00447 0x00DD0000: ('GoodPostActionFailed', 'There was an error in execution of these post-actions.'),
00448 0x40DE0000: ('UncertainDominantValueChanged', 'The related EngineeringUnit has been changed but the Variable Value is still provided based on the previous unit.'),
00449 0x00E00000: ('GoodDependentValueChanged', 'A dependent value has been changed but the change has not been applied to the device.'),
00450 0x80E10000: ('BadDominantValueChanged', 'The related EngineeringUnit has been changed but this change has not been applied to the device. The Variable Value is still dependent on the previous unit but its status is currently Bad.'),
00451 0x40E20000: ('UncertainDependentValueChanged', 'A dependent value has been changed but the change has not been applied to the device. The quality of the dominant variable is uncertain.'),
00452 0x80E30000: ('BadDependentValueChanged', 'A dependent value has been changed but the change has not been applied to the device. The quality of the dominant variable is Bad.'),
00453 0x00A70000: ('GoodCommunicationEvent', 'The communication layer has raised an event.'),
00454 0x00A80000: ('GoodShutdownEvent', 'The system is shutting down.'),
00455 0x00A90000: ('GoodCallAgain', 'The operation is not finished and needs to be called again.'),
00456 0x00AA0000: ('GoodNonCriticalTimeout', 'A non-critical timeout occurred.'),
00457 0x80AB0000: ('BadInvalidArgument', 'One or more arguments are invalid.'),
00458 0x80AC0000: ('BadConnectionRejected', 'Could not establish a network connection to remote server.'),
00459 0x80AD0000: ('BadDisconnect', 'The server has disconnected from the client.'),
00460 0x80AE0000: ('BadConnectionClosed', 'The network connection has been closed.'),
00461 0x80AF0000: ('BadInvalidState', 'The operation cannot be completed because the object is closed, uninitialized or in some other invalid state.'),
00462 0x80B00000: ('BadEndOfStream', 'Cannot move beyond end of the stream.'),
00463 0x80B10000: ('BadNoDataAvailable', 'No data is currently available for reading from a non-blocking stream.'),
00464 0x80B20000: ('BadWaitingForResponse', 'The asynchronous operation is waiting for a response.'),
00465 0x80B30000: ('BadOperationAbandoned', 'The asynchronous operation was abandoned by the caller.'),
00466 0x80B40000: ('BadExpectedStreamToBlock', 'The stream did not return all data requested (possibly because it is a non-blocking stream).'),
00467 0x80B50000: ('BadWouldBlock', 'Non blocking behaviour is required and the operation would block.'),
00468 0x80B60000: ('BadSyntaxError', 'A value had an invalid syntax.'),
00469 0x80B70000: ('BadMaxConnectionsReached', 'The operation could not be finished because all available connections are in use.'),
00470 }
00471
00472
00473 def get_name_and_doc(val):
00474 if val in code_to_name_doc:
00475 return code_to_name_doc[val]
00476 else:
00477 if uabin.test_bit(val, 31):
00478 return 'Bad', 'Unknown StatusCode value: {0}'.format(val)
00479 elif uabin.test_bit(val, 30):
00480 return 'UncertainIn', 'Unknown StatusCode value: {0}'.format(val)
00481 else:
00482 return 'Good', 'Unknown StatusCode value: {0}'.format(val)