Camera Settings
| string[] names =
{
"Width",
"Height",
"image_width",
"image_height"
};
foreach (string name in names)
{
Console.WriteLine($"--- {name} ---");
try
{
HOperatorSet.GetFramegrabberParam(
handle,
name,
out HTuple value);
Console.WriteLine($"value = {value}");
}
catch (Exception ex)
{
Console.WriteLine($"value = ERROR : {ex.Message}");
}
try
{
HOperatorSet.GetFramegrabberParam(
handle,
name + "_access",
out HTuple access);
Console.WriteLine($"access = {access}");
}
catch
{
}
try
{
HOperatorSet.GetFramegrabberParam(
handle,
name + "_range",
out HTuple range);
Console.WriteLine($"range = {range}");
}
catch
{
}
}
|
実カメラがCLPで正常Discoveryされていれば、Remote Device側の
| Width
Height
OffsetX
OffsetY
PixelFormat
|
などがHALCONから見えるはずです。
ところが、
なら、実カメラのRemote Device Featureへ到達できていない可能性が高い
| 1. [Interface]DiscoveryMethod = MixedDiscovery
2. CloseFramegrabber
3. InfoFramegrabber("GenICamTL", "device") で再列挙
4. 実カメラが出るか確認
5. LoadedClpSharedLibraryPath確認
6. Open後に [Device]Height_access を確認
|
判定例
| 1. HALCON interface名を見る
GigEVision2
→ GigE確定
GenICamTL
↓
2. InfoFramegrabber("GenICamTL","info_boards")
のtl_typeを見る
GEV
→ GigE
CXP系
→ CoaXPress
CL系
→ Camera Link
不明
↓
3. producerを見る
ProducerCL.cti
→ Camera Link
Euresys CXP Producer
→ CXP
不明
↓
4. vendor / model / interface を補助判定に使う
それでも不明
→ Unknown
|
producerでの判定例
| if (producer.Contains(
"ProducerCL.cti",
StringComparison.OrdinalIgnoreCase))
{
return CameraTransportType.CameraLink;
}
if (producer.Contains(
"Euresys",
StringComparison.OrdinalIgnoreCase))
{
// CXPかどうかはtl_typeも併用
}
|