diff options
| author | More Figs <morefigs@gmail.com> | 2017-06-29 17:37:59 +1000 |
|---|---|---|
| committer | More Figs <morefigs@gmail.com> | 2017-06-29 17:37:59 +1000 |
| commit | 8ffcabc0e2a541385d5264d2bf112a1337d65a50 (patch) | |
| tree | d2856fa42e6ee4c17050e94a9183eef5413ad712 | |
| parent | f54f656daba78957a92f6dffd43c95949aba1703 (diff) | |
| download | pymba-8ffcabc0e2a541385d5264d2bf112a1337d65a50.tar.gz pymba-8ffcabc0e2a541385d5264d2bf112a1337d65a50.zip | |
updated print statements
| -rw-r--r-- | README.md | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -21,7 +21,7 @@ Checking the version using a context manager: from pymba import * with Vimba() as vimba: - print vimba.getVersion() + print(vimba.getVersion()) Or without using a context manager: @@ -29,7 +29,7 @@ Or without using a context manager: vimba = Vimba() vimba.startup() - print vimba.getVersion() + print(vimba.getVersion()) vimba.shutdown() ### Interacting with cameras @@ -50,7 +50,7 @@ Discover, open, manipulate, and capture frames from a camera. time.sleep(0.2) cameraIds = vimba.getCameraIds() for cameraId in cameraIds: - print 'Camera ID:', cameraId + print(cameraId) # get and open a camera camera0 = vimba.getCamera(cameraIds[0]) @@ -59,10 +59,10 @@ Discover, open, manipulate, and capture frames from a camera. # list camera features cameraFeatureNames = camera0.getFeatureNames() for name in cameraFeatureNames: - print 'Camera feature:', name + print(name) # get the value of a feature - print camera0.AcquisitionMode + print(camera0.AcquisitionMode) # set the value of a feature camera0.AcquisitionMode = 'SingleFrame' @@ -110,7 +110,7 @@ Get a reference to the Vimba system object and list available system features. # list system features for featureName in system.getFeatureNames(): - print 'System feature:', featureName + print(featureName) ### Interacting with transport layer interfaces @@ -122,7 +122,7 @@ Get a reference to an interface object and list available interface features. # get list of available interfaces interfaceIds = vimba.getInterfaceIds() for interfaceId in interfaceIds: - print 'Interface ID:', interfaceId + print(interfaceId) # get interface object and open it interface0 = vimba.getInterface(interfaceIds[0]) @@ -131,7 +131,7 @@ Get a reference to an interface object and list available interface features. # list interface features interfaceFeatureNames = interface0.getFeatureNames() for name in interfaceFeatureNames: - print 'Interface feature:', name + print(name) # close interface interface0.closeInterface() @@ -145,7 +145,7 @@ Get a reference to an interface object and list available interface features. try: with Vimba() as vimba: except VimbaException as e: - print e.message + print(e.message) |
