10-31-2012 09:02 AM
Hi,
we are using CVI 2012 and NI IMAQdx and we want to read out the camera attributes from a GigE vision camera.
We tried the IMAQdxEnumerateAttributes2 function but it didn't work. We got no information back.
Does anyone have an idea how we can read out the camera attributes?
thanks in advance
Oliver
11-06-2012 03:52 AM
Hi Oliver,
the function IMAQdxEnumerateAttributes2 is the right choice for obtaining camera attributes.
Did you stick to the approach mentionend in the manual as follows?
"[IMAQdxEnumerateAttributes2] Gets the attributes supported by the camera. If you do not know in advance the number of features, complete the following steps:
Regards, Topper
11-06-2012 12:39 PM
Hello Topper,
yes we tried this but we didn't succeed.
But meanwhile we know why, here is our solution:
// Open a session to the selected camera
// initialisiert den G4GigE-Zeilensensor
rw = IMAQdxOpenCamera(G4GigE.CamName, IMAQdxCameraControlModeController, &G4GigE.session);
//
IMAQdxEnumerateAttributes2(G4GigE.session, attributeInformationArray, &uiCount, "CameraAttributes::CustomFeatures::Illumination", IMAQdxAttributeVisibilityAdvanced);
//
strcpy(String, "CameraAttributes::CustomFeatures::Illumination::Slot1::Slot_1_RED");
//
IMAQdxSetAttribute(G4GigE.session, String, IMAQdxValueTypeU32, 10);
It is necessary to type in the correct pathname to adress the attribute correctly. The path will be separated by :: If the path is not correct there will be no result.
To get the number of attributes it seams that the highest path name have to be adressed.
since we found this out we could run our application
greetings
Oliver
11-07-2012 06:08 AM
Oliver, thank you for sharing your solution!