Documentation ¶
Overview ¶
Package e36xx implements the IVI driver for the Agilent/Keysight E3600 series of power supplies.
State Caching: Not implemented
Index ¶
- func AvailableCOMPorts() []string
- func DefaultGPIBAddress() int
- func DefaultSerialBaudRate() int
- func DefaultSerialDataFrame() string
- func SerialBaudRates() []int
- func SerialConfig() string
- func SerialDataFrames() []string
- type Channel
- func (ch *Channel) ConfigureCurrentLimit(behavior dcpwr.CurrentLimitBehavior, limit float64) error
- func (ch *Channel) ConfigureOVP(b bool, limit float64) error
- func (ch *Channel) ConfigureOutputRange(rt dcpwr.RangeType, rng float64) error
- func (ch *Channel) CurrentLimit() (float64, error)
- func (ch *Channel) CurrentLimitBehavior() (dcpwr.CurrentLimitBehavior, error)
- func (ch *Channel) DisableOVP() error
- func (ch *Channel) DisableOutput() error
- func (ch *Channel) EnableOVP() error
- func (ch *Channel) EnableOutput() error
- func (ch *Channel) MeasureCurrent() (float64, error)
- func (ch *Channel) MeasureVoltage() (float64, error)
- func (ch *Channel) OVPEnabled() (bool, error)
- func (ch *Channel) OVPLimit() (float64, error)
- func (ch *Channel) OutputEnabled() (bool, error)
- func (ch *Channel) QueryCurrentLimitMax(voltage float64) (float64, error)
- func (ch *Channel) QueryOutputState(os dcpwr.OutputState) (bool, error)
- func (ch *Channel) QueryVoltageLevelMax(currentLimit float64) (float64, error)
- func (ch *Channel) ResetOutputProtection() error
- func (ch *Channel) SetCurrentLimit(limit float64) error
- func (ch *Channel) SetCurrentLimitBehavior(behavior dcpwr.CurrentLimitBehavior) error
- func (ch *Channel) SetOVPEnabled(v bool) error
- func (ch *Channel) SetOVPLimit(limit float64) error
- func (ch *Channel) SetOutputEnabled(v bool) error
- func (ch *Channel) SetVoltageLevel(amp float64) error
- func (ch *Channel) VoltageLevel() (float64, error)
- type E36xx
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AvailableCOMPorts ¶ added in v0.6.1
func AvailableCOMPorts() []string
AvailableCOMPorts lists the avaialble COM ports, including optional ports.
func DefaultGPIBAddress ¶ added in v0.6.1
func DefaultGPIBAddress() int
DefaultGPIBAddress lists the default GPIB interface address.
func DefaultSerialBaudRate ¶ added in v0.6.1
func DefaultSerialBaudRate() int
DefaultSerialBaudRate returns the default baud rate for the RS-232 serial port.
func DefaultSerialDataFrame ¶ added in v0.6.1
func DefaultSerialDataFrame() string
DefaultSerialDataFrame returns the default RS-232 data frame format.
func SerialBaudRates ¶ added in v0.6.1
func SerialBaudRates() []int
SerialBaudRates lists the available baud rates for the RS-232 serial port from the fastest to the slowest.
func SerialConfig ¶ added in v0.6.1
func SerialConfig() string
SerialConfig lists whether the RS-232 serial port is configured as a DCE (Data Circuit-Terminating Equipment) or a DTE (Data Terminal Equipment). Computers running the IVI program are DTEs; therefore, use a straight through serial cable when connecting to DCEs and a null modem cable when connecting to DTEs.
func SerialDataFrames ¶ added in v0.6.1
func SerialDataFrames() []string
SerialDataFrames lists the available RS-232 data frame formats.
Types ¶
type Channel ¶
Channel models an E36xx DC power supply output channel.
func (*Channel) ConfigureCurrentLimit ¶ added in v0.6.1
func (ch *Channel) ConfigureCurrentLimit(behavior dcpwr.CurrentLimitBehavior, limit float64) error
ConfigureCurrentLimit configures the current limit. It specifies the output current limit value and the behavior of the power supply when the output current is greater than or equal to that value.
ConfigureCurrentLimit implements the IviDCPwrBase function described in Section 4.3.1 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) ConfigureOVP ¶ added in v0.6.1
ConfigureOVP configures the Over-Voltage Protection (OVP). It specifies the over-voltage limit and the behavior of the power supply when the output voltage is greater than or equal to that value. When the Enabled parameter is False, the Limit parameter does not affect the instrument’s behavior, and the driver does not set the OVP Limit attribute.
ConfigureOVP implements the IviDCPwrBase function described in Section 4.3.4 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) ConfigureOutputRange ¶ added in v0.6.1
ConfigureOutputRange configures either the power supply’s output voltage or current range on an output. Setting a voltage range can invalidate a previously configured current range. Setting a current range can invalidate a previously configured voltage range.
ConfigureOutputRange implements the IviDCPwrBase function described in Section 4.3.3 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) CurrentLimit ¶
CurrentLimit determines the output current limit. The units are Amps.
CurrentLimit implements the getter for the read-write IviDCPwrBase Attribute Current Limit described in Section 4.2.1 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) CurrentLimitBehavior ¶
func (ch *Channel) CurrentLimitBehavior() (dcpwr.CurrentLimitBehavior, error)
CurrentLimitBehavior determines the behavior of the power supply when the output current is equal to or greater than the value of the Current Limit attribute. The E3631A only supports the CurrentRegulate behavior.
CurrentLimitBehavior implements the getter for the read-write IviDCPwrBase Attribute Current Limit Behavior described in Section 4.2.2 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) DisableOVP ¶ added in v0.6.1
DisableOVP is a convenience function for disabling Over-Voltage Protection (OVP). DisableOVP always returns nil for the E3631A since support OVP.
func (*Channel) DisableOutput ¶
DisableOutput is a convenience function for setting the Output Enabled attribute to false.
func (*Channel) EnableOVP ¶ added in v0.6.1
EnableOVP is a convenience function for enabling Over-Voltage Protection (OVP). EnableOVP always returns an error for the E3631A since support OVP.
func (*Channel) EnableOutput ¶
EnableOutput is a convenience function for setting the Output Enabled attribute to true.
func (*Channel) MeasureCurrent ¶
MeasureCurrent takes a measurement on the output signal and returns the measured current.
MeasureCurrent implements the IviDCPwrMeasurement function Measure for the Current MeasurementType parameter described in Section 7.2.1 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) MeasureVoltage ¶
MeasureVoltage takes a measurement on the output signal and returns the measured voltage.
MeasureVoltage implements the IviDCPwrMeasurement function Measure for the Voltage MeasurementType parameter described in Section 7.2.1 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) OVPEnabled ¶
OVPEnabled always returns false for the E3631A since it doesn't have OVP.
OVPEnabled is the getter for the read-write IviFgenBase Attribute OVP Enabled described in Section 4.2.4 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) OVPLimit ¶
OVPLimit returns an error, since the E3631A doesn't support Over-Voltage Protection (OVP).
OVPLimit is the getter for the read-write IviDWPwrBase Attribute OVP Limit described in Section 4.2.5 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) OutputEnabled ¶
OutputEnabled determines if all three output channels are enabled or disabled.
OutputEnabled is the getter for the read-write IviDCPwrBase Attribute Output Enabled described in Section 4.2.3 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) QueryCurrentLimitMax ¶ added in v0.6.1
QueryCurrentLimitMax returns the maximum programmable current limit that the power supply accepts for a particular voltage level on an output.
QueryCurrentLimitMax implements the IviDCPwrBase function described in Section 4.3.7 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) QueryOutputState ¶ added in v0.6.1
func (ch *Channel) QueryOutputState(os dcpwr.OutputState) (bool, error)
QueryOutputState returns whether the power supply is in a particular output state.
QueryOutputState implements the IviDCPwrBase function described in Section 4.3.9 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) QueryVoltageLevelMax ¶ added in v0.6.1
QueryVoltageLevelMax returns the maximum programmable voltage level that the power supply accepts for a particular current limit on an output.
QueryVoltageLevelMax implements the IviDCPwrBase function described in Section 4.3.8 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) ResetOutputProtection ¶ added in v0.6.1
ResetOutputProtection resets the power supply output protection after an over-voltage or over-current condition occurs.
ResetOutputProtection implements the IviDCPwrBase function described in Section 4.3.10 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetCurrentLimit ¶
SetCurrentLimit specifies the output current limit in Amperes.
SetCurrentLimit implements the setter for the read-write IviDCPwrBase Attribute Current Limit described in Section 4.2.1 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetCurrentLimitBehavior ¶
func (ch *Channel) SetCurrentLimitBehavior(behavior dcpwr.CurrentLimitBehavior) error
SetCurrentLimitBehavior specifies the behavior of the power supply when the output current is equal to or greater than the value of the current limit attribute. The E3631A only supports the CurrentRegulate behavior, so attempting to set CurrentTrip will result in an error.
CurrentLimitBehavior implements the getter for the read-write IviDCPwrBase Attribute Current Limit Behavior described in Section 4.2.2 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetOVPEnabled ¶
SetOVPEnabled always returns an error for the E3631A since it doesn't have Over-Voltage Protection (OVP).
SetOVPEnabled is the setter for the read-write IviFgenBase Attribute OVP Enabled described in Section 4.2.4 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetOVPLimit ¶
SetOVPLimit returns an error since the E3631A doesn't support Over-Voltage Protection (OVP).
SetOVPLimit is the setter for the read-write IviDCPwrBase Attribute OVP Limit described in Section 4.2.5 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetOutputEnabled ¶
SetOutputEnabled sets all three output channels to enabled or disabled.
SetOutputEnabled is the setter for the read-write IviDCPwrBase Attribute Output Enabled described in Section 4.2.3 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) SetVoltageLevel ¶
SetVoltageLevel specifies the voltage level the DC power supply attempts to generate in Volts.
SetVoltageLevel is the setter for the read-write IviDCPwrBase Attribute Voltage Level described in Section 4.2.6 of IVI-4.4: IviDCPwr Class Specification.
func (*Channel) VoltageLevel ¶
VoltageLevel reads the specified voltage level the DC power supply attempts to generate in Volts.
VoltageLevel is the getter for the read-write IviDCPwrBase Attribute Voltage Level described in Section 4.2.6 of IVI-4.4: IviDCPwr Class Specification.
type E36xx ¶
E36xx provides the IVI driver for the Agilent/Keysight E3600 series of power supplies.
func New ¶
func New(inst ivi.Instrument, reset bool) (*E36xx, error)
New creates a new AgilentE36xx IVI Instrument driver. Currently, only the E3631A model is supported, but in the future as other models are added, the New function will query the instrument to determine the model and ensure it is one of the supported models. If reset is true, then the instrument is reset.
func (*E36xx) OutputCount ¶
OutputCount returns the number of available output channels.
OutputCount is the getter for the read-only IviDCPwrBase Attribute Output Channel Count described in Section 4.2.7 of IVI-4.4: IviDCPwr Class Specification.