MCPcopy Create free account
hub / github.com/LabPy/lantz / _get_capabilities

Method _get_capabilities

lantz/drivers/legacy/usbtmc.py:136–145  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

134 raise InstrumentError("TMC device must have both Bulk-In and Bulk-out endpoints.")
135
136 def _get_capabilities(self):
137 cap = self.usb_dev.ctrl_transfer(
138 usb.util.build_request_type(usb.util.CTRL_IN,
139 usb.util.CTRL_TYPE_CLASS,
140 usb.util.CTRL_RECIPIENT_INTERFACE),
141 REQUEST.GET_CAPABILITIES,
142 0x0000,
143 self.usb_intf.index,
144 0x0018,
145 timeout=self.TIMEOUT)
146
147 def _find_interface(self, dev, setting):
148 interfaces = find_interfaces(dev, bInterfaceClass=0xFE, bInterfaceSubClass=3)

Callers 1

__init__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected