Opens a Phidget.

 @param [Integer] serial_number Serial number of the phidget to open, -1 means any.
 @return [Boolean] returns true or raises an error
177518
def open_label_remote_ip(label=nil, server_address=nil, port=5001, password=nil)
		Phidgets::FFI::Common.openLabelRemoteIP(@handle, label, server_address, port, password)
		  
			true
    end
1123883
def get_serial_number_string(self):
        
        self._check_device_status()
        str_p = ffi.new("wchar_t[]", 255)
        rv = hidapi.hid_get_serial_number_string(self._device, str_p, 255)
        if rv == -1:
            raise IOError("Failed to read serial number string from HID "
                          "device: {0}".format(self._get_last_error_string()))
        return ffi.string(str_p)
1320998
def init_hardware(self, serial=None, device_number=ANY_MODULE):
        
        if not self._hw_is_initialized:
            # initialize hardware either by device number or serial
            if serial is None:
                UcanInitHardwareEx(byref(self._handle), device_number, self._callback_ref, None)
            else:
                UcanInitHardwareEx2(byref(self._handle), serial, self._callback_ref, None)
            self._hw_is_initialized = True
177029
def _raw_open(self, flags, mode=0o777):
        
        if self._closed:
            self._raise_closed()
        return self._accessor.open(self, flags, mode)
1020172
def serial_port(self, serial_port):
        
        char_size = get_char_size(serial_port.baudrate)

        # See docstring of get_char_size() for meaning of constants below.
        serial_port.inter_byte_timeout = 1.5 * char_size
        serial_port.timeout = 3.5 * char_size
        self._serial_port = serial_port
1322753
def open(self, name, mode='rb'):
        
        self.request = urlopen(self.url)
        if self.algorithm:
            self.hash = hashlib.new(self.algorithm)
        return self
801466
def _try_open(cls):
    """"""
    handle = None
    for usb_cls, subcls, protocol in [(adb_device.CLASS,
                                       adb_device.SUBCLASS,
                                       adb_device.PROTOCOL),
                                      (fastboot_device.CLASS,
                                       fastboot_device.SUBCLASS,
                                       fastboot_device.PROTOCOL)]:
      try:
        handle = local_usb.LibUsbHandle.open(
            serial_number=cls.serial_number,
            interface_class=usb_cls,
            interface_subclass=subcls,
            interface_protocol=protocol)
        cls.serial_number = handle.serial_number
        return True
      except usb_exceptions.DeviceNotFoundError:
        pass
      except usb_exceptions.MultipleInterfacesFoundError:
        _LOG.warning('Multiple Android devices found, ignoring!')
      finally:
        if handle:
          handle.close()
    return False
229237
def open(cls, typename):
		
		return cls(opcode=OMAPI_OP_OPEN, message=[(b"type", typename)], tid=-1)
722685
def enable_i2c_slave(self, slave_address):
        
        ret = api.py_aa_i2c_slave_enable(self.handle, slave_address,
                self.BUFFER_SIZE, self.BUFFER_SIZE)
        _raise_error_if_negative(ret)
148747
def run_open(state, module, *args, **kwargs):
    
    from ..core import which, ensure_project, inline_activate_virtual_environment

    # Ensure that virtualenv is available.
    ensure_project(
        three=state.three, python=state.python,
        validate=False, pypi_mirror=state.pypi_mirror,
    )
    c = delegator.run(
        '{0} -c "import {1}; print({1}.__file__);"'.format(which("python"), module)
    )
    try:
        assert c.return_code == 0
    except AssertionError:
        echo(crayons.red("Module not found!"))
        sys.exit(1)
    if "__init__.py" in c.out:
        p = os.path.dirname(c.out.strip().rstrip("cdo"))
    else:
        p = c.out.strip().rstrip("cdo")
    echo(crayons.normal("Opening {0!r} in your EDITOR.".format(p), bold=True))
    inline_activate_virtual_environment()
    edit(filename=p)
    return 0
671098
def open(self):
        

        if not self._is_connected:
            
            print("Connecting to arduino on {}... ".format(self.device),end="")

            self.comm = serial.Serial()
            self.comm.port = self.device
            self.comm.baudrate = self.baud_rate
            self.comm.timeout = self.timeout
            self.dtr = self.enable_dtr
            self.comm.open()

            time.sleep(self.settle_time)
            self._is_connected = True

            print("done.")
814759
def openCurrentItem(self):
        
        logger.debug("openCurrentItem")
        _currentItem, currentIndex = self.getCurrentItem()
        if not currentIndex.isValid():
            return

        # Expanding the node will call indirectly call RepoTreeModel.fetchMore which will call
        # BaseRti.fetchChildren, which will call BaseRti.open and thus open the current RTI.
        # BaseRti.open will emit the self.model.sigItemChanged signal, which is connected to
        # RepoTreeView.onItemChanged.
        self.expand(currentIndex)
602055
def nil_uuid?
      return false if self.time_low != 0
      return false if self.time_mid != 0
      return false if self.time_hi_and_version != 0
      return false if self.clock_seq_hi_and_reserved != 0
      return false if self.clock_seq_low != 0
      self.nodes.each do |node|
        return false if node != 0
      end
      return true
    end
602612
def open(cls, fp):
        
        if hasattr(fp, 'read'):
            self = cls(PSD.read(fp))
        else:
            with open(fp, 'rb') as f:
                self = cls(PSD.read(f))
        return self
687648
def _open_connection(self):
        """"""
        if (self._mode == PROP_MODE_SERIAL):
            self._serial = serial.Serial(self._serial_device, self._serial_speed)
        elif (self._mode == PROP_MODE_TCP):
            self._socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
            self._socket.connect((self._ip, self._port))
        elif (self._mode == PROP_MODE_FILE):
            self._file = open(self._file_path, "r")
915923
def open(self):
        """"""
        device_type = 'cisco_ios'
        if self.transport == 'telnet':
            device_type = 'cisco_ios_telnet'
        self.device = ConnectHandler(device_type=device_type,
                                     host=self.hostname,
                                     username=self.username,
                                     password=self.password,
                                     **self.netmiko_optional_args)
        # ensure in enable mode
        self.device.enable()
633457
async def open(self) -> bool:
        """"""
        _LOGGER.debug('%s: Sending open command', self.name)
        if not await self._set_state(1):
            return False

        # Do not allow update of this device's state for 5 seconds.
        self.next_allowed_update = datetime.utcnow() + timedelta(seconds=5)

        # Ensure state is open or opening
        if self.state not in (STATE_OPEN, STATE_OPENING):
            # Set state to opening
            self._update_state('4')
            self._device_json = self._device['device_info']

        _LOGGER.debug('%s: Open command send', self.name)
        return True