Implements a software-based GigE Vision Device with full GVCP and GVSP support. More...
Public Member Functions | |
PvSoftDeviceGEV () | |
Constructor. | |
virtual | ~PvSoftDeviceGEV () |
Destructor. | |
IPvSoftDeviceGEVInfo * | GetInfo () |
Obtains the information interface of the PvSoftDeviceGEV. More... | |
PvResult | AddStream (IPvStreamingChannelSource *aSource) |
Adds a new stream to the PvSoftDeviceGEV. More... | |
PvResult | SetUserSetCount (uint32_t aCount) |
PvResult | SetPassthru (bool aPassthruEnabled, PvString aPassthruDevice) |
Create the device in Passthru mode. More... | |
PvResult | SetMalformedXMLFile (PvString aMalformedXMLFile) |
Set a destination for malformed xml files. More... | |
PvResult | SetTCPTransportEnabled (bool aEnabled) |
Enables experimental TCP transport. More... | |
PvResult | SetRTPProtocolEnabled (bool aEnabled) |
Enables the option of using RTP for streaming. More... | |
PvResult | SetStreamTimestamping (bool aEnabled) |
Enables stream timestamping on all sources. 'True' by default. More... | |
IPvRegisterMap * | GetRegisterMap () |
Obtains the register map interface of the PvSoftDeviceGEV. More... | |
PvResult | Start (const PvString &aMACAddress) |
Starts the PvSoftDeviceGEV. More... | |
PvResult | Stop () |
Stops the PvSoftDeviceGEV. More... | |
IPvSoftDeviceGEVStatistics * | GetStatistics () |
Obtains the statistics interface of the PvSoftDeviceGEV. More... | |
IPvMessageChannel * | GetMessagingChannel () |
Obtains the messaging channel interface of the PvSoftDeviceGEV. More... | |
PvResult | RegisterEventSink (IPvSoftDeviceGEVEventSink *aEventSink) |
Registers an event sink to receive notifications from the PvSoftDeviceGEV. More... | |
PvResult | UnregisterEventSink (IPvSoftDeviceGEVEventSink *aEventSink) |
Unregisters a previously registered event sink. More... | |
PvResult | GetGenICamXMLFile (PvString &aString) const |
Returns the GenICam XML file of the device. More... | |
![]() | |
virtual | ~IPvSoftDeviceGEV () |
Virtual destructor. | |
Protected Member Functions | |
PvSoftDeviceGEV (PvVirtualDeviceLib::IFactory *aFactory) | |
Protected Constructor. More... | |
Implements a software-based GigE Vision Device with full GVCP and GVSP support.
Basic GigE Vision Device setup:
A more advanced GigE Vision Device setup:
|
protected |
Protected Constructor.
[in] | aFactory | The factory object to instantiate the PvSoftDeviceGEV. |
|
virtual |
Adds a new stream to the PvSoftDeviceGEV.
All streams must be added before starting the PvSoftDeviceGEV.
[in] | aSource | Interface to a user-provided source. |
Implements IPvSoftDeviceGEV.
Returns the GenICam XML file of the device.
Can be used to retrieve the GenICam XML file of the device after the Start method has been called. Can be used on success or failure of the Start method.
aString | [out] String where the XML file is copied. |
Implements IPvSoftDeviceGEV.
|
virtual |
Obtains the information interface of the PvSoftDeviceGEV.
Only available after the PvSoftDeviceGEV has been started.
IPvSoftDeviceGEVInfo is used to set the information strings in the read-only bootstrap registers of the PvSoftDeviceGEV, such as Model Name, Vendor Name, etc.
Implements IPvSoftDeviceGEV.
|
virtual |
Obtains the messaging channel interface of the PvSoftDeviceGEV.
The IPvMessageChannel interface can be used to send events on the messaging channel when a GigE Vision controller is connected to the PvSoftDeviceGEV and has properly set up a destination for messaging channel events.
Only available after the PvSoftDeviceGEV has been started.
Implements IPvSoftDeviceGEV.
|
virtual |
Obtains the register map interface of the PvSoftDeviceGEV.
Only available after the PvSoftDeviceGEV has been started.
IPvRegisterMap can be used to directly access the register map of the PvSoftDeviceGEV. It is also possible to subscribe to register read/write events using IPvSoftDeviceGEVEventSink.
See IPvSoftDeviceGEVEventSink::OnCreateCustomRegisters for information about adding custom registers to a PvSoftDeviceGEV.
Implements IPvSoftDeviceGEV.
|
virtual |
Obtains the statistics interface of the PvSoftDeviceGEV.
Only available after the PvSoftDeviceGEV has been started.
Implements IPvSoftDeviceGEV.
|
virtual |
Registers an event sink to receive notifications from the PvSoftDeviceGEV.
This method can be called before the PvSoftDeviceGEV is started.
[in] | aEventSink | Pointer to a PvSoftDeviceGEV event sink. |
Implements IPvSoftDeviceGEV.
Set a destination for malformed xml files.
[in] | aMaformedXMLFile | Full path to where to store malformed xml file |
Implements IPvSoftDeviceGEV.
Create the device in Passthru mode.
[in] | aPassthruEnbled | Set to true to enable passthru behaviour. |
[in] | aPassthruDevice | Description of Remote Device for passthru |
Implements IPvSoftDeviceGEV.
|
virtual |
Enables the option of using RTP for streaming.
PvSoftDeviceGEV supports optional RTP protocol for GigE Vision devices.
When RTP is enabled it can be selected as the protocol used to data transmission at the stream channel level of the GenApi interface of the device.
RTP supported is not covered by the GigE Vision specification. A GigE Vision Device actively streaming using RTP goes beyond the bounds covered by the GigE Vision standard.
The RTP implementation is however compliant with the RTP RFCs covering the transport of images (RFC 4175) and H.264 data (RFC 6184).
When a stream transmits using the RTP protocol, the stream is announced on a multicast channel (224.2.127.254:9875) using the SAP protocol with a SDP descriptor as required by the DEFSTAN 0082 specification.
[in] | aEnabled | Toggles RTP support. |
Implements IPvSoftDeviceGEV.
PvResult PvSoftDeviceGEV::SetStreamTimestamping | ( | bool | aEnabled | ) |
Enables stream timestamping on all sources. 'True' by default.
Buffers are timestamped by the acquisition manager. This method can be called with a 'False' value to skip timestamping when placing the buffers into the queue.
This method can be useful in a scenario where the original timestamp of the buffer needs to be preserved, or if the timestamp is updated externally (in the application). Doing so will prevent the acquisition manager to override the timestamp before transmission.
The method does not affect GenICam registers or message channel timestamps.
[in] | aEnabled | Toggles stream timestamping. |
|
virtual |
Enables experimental TCP transport.
PvSoftDeviceGEV supports optional, experimental TCP transport for GigE Vision devices. It affects GVCP control, GVCP messaging channel and GVSP streaming.
When TCP is enabled the device still respond to UDP requests as usual. Additional TCP sockets are opened to optionally accept TCP connections from the host.
As long as TCP is not fully ratified by the GigE Vision specification, enabling TCP could and most likely will break GigE Vision compliance. It also means only the eBUS PvDeviceGEV and PvStreamGEV can be used to interact with the device when using TCP transport.
[in] | aEnabled | Toggles TCP support. |
Implements IPvSoftDeviceGEV.
|
virtual |
Selected registers handling in pseudo-code:
The IPvRegisterStore::Persist method loads or saves the register content in the store using the feature name and provided suffix.
On startup the default user-set is always updated in the store from the fresh device status. If the UserSetDefault GenApi feature is assigned to a user-set other than Default, the user-set is automatically loaded on device startup.
The UserSetDefault GenApi feature is special: it is not saved to a user-set but is immediately and automatically persistent to the store whenever changed.
User-sets can be saved and loaded explicitly using the UserSetSelector, UserSetSave, and UserSetLoad GenApi features.
The UserSetFeatureSelector and UserSetFeatureEnable GenApi features can be used to control which features are saved to the user-sets. All features defined as Streamable when creating the GenICam XML file of the device should be available under the UserSetFeatureSelector enum feature.
[in] | aCount | Count of user-sets supported, in addition to the default user-set. |
Implements IPvSoftDeviceGEV.
Starts the PvSoftDeviceGEV.
Both GVCP and GVSP are operated from a background thread. Even though the Start method returns, the device is running in your process until you call Stop or until the object is destroyed.
[in] | aMACAddress | MAC address of the interface to bind the PvSoftDeviceGEV to. |
Implements IPvSoftDeviceGEV.
|
virtual |
Stops the PvSoftDeviceGEV.
Implements IPvSoftDeviceGEV.
|
virtual |
Unregisters a previously registered event sink.
This method can be called before the PvSoftDeviceGEV is started and after it has been stopped.
[in] | aEventSink | Pointer to a PvSoftDeviceGEV event sink. |
Implements IPvSoftDeviceGEV.
Copyright (c) 2002-2021 Pleora Technologies Inc.
www.pleora.com