Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Feb 2019 14:39:37 +0100
From:      "Julian H. Stacey" <jhs@berklix.com>
To:        Matthias Apitz <guru@unixarea.de>
Cc:        hackers@freebsd.org
Subject:   Re: bsd android tethering using USB cable - intermittent failure
Message-ID:  <201902111339.x1BDdbBB039254@fire.js.berklix.net>
In-Reply-To: Your message "Wed, 06 Feb 2019 09:05:11 %2B0100." <20190206080511.GA22504@sh4-5.1blu.de>

next in thread | previous in thread | raw e-mail | index | archive | help

Matthias Apitz wrote: Wed, 6 Feb 2019 09:05:11 +0100
> El día Tuesday, February 05, 2019 a las 05:34:42PM +0100, Julian H. Stacey escribió:
> 
> > Thanks , Yes I've got developer mode on (7 taps on build version)
> > &  dont know how to lock display so always on, & yes I do always
> > touch screen to tether.
> > 
> > Ive tried rebooting BSD today didnt help. Dont think ive tried
> > rebooting the Androids today.  I wondered if I had some hidden
> > faulty initialiser file so just removed a bunch of ~/.[a-zA-Z]*
> > that I didnt recognise or didnt want.
> > 
> > Weirdly, adb shell has now just connected on the phone I want to
> > move data on.
> > 
> > & also weirdly ifconfig -a
> > does Not display a ue0: eg from past:
> > 	ue0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
> >  		ether xx:xx:xx:xx:xx:xx
> > though I thought I needed ue to tether with,
> > ifconfig -a just shows ether & local bge0: & lo0:
> > 
> > Unfortunately my background devd set up the connection before I
> > killed it & switched to foreground /sbin/devd -d so xterm scroll
> > back does not show what device, but I grabbed a tar copy of /dev
> > to look at later
> > 
> > My Android popped up with a less often seen screen: USB PC Connection
> > 	Connect as
> > 		Media device (MTP) which shows pre-ticked Green
> > 		Camera (PTP) which shows blank, un-checked.
> > 
> > Well I wont disturb that pair of devs that are ready to talk,
> > I'll start long transfer of data I need, 
> > 
> > but I will contine to experiment on another pair of devs,

Hi Matthias & all,

> I think you must not have this interface 'ue0',

Yes, you'r right, thanks, Tethering the smart phone kills
the adb direct over usb connection, not surprising in retrospect ;-)


> i.e. you must not enable
> 'rndis' in the gadget. Or use TCP and SSH or ADB, not both. See this
> life example:
> 
> I have not set in the BQ:

I presume BQ is your name for your phone type.


> android-gadget-service enable rndis 

I don't know what file on bsd or android you refer to.  (Fortunately
android 6 has find & grep (earlier does not)), but I find nothing
with these:
On android:
	cd /etc;find . -type f -exec grep android-gadget-service {} /dev/null \;
On current freebsd :
	man urndis
	cd /usr/src ; find . -type f -exec grep android-gadget-service {} \;


> # ifconfig ue0
> ifconfig: interface ue0 does not exist
> 
> attach  E4.5

Too cryptic, not sure what you mean.
attach is not a command on android 6 or freebsd current
	uname -a
	Linux localhost 3.4.0-12884729 #1 SMP PREEMPT Mon Jan 15 16:53:44 KST 2018 armv7l
	shell@klte:/ $ 
Though attach is a label for bsd /etc/devd/*.conf
& I recall attach a dev to an interface of old, eg slattach etc.
& on freebsd current : apropos attach : man devmatch
& devinfo | grep rndis # only shows urndis0 when I click tether on android


> # tail /var/log/messages
> ...
> Feb  6 08:50:16 c720-r342378 kernel: ugen0.4: <BQ AquarisE4.5> at usbus0
> 
> # adb start-server
> * daemon not running; starting now at tcp:5037
> * daemon started successfully
> 
> # adb devices -l
> List of devices attached
> JU000435               device usb:0:4 product:krillin model:Aquaris_E4_5_Ubuntu_Edition device:krillin transport_id:1

Yes, ths was my problem after tethering I was not seeing any devices,
now I dont teher & can connect again & move files.
> 
> # adb shell
> phablet@ubuntu-phablet:~$
> phablet@ubuntu-phablet:~$ uname -a
> Linux ubuntu-phablet 3.4.67 #1 SMP PREEMPT Mon Jun 6 12:04:40 UTC 2016 b75400e armv7l armv7l armv7l GNU/Linux

PS Later I'll tether again.  My end aim is find an app for android
that supports NFS & AMD, so the phone can seamlessly become part
of my file system on BSD. but a search on http://play.google.com
& http://www.fdroid.org shows nothing obvious.

I'll probably have to root the phone too before that, & I didnt
root, till after I could backup, & backup wasnt easy with no knowledge
of FS tree, & no commands find & grep on my older android, & locked
read permissions in non root, it was chicken & egg.  

Tips welcome, I add them to my http://www.berklix.com/android/
Thanks

Julian
-- 
Julian Stacey, Consultant Systems Engineer, BSD Linux Unix, Munich Aachen Kent
 UK Stole 700,000 votes from British in EU + 3 million globally; 1.9 M in UK
 were too young + 1.3 M died. Fraud, fines & lies. Brexit is minority. 2nd Ref.
 Blind Chaos & slump?  Or revoke #50, plan better first, maybe re-file later.
 http://www.berklix.uk/brexit/#email_an_mp



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201902111339.x1BDdbBB039254>