# ADB devices not found

Source: https://forum.modalai.com/topic/748/adb-devices-not-found
Category: Flight Core and Legacy VOXL (https://forum.modalai.com/category/9/flight-core-and-legacy-voxl)
Tags: voxl-cam
Posted: 2022-02-16 08:32:22 UTC by marian
Replies: 30 · Views: 16046

## marian · 2022-02-16 08:32:22 UTC

Hi, for the same voxl cam I ordered, i tried to use adb to connect to it and doesn't work. I tried via un Ubuntu client and via my mac too.

The answer is always like this:
 % ./adb devices
List of devices attached

Via Windows (where i use an ubuntu client) I see the devices connected on the usb port, but on linux the command adb doesn't see it. 
Via Mac I don't see at all the devices connected. 

I use the power module delivered with the voxl package and a 4s battery to power it.  

Please advice how to proceed.

## Reply by marian · 2022-02-17 18:38:20 UTC

I see the device when I run lsusb on the ubuntu client, but not when I run the adb devices command as below:

marian@RM:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 002: ID 05c6:901d Qualcomm, Inc. APQ8096-MTP _SN:4549C070
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
marian@RM:~$ adb devices
List of devices attached

marian@RM:~$

## Reply by tom (ModalAI staff) · 2022-02-17 22:34:21 UTC

@marian Does it show up with `fastboot devices` perhaps?

## Reply by marian · 2022-02-18 10:46:10 UTC

@tom Thank you for your reply. 
No, it doesn't.

I verified the link and it's fine as per below:

On Windows 
PS C:\WINDOWS\system32> usbipd wsl list
BUSID  DEVICE                                                        STATE
3-1    APQ8096-MTP _SN:4549C070, ADB Interface                       Attached - Ubuntu-20.04

On Ubuntu client:
marian@RM:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 05c6:901d Qualcomm, Inc. APQ8096-MTP _SN:4549C070
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

marian@RM:~$ dmesg | tail
[ 2188.224798] usb 1-1: SetAddress Request (4) to port 0
[ 2188.318613] usb 1-1: New USB device found, idVendor=05c6, idProduct=901d, bcdDevice= 3.18
[ 2188.318617] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 2188.318621] usb 1-1: Product: APQ8096-MTP _SN:4549C070
[ 2188.318625] usb 1-1: Manufacturer: Android
[ 2188.318629] usb 1-1: SerialNumber: c6f37030

cat /etc/udev/rules.d/51-android.rules
SUBSYSTEM=="usb", ATTRS{idVendor}=="05c6", ATTRS{idProduct}=="901d", MODE="0660", GROUP="plugdev", SYMLINK+="voxl%n"
SUBSYSTEM=="usb", ATTRS{idVendor}=="18d1", ATTRS{idProduct}=="d00d", MODE="0660", GROUP="plugdev", SYMLINK+="voxl-fastboot%n"

marian@RM:~$ adb --version
Android Debug Bridge version 1.0.39
Version 1:8.1.0+r23-5ubuntu2
Installed as /usr/lib/android-sdk/platform-tools/adb

marian@RM:~$ fastboot --version
fastboot version 1:8.1.0+r23-5ubuntu2
Installed as /usr/lib/android-sdk/platform-tools/fastboot

And the results of the commands:
marian@RM:~$ adb devices
List of devices attached

marian@RM:~$ fastboot devices
marian@RM:~$

## Reply by tom (ModalAI staff) · 2022-02-22 17:55:39 UTC

@marian Were you able to connect to the VOXL-Cam via ADB in the past? Or have you been having these issues out of the box?

## Reply by marian · 2022-02-22 19:15:42 UTC

@tom I have being issue out of the box, it never connect via adb

## Reply by tom (ModalAI staff) · 2022-02-22 19:17:15 UTC

@marian And using this same PC, are you able to ADB onto a different VOXL-Cam?

## Reply by marian · 2022-02-22 19:31:51 UTC

@tom I have only one voxl-cam

## Reply by tom (ModalAI staff) · 2022-02-22 23:48:34 UTC

