Classes | |
struct | RxItem |
Public Member Functions | |
void | addRxFrame (const uavcan::CanRxFrame &frame, uavcan::CanIOFlags flags) |
void | flushTxQueueTo (uavcan::INode &main_node, std::uint8_t iface_index) |
bool | hasDataInRxQueue () const |
VirtualCanIface (uavcan::IPoolAllocator &allocator, uavcan::ISystemClock &clock, std::mutex &arg_mutex, unsigned quota_per_queue) | |
![]() | |
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 () |
Private Member Functions | |
int16_t | configureFilters (const uavcan::CanFilterConfig *, std::uint16_t) override |
uint64_t | getErrorCount () const override |
uint16_t | getNumFilters () const override |
int16_t | receive (uavcan::CanFrame &out_frame, uavcan::MonotonicTime &out_ts_monotonic, uavcan::UtcTime &out_ts_utc, uavcan::CanIOFlags &out_flags) override |
int16_t | send (const uavcan::CanFrame &frame, uavcan::MonotonicTime tx_deadline, uavcan::CanIOFlags flags) override |
![]() | |
Noncopyable () | |
~Noncopyable () | |
Private Attributes | |
std::mutex & | mutex_ |
uavcan::CanTxQueue | prioritized_tx_queue_ |
Queue< RxItem > | rx_queue_ |
Objects of this class are owned by the sub-node thread. This class does not use heap memory.
Definition at line 140 of file test_multithreading.cpp.
|
inline |
Definition at line 191 of file test_multithreading.cpp.
|
inline |
Note that RX queue overwrites oldest items when overflowed. Call this from the main thread only. No additional locking is required.
Definition at line 203 of file test_multithreading.cpp.
|
inlineoverrideprivatevirtual |
Configure the hardware CAN filters. CanFilterConfig.
Implements uavcan::ICanIface.
Definition at line 186 of file test_multithreading.cpp.
|
inline |
Call this from the main thread only. No additional locking is required.
Definition at line 217 of file test_multithreading.cpp.
|
inlineoverrideprivatevirtual |
Continuously incrementing counter of hardware errors. Arbitration lost should not be treated as a hardware error.
Implements uavcan::ICanIface.
Definition at line 188 of file test_multithreading.cpp.
|
inlineoverrideprivatevirtual |
Number of available hardware filters.
Implements uavcan::ICanIface.
Definition at line 187 of file test_multithreading.cpp.
|
inline |
Call this from the sub-node thread only. No additional locking is required.
Definition at line 242 of file test_multithreading.cpp.
|
inlineoverrideprivate |
Definition at line 165 of file test_multithreading.cpp.
|
inlineoverrideprivate |
Definition at line 158 of file test_multithreading.cpp.
|
private |
Definition at line 154 of file test_multithreading.cpp.
|
private |
Definition at line 155 of file test_multithreading.cpp.
Definition at line 156 of file test_multithreading.cpp.