|
dxd - dynax driver framework 3.0.2
cross platform open source driver development framework
|
USB isoc streaming group: one bus frame aligned tick per USB frame, the one thread running the pipes' request pipelines and moving their data. More...
#include <dx_usb_stream_group.h>
Public Types | |
| typedef settings<device_t>::client | client |
| typedef dx::clock<clock::source<device_t>> | clock |
| the one clock of this group, its source freely selectable | |
| typedef dx::source<>::clock_t | clock_t |
| typedef device_t | device_t |
| typedef dx::source<>::event_t | event_t |
| typedef settings_promoted<device_t, store>::type | promoted |
| typedef settings_promoted<device_t, store>::type | promoted |
| typedef device_t::stream_t | stream_t |
| typedef settings<device_t>::transport | transport |
| the group's two sides, reached as transport::/client:: members | |
Public Member Functions | |
| void | conclude() noexcept |
| group(device_t& device) | |
| the group's clock source ticks off the same device's frame counter, by the transport's wait strategy | |
| void | halt() noexcept override |
| the session's end: its pipes run out on the group's thread - from its own tick nothing ticks them, rest() takes them -, then the thread ends and the group rests | |
| realtime& | initialize(const std::chrono::high_resolution_clock::duration& resolution) |
| void | initialize(const typename clock_t::duration& duration) |
| operator event_t&() noexcept | |
| operator event_t*() noexcept | |
| virtual void | sync(const typename clock_t::time_point& now) |
| virtual source& | wait(bool reset= false) |
Static Public Member Functions | |
| static std::string | key(direction::direction direction, uint32_t strategy) |
| static std::string | key(direction::direction direction, uint32_t) |
Public Attributes | |
| listener<dx::listen<std::function<void(const uint32_t &)>>> | iosize_listener |
| a margin defaulted by the device's iosize (a host's tick is its buffer) reloads with it | |
| promoted | safety_offset [direction::directions] |
| promoted | safety_offset [direction::directions] |
| promoted<uint32_t> | start |
| promoted<bool> | started |
| std::map<decltype(stream_t::target.idx()), std::weak_ptr<stream_t>> | streams |
| shared stream ownership: central weak reference per stream, guarded by device | |
| promoted | sync_strategy |
| promoted | sync_strategy |
Protected Member Functions | |
| void | discharge() noexcept override |
| the session's end on its own thread: the group rests, each pipe that lost frames reported once | |
| bool | locking() const |
| the device's clock is still locking to a sample rate set: the session neither charges nor submits | |
| virtual void | notify() noexcept |
| void | run() override |
| a group streams as a unit: the streams of its descs no client opened yet are opened ahead of the session, so a client joining it finds its stream visited | |
| bool | self() const |
| the caller is the clock's own thread: a halt from its tick ends the loop, nobody joins it | |
| void | tick() override |
| this bus's own transport, ticked per bus frame by its clock source: the session's tick, once the device's clock locked to its rate - a rate change ending charges once locked | |
Protected Attributes | |
| std::condition_variable | condition_variable |
| device_t& | device |
| also the mutex serializing membership | |
| _event_t | event |
| std::function<void()> | flush_hook |
| std::function<void()> | halt_hook |
| std::vector<std::shared_ptr<stream_t>> | members |
| the session's streams: taken before the thread starts, released at its end - the tick visits them without a lock | |
| dx::stream::clock::monitor* | monitor |
| device.monitor cached at the session's start: the tick never maps shared memory | |
| std::mutex | mutex |
| _clock_t::time_point | objective |
| const dx::stream::direction::direction& | order{this->device.start_stop_order} |
| the direction the device stops first | |
| unsigned int | reference{} |
| the stream whose advance drives the clock domain, by its target index (0: none) | |
| std::function<void()> | run_hook |
| std::atomic<bool> | running |
| os_result | status |
| const struct device_t::desc_t::stream* | sync_reference |
| device.sync_reference cached: the tick never reads the promoted | |
Friends | |
| struct | isoc::session<group> |
USB isoc streaming group: one bus frame aligned tick per USB frame, the one thread running the pipes' request pipelines and moving their data.
|
inherited |
|
inherited |
the one clock of this group, its source freely selectable
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
the group's two sides, reached as transport::/client:: members
|
inline |
the group's clock source ticks off the same device's frame counter, by the transport's wait strategy
|
inlinenoexceptinherited |
|
inlineoverrideprotectednoexcept |
the session's end on its own thread: the group rests, each pipe that lost frames reported once
|
inlineoverridenoexcept |
the session's end: its pipes run out on the group's thread - from its own tick nothing ticks them, rest() takes them -, then the thread ends and the group rests
|
inlineinherited |
|
inlineinherited |
|
inlinestaticinherited |
|
inlinestaticinherited |
|
inlineprotected |
the device's clock is still locking to a sample rate set: the session neither charges nor submits
|
inlineprotectedvirtualnoexceptinherited |
notify change from device requiring streaming reset
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlineoverrideprotected |
a group streams as a unit: the streams of its descs no client opened yet are opened ahead of the session, so a client joining it finds its stream visited
|
inlineprotectedinherited |
the caller is the clock's own thread: a halt from its tick ends the loop, nobody joins it
|
inlinevirtualinherited |
|
inlineoverrideprotected |
this bus's own transport, ticked per bus frame by its clock source: the session's tick, once the device's clock locked to its rate - a rate change ending charges once locked
|
inlinevirtualinherited |
|
friend |
|
protectedinherited |
|
protectedinherited |
also the mutex serializing membership
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
inherited |
a margin defaulted by the device's iosize (a host's tick is its buffer) reloads with it
|
protectedinherited |
the session's streams: taken before the thread starts, released at its end - the tick visits them without a lock
|
protectedinherited |
device.monitor cached at the session's start: the tick never maps shared memory
|
protectedinherited |
|
protectedinherited |
|
protected |
the direction the device stops first
|
protected |
the stream whose advance drives the clock domain, by its target index (0: none)
|
protectedinherited |
|
protectedinherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
protectedinherited |
|
inherited |
shared stream ownership: central weak reference per stream, guarded by device
|
protectedinherited |
device.sync_reference cached: the tick never reads the promoted
|
inherited |
|
inherited |