@marian So is SSH working then? I see that you've done some work with this VOXL Cam already based on your post history?
Or were you connecting directly to the Flight Core via JST to USB?

## Reply by marian · 2022-02-23 09:22:35 UTC

@tom Yes, the ssh and connecting the flight core via jst to usb is working. 

When I bought the voxl-cam I understood that came calibrated and ready to use. But, as I used it on a custom frame the sensors like accelerometer, compass and gyroscope are not calibrated. 

I used it on the frame on the same way like seekers (of course, I needed it to adapt the /etc/modalai/extrinsics.conf file for my configuration), but 
- whenever I use a GPS with compass (as M8N u-blox) I can't calibrate the compass, it will see a different position instead of the position the drone really is, it is finishing the calibration anyway, but after reboot it will ask me again to re-calibrate the compass
- whenever I used it for indoor navigation, so GPS and compass disabled, I calibrate the accelerometer with ROTATION-NONE as per modalai documentation,then once I have the local position on, the QGC tell me that I have a roll failure detected and, of course, can't proceed with arming. 

So, basically I can't use at all the voxl-cam :(

## Reply by tom (ModalAI staff) · 2022-02-23 17:44:08 UTC

@marian Okay that is good that at least ssh is working so the board should be functional. I wonder if it is some sort of user privileges issue that ADB isn't coming up. What if you do `sudo adb devices`? And what if you remove that android rules file: `sudo rm /etc/udev/rules.d/51-android.rules` and reboot your PC? I'm not sure that file is necessary.

For those other questions, I would open a new forum topic so that the whole team can get eyes on it.

## Reply by marian · 2022-02-23 18:41:46 UTC

@tom The results are the same even if I use sudo or I remove the 51-android.rules

## Reply by tom (ModalAI staff) · 2022-02-23 18:55:03 UTC (in reply to marian)

@marian Did you reboot after removing the android-rules file?

## Reply by tom (ModalAI staff) · 2022-02-23 18:55:59 UTC

@marian We may have to take a look at your hardware in house, checkout our RMA info here: https://modalai.com/rma

## Reply by marian · 2022-02-23 19:03:08 UTC (in reply to tom)

@tom yes, I rebooted the pc

## Reply by marian · 2022-02-25 09:56:13 UTC (in reply to tom)

@tom In terms of RMA, can we try to have a remote diagnostic? I'm far a way from US ...

## Reply by tom (ModalAI staff) · 2022-02-25 17:59:50 UTC

@marian Have you been able to ADB in to any other VOXL devices on this PC in the past? From what I see in your `lsusb` output everything looks correct. I'm wondering if there's an issue with your ADB install

## Reply by tom (ModalAI staff) · 2022-02-25 18:16:03 UTC

@marian Here is what a working VOXL looks like on my machine running Ubuntu 18: `Bus 001 Device 068: ID 05c6:901d Qualcomm, Inc.` We have others at the company who use 20 so that shouldn't be an issue

## Reply by tom (ModalAI staff) · 2022-02-25 18:16:34 UTC

@marian
 ```[  +0.467545] usb 1-1: new high-speed USB device number 68 using xhci_hcd
[  +0.150491] usb 1-1: New USB device found, idVendor=05c6, idProduct=901d, bcdDevice= 3.18
[  +0.000010] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  +0.000005] usb 1-1: Product: APQ8096-MTP _SN:AF0F8B82
[  +0.000004] usb 1-1: Manufacturer: Android
[  +0.000003] usb 1-1: SerialNumber: 4399683d```

## Reply by marian · 2022-02-28 13:23:43 UTC

@tom I see the same things, but stiill the adb or fastboot commands don't see my device. I tried with two different laptops, and the problem is the same as per images below:

