|
BNO08X Driver 0.1.0
API reference
|
Errors, results, configuration, events and unit helpers. More...
Classes | |
| struct | bno08x::Result< T > |
| The value of a call, or why there is none. More... | |
| struct | bno08x::Result< void > |
| The result of a call that returns no value. More... | |
| struct | bno08x::Event |
One thing the driver reports, taken with Bno08x::PopEvent(). More... | |
| struct | bno08x::Stats |
| Counters of everything the driver dropped, repaired or noticed. Never reset by the driver. More... | |
| struct | bno08x::FeatureConfig |
| The common feature report of one sensor (RM S6.5.2). More... | |
| struct | bno08x::ProductId |
| Product ID response (RM S6.3.2). More... | |
| struct | bno08x::Metadata |
| Sensor metadata record (RM Figures 28 and 29, record IDs 0xE301 to 0xE325). More... | |
| struct | bno08x::FrsBuffer |
A caller-owned buffer for ReadFrs(); it must outlive the operation. More... | |
| struct | bno08x::MeCal |
| The motion engine's calibration enables (RM S6.4.6). More... | |
| struct | bno08x::Quat14 |
| A quaternion in Q14 (RM S6.4.3.3): the set-reorientation argument. More... | |
| struct | bno08x::WheelSample |
| One wheel measurement for dead reckoning (RM S6.4.13). More... | |
| struct | bno08x::RvcFrame |
| A decoded UART-RVC frame (DS p21). More... | |
| struct | bno08x::Config |
The configuration of a session. Config{} is the recommended setup for a BNO085. More... | |
Typedefs | |
| using | bno08x::OpId = uint16_t |
An operation number returned by every call that completes later with an OpDone event. | |
Functions | |
| constexpr const char * | bno08x::ToString (Error error) noexcept |
| The name of an error, for logs. | |
| constexpr bool | bno08x::ToSensorId (uint8_t raw, SensorId &out) noexcept |
Whether raw is one of the sensor IDs of SensorId, and if so which. | |
Variables | |
| constexpr std::size_t | bno08x::kSensorSlots = 0x2F |
| Number of slots of the per-sensor tables: sensor IDs 0x01 to 0x2E. | |
| constexpr std::size_t | bno08x::kEventValues = 16 |
Number of values an Event carries. | |
| constexpr std::size_t | bno08x::kFrsMaxWords = 128 |
| Largest FRS record the driver reads or writes, in 32-bit words (Kconfig-free constant). | |
Errors, results, configuration, events and unit helpers.
|
strong |
|
strong |
Axes of a tare (RM S6.4.3.1): 0x07 all axes, 0x04 Z only.
| Enumerator | |
|---|---|
| All | X, Y and Z: reorients every motion output. |
| ZOnly | Z only: changes the heading, not the tilt. |
| X | X only; refused unless |
| Y | Y only; refused unless |
| XY | X and Y; refused unless |
| XZ | X and Z; refused unless |
| YZ | Y and Z; refused unless |
|
strong |
Why a call failed. Every call of the driver returns one of these in its Result.
Values 0 to 9 are the shared base set; chip-specific values start at 16. DeviceIdMismatch and Crc exist for the shared base set only: this chip has no ID register to check and its links carry no CRC, so the driver never returns them.
| Enumerator | |
|---|---|
| Ok | The call succeeded. |
| NotInitialized |
|
| InvalidArgument | An argument or a |
| Bus | A port hook returned |
| Timeout | The hub did not answer in the allowed time. |
| DeviceIdMismatch | Base value; never returned (the BNO08x has no ID register). |
| Crc | Base value; never returned (no link of this chip carries a CRC). |
| Busy | The operation queue is full, or a transmit is still pending. |
| DeviceFault | The hub reported a failure inside a response (a status or error code). |
| Unsupported | The hook or silicon feature this call needs is absent. |
| Framing | A frame rule was broken and the engine resynchronised. |
| HubReset | The hub restarted; the operation was abandoned. |
| Overflow | The event queue or a cargo buffer was full. |
| Refused | The hub answered with a failure status (for example an FRS status). |
| Oversize | A request does not fit one write transfer; nothing was sent. |
| NotAdvertised | The channel or report was never advertised by the hub. |
| Variant | The feature is not available on the configured chip. |
|
strong |
What an Event reports.
| Enumerator | |
|---|---|
| Sensor | A sensor sample: |
| OpDone | An operation finished: |
| FeatureChanged | The hub sent a feature response nobody asked for (a rate change). |
| Reset | The hub restarted; |
| FlushDone | A flush completed for |
| HubError | The SHTP error list: |
| Dropped | Events were lost to a full queue: |
| Rvc | A UART-RVC frame: |
| Sh2Error | An SH-2 error queue entry: |
|
strong |
|
strong |
|
strong |
How an I2C or SPI read sizes its transfers.
| Enumerator | |
|---|---|
| HeaderThenRest | Read the 4-byte header, then exactly the rest as a continuation (default). |
| Fixed | Read |
|
strong |
Every sensor report ID any CEVA document defines (RM S6.5; matrix section 1.8 of the design).
|
strong |
Result of the simple calibration finish (RM S6.4.10.2, R1).
|
strong |
State of the session.
|
strong |
The rotation vector a tare is based on (RM S6.4.3.1, P2).
|
strong |
How the host reaches the hub (strapped by PS1 and PS0 at reset, DS p9 Figure 1-5).
|
strong |
|
constexprnoexcept |
Whether raw is one of the sensor IDs of SensorId, and if so which.
| raw | A report ID. | |
| [out] | out | The sensor, set only when the function returns true. |
SensorId.
|
constexprnoexcept |
The name of an error, for logs.
| error | The error. |
"Timeout"; "Unknown" for a value that is not an enumerator.