#include <can.hpp>
|
uavcan::int16_t | configureFilters (const uavcan::CanFilterConfig *filter_configs, uavcan::uint16_t num_configs) override |
|
uavcan::uint64_t | getErrorCount () const override |
|
uavcan::ICanIface * | getIface (uavcan::uint8_t iface_index) override |
|
uavcan::uint16_t | getNumFilters () const override |
|
uavcan::uint8_t | getNumIfaces () const override |
|
uavcan::uint32_t | getRxQueueOverflowCount () const |
|
bool | hadActivity () |
|
bool | hasEmptyTx () const |
|
bool | hasReadyRx () const |
|
int | init (uavcan::uint32_t bitrate) |
|
bool | isInBusOffState () const |
|
uavcan::int16_t | receive (uavcan::CanFrame &out_frame, uavcan::MonotonicTime &out_ts_monotonic, uavcan::UtcTime &out_ts_utc, uavcan::CanIOFlags &out_flags) override |
|
uavcan::int16_t | select (uavcan::CanSelectMasks &inout_masks, const uavcan::CanFrame *(&)[uavcan::MaxCanIfaces], uavcan::MonotonicTime blocking_deadline) override |
|
uavcan::int16_t | send (const uavcan::CanFrame &frame, uavcan::MonotonicTime tx_deadline, uavcan::CanIOFlags flags) override |
|
Public Member Functions inherited from uavcan::ICanDriver |
virtual const ICanIface * | getIface (uint8_t iface_index) const |
|
virtual int16_t | select (CanSelectMasks &inout_masks, const CanFrame *(&pending_tx)[MaxCanIfaces], MonotonicTime blocking_deadline)=0 |
|
virtual | ~ICanDriver () |
|
virtual int16_t | receive (CanFrame &out_frame, MonotonicTime &out_ts_monotonic, UtcTime &out_ts_utc, CanIOFlags &out_flags)=0 |
|
virtual int16_t | send (const CanFrame &frame, MonotonicTime tx_deadline, CanIOFlags flags)=0 |
|
virtual | ~ICanIface () |
|
This class implements CAN driver interface for libuavcan. No configuration needed other than CAN baudrate. This class is a singleton.
Definition at line 16 of file platform_specific_components/lpc11c24/libuavcan/driver/include/uavcan_lpc11c24/can.hpp.
◆ CanDriver()
uavcan_lpc11c24::CanDriver::CanDriver |
( |
| ) |
|
|
inlineprivate |
◆ configureFilters()
Configure the hardware CAN filters. CanFilterConfig.
- Returns
- 0 = success, negative for error.
Implements uavcan::ICanIface.
Definition at line 469 of file can.cpp.
◆ detectBitRate()
uavcan::uint32_t uavcan_lpc11c24::CanDriver::detectBitRate |
( |
void(*)() |
idle_callback = nullptr | ) |
|
|
static |
Attempts to detect bit rate of the CAN bus. This function may block for up to X seconds, where X is the number of bit rates to try. This function is NOT guaranteed to reset the CAN controller upon return.
- Returns
- On success: detected bit rate, in bits per second. On failure: zero.
Definition at line 171 of file can.cpp.
◆ getErrorCount()
Continuously incrementing counter of hardware errors. Arbitration lost should not be treated as a hardware error.
Implements uavcan::ICanIface.
Definition at line 541 of file can.cpp.
◆ getIface()
Returns an interface by index, or null pointer if the index is out of range.
Implements uavcan::ICanDriver.
Definition at line 552 of file can.cpp.
◆ getNumFilters()
◆ getNumIfaces()
Total number of available CAN interfaces. This value shall not change after initialization.
Implements uavcan::ICanDriver.
Definition at line 557 of file can.cpp.
◆ getRxQueueOverflowCount()
Returns the number of times the RX queue was overrun.
Definition at line 350 of file can.cpp.
◆ hadActivity()
bool uavcan_lpc11c24::CanDriver::hadActivity |
( |
| ) |
|
This method will return true only if there was any CAN bus activity since previous call of this method. This is intended to be used for LED iface activity indicators.
Definition at line 342 of file can.cpp.
◆ hasEmptyTx()
bool uavcan_lpc11c24::CanDriver::hasEmptyTx |
( |
| ) |
const |
◆ hasReadyRx()
bool uavcan_lpc11c24::CanDriver::hasReadyRx |
( |
| ) |
const |
◆ init()
Returns negative value if the requested baudrate can't be used. Returns zero if OK.
Definition at line 274 of file can.cpp.
◆ instance()
static CanDriver& uavcan_lpc11c24::CanDriver::instance |
( |
| ) |
|
|
inlinestatic |
◆ isInBusOffState()
bool uavcan_lpc11c24::CanDriver::isInBusOffState |
( |
| ) |
const |
Whether the controller is currently in bus off state. Note that the driver recovers the CAN controller from the bus off state automatically! Therefore, this method serves only monitoring purposes and is not necessary to use.
Definition at line 356 of file can.cpp.
◆ receive()
◆ select()
◆ send()
◆ self
The documentation for this class was generated from the following files: