In addition: instead of simply loading the GenICam.vin, you might want to use our discover interface to be a bit more flexible in which of the devices you actually want to open.
The code would look like this:
devices = cvb.DeviceFactory.discover_from_root(cvb.DiscoverFlags.IgnoreTLs | cvb.DiscoverFlags.IgnoreGevSD)
with cvb.DeviceFactory.open(devices[0].access_token, cvb.AcquisitionStack.Vin) as device:
test = "donothing"
At this point however, I would like to suggest to you to use our latest acquisitionstack (3rd gen).
The code for discorvering devices and loading them in this case looks like this:
devices = DeviceFactory.discover_from_root(DiscoverFlags.IgnoreVins) # or any other flag combination e.g.
devices = DeviceFactory.discover_from_root(cvb.DiscoverFlags.IgnoreVins | DiscoverFlags.IgnoreGevSD)
with DeviceFactory.open(devices[0].access_token, AcquisitionStack.GenTL) as device: