The methods accessing the ROC control space, like
return an int
return code. It holds 0 in case the operation succeeded and is non-zero when it failed. In case of failure
- the lower 8 bits contain an error code as defined in roc::Board::operErr and is detailed below
- the upper 24 bits contain an index or step number. This allows to reconstruct the point of failure for list or array operations like roc::Board::operGen.
Use the methods
The error codes are
- kOperSuccess: success
- kOperAddrErr: invalid address, there is no ROC resource under this address.
- kOperValueErr: invalid value, the value to be written is not allowed in the current state of the ROC or ROC peripheral. Only returned for write type operations.
- kOperStateErr: invalid state, the operation is not allowed in the current state of the ROC or ROC peripheral.
- kOperNetworkErr: network communication error.
- kOperVerifyErr: verify mismatch, a readback after a write operations yielded a value different from the written one. Only returned by dedicated write type operations, the method name often ends in ...Verify.
- kOperBusErr: secondary bus error. This is returned when a field bus operation, like on a I2C bus, failed.