public IRRADIANCE() { InitializeComponent(); // Initializing the Device PM 400 with Address: 'USB0::0x1313::0x8075::P5000256::INSTR' try { pm100d = new PM100D("USB0::0x1313::0x8075::P5000256::INSTR", true, false); // For valid Ressource_Name see NI-Visa documentation. } catch (BadImageFormatException bie) { labelPower.Text = bie.Message; } catch (NullReferenceException nre) { labelPower.Text = nre.Message; } catch (ExternalException ex) { labelPower.Text = ex.Message; } finally { if (pm100d != null) { pm100d.Dispose(); } } }
private void btnIR_Start_Click(object sender, EventArgs e) { pm100d = new PM100D("USB0::0x1313::0x8075::P5000256::INSTR", true, false); // For valid Ressource_Name see NI-Visa documentation. timer1.Enabled = true; btnIR_Start.Enabled = false; btnIR_Stop.Enabled = true; }
/// <summary> /// Monitor power construct with Device Name /// </summary> public MonitorPowerModel(string name, double wavelen, double pow) { pm = new PM100D(name, true, true); waveLength = waveLength; power = pow; }