public uint SetCameraBinning(int horzBinning, int vertBinning) { if (!systemInitialized) { return(NOT_INITIALIZED); } uint uiErrorCode; // Set Readout //// set to full resolution for the full image //// params: horizontal binning, vertical binning,horz start pixel, horz end pixel, vert start pixel, vert end pixel uiErrorCode = MyCamera.SetImage(horzBinning, vertBinning, 1, xPixels, 1, yPixels); return(uiErrorCode); }
// This function sets up the camera public void SetUpAndor() { sdk.SetADChannel(ADChannel); int _NumberHSSpeeds = 0; sdk.GetNumberHSSpeeds(ADChannel, 0, ref _NumberHSSpeeds); float _HSSpeedMax = 0; sdk.GetHSSpeed(ADChannel, 0, 0, ref _HSSpeedMax); HSSpeedMax = _HSSpeedMax; float _HSSpeedMin = 0; sdk.GetHSSpeed(ADChannel, 0, _NumberHSSpeeds - 1, ref _HSSpeedMin); HSSpeedMin = _HSSpeedMin; sdk.SetHighCapacity(0); // Note: 1 disables high sensitivity. 0 enables high sensitivity // sdk.SetImage(hbin, vbin, hstart, hend,vstart,vend) sdk.SetImage(1, 1, 1, XDim, 1, YDim); // Use full sensor area sdk.SetAcquisitionMode(AcquisitionMode); sdk.SetReadMode(ReadMode); // These functions control the camera's mode of operation sdk.SetMCPGating(Gating); sdk.SetTriggerMode(TriggerMode); sdk.SetDDGTriggerMode(DDGTriggerMode); sdk.SetGateMode(GateMode); sdk.SetMCPGain(defaultGain); // This functions controls the voltage of the intensifier mcp sdk.SetHSSpeed(0, 0); int vsspeed_i = 0; float vsspeed = 0; sdk.GetFastestRecommendedVSSpeed(ref vsspeed_i, ref vsspeed); sdk.SetVSSpeed(vsspeed_i); }