[list] =
instrhwinfo ()
¶list =
instrhwinfo (interface)
¶Query available hardware for instrument-control
When run without any input parameters, instrhwinfo will provide the toolbox information and a list of supported interfaces.
interface is the instrument interface to query. When provided, instrhwinfo will provide information on the specified interface.
Currently only interface "serialport","i2c" and "spi" and is supported, which will provide a list of available serial ports or i2c ports.
If an output variable is provided, the function will store the information to the variable, otherwise it will be displayed to the screen.
instrhwinfo scalar structure containing the fields: ToolboxVersion = 0.4.0 ToolboxName = octave instrument control package SupportedInterfaces = { [1,1] = i2c [1,2] = parallel [1,3] = serialport [1,4] = tcp [1,5] = udp [1,6] = usbtmc [1,7] = vxi11 }
name =
resolvehost (host)
¶[name, address] =
resolvehost (host)
¶out =
resolvehost (host, returntype)
¶Resolve a network host name or address to network name and address
host - Host name or IP address string to resolve.
name - Resolved IP host name.
returntype - ’name’ to get host name, ’address’ to get IP address.
name - Resolved IP host name.
address - Resolved IP host address.
out - host name if returntype is ’name’, ipaddress if returntype is ’address’
%% get resolved ip name and address of www.gnu.org [name, address] = resolvehost ('www.gnu.org'); %% get ip address of www.gnu.org ipaddress = resolvehost ('www.gnu.org', 'address');
See also: tcp, udp.