Commit 8fa6c31c authored by Laurent Claustre's avatar Laurent Claustre

Added attributes for output1 line control

parent 826a4795
Pipeline #15052 passed with stages
in 19 minutes and 26 seconds
......@@ -34,11 +34,19 @@ and might disappear in the future.
Both inter_packet_delay and frame_tranmission_delay properties can be used to tune the GiGE performance, for
more information on how to configure a GiGE Basler camera please refer to the Basler documentation.
Attributes
----------
This camera device has not attribute.
============================== ======= ======================= ============================================================
Attribute name RW Type Description
============================== ======= ======================= ============================================================
statistics_total_buffer_count rw DevLong Total number of requested frames
statistics_failed_buffer_count rw DevLong Total number of failed frames
test_image_selector rw DevString Select a test image: image_off/image_1/.../image_7 **(\*)**
output1_line_source rw DevString Select a source for I/O output1 line **(\*)**
user_output_lin1 rw DevBoolean Switch on/off UserOuput on output1 line **(\*)**
============================== ======= ======================= ============================================================
**(\*)** Use the command getAttrStringValueList to get the list of the supported value for these attributes.
Commands
......
......@@ -192,7 +192,9 @@ class BASLER_EXPORT Camera
// -- change output line source
void setOutput1LineSource(LineSource);
void getOutput1LineSource(LineSource&) const;
void setUserOutputLine1(bool value);
void getUserOutputLine1(bool& value) const;
// -- change acq frame count
void setAcquisitionFrameCount(int AFC);
void getAcquisitionFrameCount(int& AFC) const;
......
......@@ -112,6 +112,8 @@ namespace Basler
// -- change output line source
void setOutput1LineSource(Basler::Camera::LineSource);
void getOutput1LineSource(Basler::Camera::LineSource&) const;
void setUserOutputLine1(bool value);
void getUserOutputLine1(bool& value) const;
// -- change acq frame count
void setAcquisitionFrameCount(int AFC);
......
......@@ -2013,6 +2013,33 @@ void Camera::getOutput1LineSource(Camera::LineSource& source) const
DEB_RETURN() << DEB_VAR1(source);
}
//-----------------------------------------------------
// Set the output line1 to a user value: True on False
// the output line1 source can be overwritten by calling
// setOutput1LineSource()
//-----------------------------------------------------
void Camera::setUserOutputLine1(bool value)
{
DEB_MEMBER_FUNCT();
// set the I/O output1 to be set by the UserOutput value
Camera_->LineSelector.SetValue(LineSelector_Out1);
Camera_->LineSource.SetValue(LineSource_UserOutput);
Camera_->UserOutputSelector.SetValue(UserOutputSelector_UserOutput1);
Camera_->UserOutputValue.SetValue(value);
}
//-----------------------------------------------------
//
//-----------------------------------------------------
void Camera::getUserOutputLine1(bool &value) const
{
DEB_MEMBER_FUNCT();
Camera_->UserOutputSelector.SetValue(UserOutputSelector_UserOutput1);
value = Camera_->UserOutputValue.GetValue();
}
//-----------------------------------------------------
//
//-----------------------------------------------------
......
......@@ -65,7 +65,15 @@ class Basler(PyTango.Device_4Impl):
'TESTIMAGE_6': BaslerAcq.Camera.TestImage_6,
'TESTIMAGE_7': BaslerAcq.Camera.TestImage_7,
}
self.__Output1LineSource = {
'LINESOURCE_OFF': BaslerAcq.Camera.Off,
'LINESOURCE_EXPOSURE_ACTIVE': BaslerAcq.Camera.ExposureActive,
'LINESOURCE_FRAME_TRIGGER_WAIT': BaslerAcq.Camera.FrameTriggerWait,
'LINESOURCE_LINE_TRIGGER_WAIT': BaslerAcq.Camera.LineTriggerWait,
'LINESOURCE_TIMER_ACTIVE': BaslerAcq.Camera.TimerActive,
'LINESOURCE_USER_OUTPUT': BaslerAcq.Camera.UserOutput,
'LINESOURCE_ACQUISITION_TRIGGER_WAIT': BaslerAcq.Camera.AcquisitionTriggerWait,
}
self.__Attribute2FunctionBase = {
}
......@@ -175,7 +183,25 @@ class BaslerClass(PyTango.DeviceClass):
'unit': 'N/A',
'format': '',
'description': 'select a test image image_off/image_1/.../image_7',
}],
}],
'output1_line_source':
[[PyTango.DevString,
PyTango.SCALAR,
PyTango.READ_WRITE],
{
'unit': 'N/A',
'format': '',
'description': 'select a source for I/O output1 line',
}],
'user_output_line1':
[[PyTango.DevBoolean,
PyTango.SCALAR,
PyTango.READ_WRITE],
{
'unit': 'N/A',
'format': '',
'description': 'switch on/off UserOuput on output1 line',
}],
}
def __init__(self,name) :
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment