Line Inverter#
All high (1) signals are converted to low (0) signals and vice versa.
Using the Feature#
Enabling the Line Inverter#
Info
Enable the line inverter only when the I/O lines are not in use. Otherwise, the camera may show unpredictable behavior.
- Set the
LineSelector
parameter to the desired I/O line. - Set the
LineInverter
parameter to true to invert the electrical signal level of the I/O line selected or to false to disable inversion.
Sample Code#
// Select Line 1
camera.LineSelector.SetValue(LineSelector_Line1);
// Enable the line inverter for the I/O line selected
camera.LineInverter.SetValue(true);
INodeMap& nodemap = camera.GetNodeMap();
// Select Line 1
CEnumParameter(nodemap, "LineSelector").SetValue("Line1");
// Enable the line inverter for the I/O line selected
CBooleanParameter(nodemap, "LineInverter").SetValue(true);
// Select Line 1
camera.Parameters[PLCamera.LineSelector].SetValue(PLCamera.LineSelector.Line1);
// Enable the line inverter for the I/O line selected
camera.Parameters[PLCamera.LineInverter].SetValue(true);
/* Macro to check for errors */
#define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc)
GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */
/* Select Line 1 */
errRes = PylonDeviceFeatureFromString(hdev, "LineSelector", "Line1");
CHECK(errRes);
/* Enable the line inverter for the I/O line selected */
errRes = PylonDeviceSetBooleanFeature(hdev, "LineInverter", 1);
CHECK(errRes);
You can also use the pylon Viewer to easily set the parameters.