Code example for UsbDevice

Methods: getInterface

0
		super.disconnect(); 
		if (mListener != null) {
			mListener.cancel(true);
		} 
		if (deviceFTDI != null && conn != null) {
			conn.releaseInterface(deviceFTDI.getInterface(0));
			conn.close();
		} 
	} 
 
	@Override 
	public void write(String s) {
		byte b[] = s.getBytes();
		int from_idx, to_idx, res;
		byte tmp[] = new byte[64];
 
		from_idx = 0;
		while (from_idx < b.length) {
			to_idx = 0;
			while (to_idx < 64 && from_idx < b.length) {
				tmp[to_idx++] = b[from_idx++];