IDS Peak comfortSDK, genericSDK, AFL, ICL, and IPL developer manuals are external documents.
Please contact us if you need these manuals.
Using the DeviceManager the following callbacks can be registered and unregistered:
•DeviceFound / DeviceLost
•DeviceDisconnected / DeviceReconnected (see also Reconnect)
•DeviceListChanged (see also Update)
•InterfaceFound / InterfaceLost
•SystemFound / SystemLost
// register DeviceFound callback
auto callbackHandle = deviceManager.RegisterDeviceFoundCallback([](const std::shared_ptr<peak::core::DeviceDescriptor>& foundDevice)
{
std::cout << "DeviceFound: " << foundDevice->DisplayName() << std::endl;
});
// unregister DeviceFound callback
deviceManager.UnregisterDeviceFoundCallback(callbackHandle);
|

|
Note: With the switch to NuGet, the namespaces were renamed to follow C# conventions. You find migration tables in the ReadMe file of the respective NuGet package, see https://www.nuget.org/profiles/IDS_Imaging.
The following examples use the namespace as it was used up to IDS peak 2.19.
|
// define DeviceFound callback
static void DeviceFoundDelegate(object o, DeviceDescriptor dev)
{
Console.WriteLine("C# static function DeviceFound: {0}", dev.DisplayName());
}
...
// register DeviceFound callback
deviceManager.DeviceFoundEvent += DeviceFoundDelegate;
// unregister DeviceFound callback
deviceManager.DeviceFoundEvent -= DeviceFoundDelegate;
|
Also the following timeouts can be set:
•DeviceUpdate
•InterfaceUpdate
•SystemUpdate