Summary (What we've done, what we've tried):
Basically, the aim is to establish an adb protocol via usb between two linux computers by using adb source codes.
Envinronment is Ubuntu 16.0.4. There's android-tools-adbd (adb daemon) package ready for use in the pool with its source available.
There is also a source on this link (adbd) compilable with gcc option -stc=c++14 which is supported in 16.0.4 by default (or gcc 5.2).
We are able to build the package from source or use already-built one successfully by using adb connect (TCP/IP dependent). There's no problem on adb connection via TCP/IP if two computers are connected to the same network.
Unfortunately, we are not able to set a USB connection between two computers with an A to A (both male) cable. ADB gadget isn't working and none of the devices recognize the other. We can't decide whether there's a need for an explicit driver besides ADB gadget.
Question is (REAL question to be answered):
How to set a USB protocol between two linux computers so that adb communication can be done via USB?
Is there any solution for it?
[---EDIT---]
NOTES:
Going further day by day, small issues left. For those who want to be involved; we are following this guide.
(Kernel version 4.4.0-38-generic)
Having problems with running the correct udc (USB Device Controller) driver. After activating ConfigFS by
modprobe usb_f_fs
,xdg-adbd
(executable from the source link, adbd) works fine until theif(...)
that detects udc driver. We tried runningmodprobe musb_hdrc
but didn't see an explicit driver name under/sys/class/udc
.
(27.09.2016)