From 779a62a3b24e0cb41be1be6ed0beb948a8bab604 Mon Sep 17 00:00:00 2001 From: morefigs Date: Tue, 23 Apr 2019 10:16:30 +1000 Subject: Note on setting feature name as an object attribute --- examples/camera/set_feature_value.py | 1 + examples/interface/set_feature_value.py | 1 + 2 files changed, 2 insertions(+) diff --git a/examples/camera/set_feature_value.py b/examples/camera/set_feature_value.py index c02f961..7086d75 100644 --- a/examples/camera/set_feature_value.py +++ b/examples/camera/set_feature_value.py @@ -20,6 +20,7 @@ if __name__ == '__main__': print('"{}" was set to "{}"'.format(feature.name, feature.value)) # alternatively the feature value can be set as an object attribute + # note that this doesn't raise an error if the feature name doesn't exist camera.ExposureAuto = feature.value camera.close() diff --git a/examples/interface/set_feature_value.py b/examples/interface/set_feature_value.py index a9f32da..4eca205 100644 --- a/examples/interface/set_feature_value.py +++ b/examples/interface/set_feature_value.py @@ -20,6 +20,7 @@ if __name__ == '__main__': print('"{}" was set to "{}"'.format(feature.name, feature.value)) # alternatively the feature value can be set as an object attribute + # note that this doesn't raise an error if the feature name doesn't exist interface.InterfacePingPace = 3 interface.close() -- cgit v1.2.3