![IMG_2349-1.jpeg](https://forum.modalai.com/assets/uploads/files/1646054529627-img_2349-1-resized.jpeg)
![IMG_2348.jpg](https://forum.modalai.com/assets/uploads/files/1646054607327-img_2348-resized.jpg)

## Reply by marian · 2022-02-28 16:01:23 UTC

@tom I tried the adb for windows and it is working fine, I'm able to connect onto the voxl-cam via adb shell command.

Still have a problem via wsl to see the devices from ubuntu client, but if is working from windows client for adb I suppose that the device is fine.

## Reply by tom (ModalAI staff) · 2022-02-28 17:59:09 UTC

@marian Okay that's some good news! Since you're able to ADB from windows that means the VOXL Cam itself is functional. It must be some permission issue. We recommend using Ubuntu 18 directly and none of our engineers here use Windows for software development so I'm not too familiar with WSL. Do USB devices need to be added manually? Not sure they're shared from windows to WSL automatically. You may also need to stop the ADB server from running on the Windows client in order for it to work in WSL. (`adb kill-server`)

## Reply by marian · 2022-03-01 10:05:23 UTC

@tom It's working just fine :) 

There were a few issues:

1) when using WSL we need to start the server on windows via powershell and the first time will ask to set up the security access, just give access on both networks, this is used by wsl to give access to ubuntu client.  

2) On linux, if we install the adb via apt install, the adb version will be older and the connection with the server will not work. Should install it via platform-tools provided by Android studio.

3) The cable. Using a micro-usb cable to connect the voxl-cam doesn't work every time, is recommended to use a usb 3 data cable to connect via this usb port.  

Once we follow all these, is working fine in all the environments : windows, wsl / ubuntu 20, and mac os :) 

Thanks for your help!

## Reply by tom (ModalAI staff) · 2022-03-01 19:34:51 UTC

@marian This is some really good information, thank you so much for your findings!

## Reply by Bright Nnadi · 2022-07-26 20:47:52 UTC (in reply to marian)

@marian Please I am having the same issue you had with  ADB here. I installed ADB with Ubuntu but it I don't think it worked because its not Detecting my VOXL CAM yet.

## Reply by marian · 2022-07-27 06:35:48 UTC (in reply to Bright Nnadi)

@Bright-Nnadi Hi, did you install ubuntu on windows and using via wsl, or you have a linux machine with ubuntu installed that you use?

## Reply by Bright Nnadi · 2022-07-27 13:36:33 UTC (in reply to marian)

@marian i just installed ubuntu  on windows  but not via wsl

## Reply by marian · 2022-07-27 14:10:03 UTC (in reply to Bright Nnadi)

@Bright-Nnadi I understand. I followed the steps below and it works fine for me, I hope that will help you too.

1) Installation steps :
 Install ADB for windows
 Install adb for ubuntu.

Check the version on both systems. On ubuntu, if using apt will install an older version than Windows, so should install it via platform-tools provided by Android studio

For Using ADB follow the steps below:
a) Run PowerShell in Admin mode, and go to the folder where ADB is located
There tape the command below:
.\adb.exe -a -P 5037 nodaemon server

That should connect and show the devices:
adb.exe I 02-28 17:55:47 13580 13948 adb.cpp:171] c6f37030: already offline

N.B.: The first time we run it, it will open a security window to give it access through the Firewall. Select the both, local and public network. It is needed to access the device through WSL (see step below). 

Into another PowerShell window can connect to the device via .\adb.exe shell 

b) on Ubuntu client : 

Take the IP address of the WSL from the windows station: 
ifconfig -> for me is something like 172.23.0.1 …

Look into the /etc/resolv.conf => there should be the address below, if not change it to this one

Run the command:
 adb -H 172.23.0.1 -P 5037 devices

That should allow you to connect to adb device from Ubuntu client on Windows.

## Reply by Bright Nnadi · 2022-07-27 14:58:06 UTC (in reply to marian)

@marian Please how will install adb via AS, not familiar with it.

## Reply by Bright Nnadi · 2022-07-27 15:11:23 UTC

So I have Android studio installed now

## Reply by Hyunsoo Kim 0 · 2024-04-23 22:30:22 UTC (in reply to tom)

@tom Thank you so much!
I was having the exact same problem with @marian.
I could connect to the voxl via ssh but could not via adb shell.
But could solve it after removing the /etc/udev/rules.d/51-android.rules. 
Try to remove the file, who are facing the same problem with me.
