public void close() throws BITalinoException {
        try {
            dis.close();
            os.close();
        } catch (Exception e) {
            throw new BITalinoException(BITalinoErrorTypes.BT_DEVICE_NOT_CONNECTED);
        } finally {
            dis = null;
            os = null;
        }
    }