USB Control operations

Name

USB Control operations -- connect, controlOp, listUSBControlServers

Synopsis

package require Tk

package require usbcontrolclient

set connectionObject [connect]

controlOp object args...

listUSBControlServers host prefix

DESCRIPTION

The commands described in this page provide some simple, non object-oriented interfaces to the control server.

connect connects to the default port localhost control server (localhost:27000), and returns a controlClient object bound to that connection. See controlClient for information about what you can do with one of these objects. Normally you set the return value of this command to a variable which is then used as the base command for a command in the command ensemble supported by controlClient objecdts.

controlOp performs an operation on a control server. The control server is encapsulated inobject which is an instance of controlClient. The remaining parameters are a method name and its parameters. For example, if you have a control object in the variable server and want to set the value of the george parameter of the driver instance named tom to 3 you would:


controlOp $server Set tom george 3.
            

listUSBControlServers returns a possibly empty list of information about control servers registered with the port manager. host identifies which host is being queried. prefix identifies which type of server is being requested. At this point it should be one of the values VMUSBReadout or CCUSBReadout.

The returned value is a properly formatted Tcl list. Each element of the list is a pair containing in order a string identifying the USB controller that is connected to the server and the IP port on which that server is listening. If the readout program was run on a specific interface by specifying the --serial option, the controller identifer is the serial number of the devices. If the readout program did not specify a --serial, the text FirstController is provided. If the controller controlled via a network connection to a usb controller server, the identifier is the name of the host on which the server is running (value of the --host option the readout program is running with).