I just wanted to check if anyone could or did recently flash a custom firmware or Android build to their smartphone. I did today and it hang with the message <waiting for device>.
Command (in fastboot mode): fastboot flash abl_ab abl.elf
Reference: Update firmware on beryllium | LineageOS Wiki
Now I’m not sure if it’s a bug with NixOS or my laptop’s fault.
It worked without any problems on my desktop PC with arch installed.
lsusb lists the device as connected. dmesg -w goes wild when I try to flash a image to the device with the command:
Boot device into fastboot with adb reboot bootloader
usb 1-1: new full-speed USB device number 10 using xhci_hcd
usb 1-1: new high-speed USB device number 11 using xhci_hcd
usb 1-1: New USB device found, idVendor=xxxx, idProduct=xxxx, bcdDevice= 1.00
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: Android
usb 1-1: Manufacturer: Google
usb 1-1: SerialNumber: xxxxxxxx
Run fastboot flash abl_ab abl.img
After pressing enter the terminal freezes with the output
Sending 'abl_ab' (204 KB)
After a few minutes, I cancel the command and execute fastboot devices.
The command doesn’t list the android device and dmesg -w prints the following:
usb 1-1: reset high-speed USB device number 11 using xhci_hcd
usb 1-1: device descriptor read/64, error -110
usb 1-1: device descriptor read/64, error -71
usb 1-1: reset high-speed USB device number 11 using xhci_hcd
usb 1-1: device descriptor read/64, error -71
usb 1-1: device descriptor read/64, error -71
usb 1-1: reset high-speed USB device number 11 using xhci_hcd
usb 1-1: Device not responding to setup address.
usb 1-1: Device not responding to setup address.
usb 1-1: device not accepting address 11, error -71
usb 1-1: reset high-speed USB device number 11 using xhci_hcd
usb 1-1: Device not responding to setup address.
usb 1-1: Device not responding to setup address.
usb 1-1: device not accepting address 11, error -71
usb 1-1: USB disconnect, device number 11
usb 1-1: new high-speed USB device number 12 using xhci_hcd
usb 1-1: device descriptor read/64, error -71
usb 1-1: device descriptor read/64, error -71
usb 1-1: new high-speed USB device number 13 using xhci_hcd
usb 1-1: device descriptor read/64, error -71
usb 1-1: device descriptor read/64, error -71
usb usb1-port1: attempt power cycle
usb 1-1: new high-speed USB device number 14 using xhci_hcd
usb 1-1: Device not responding to setup address.
usb 1-1: Device not responding to setup address.
usb 1-1: device not accepting address 14, error -71
usb 1-1: new high-speed USB device number 15 using xhci_hcd
usb 1-1: Device not responding to setup address.
usb 1-1: Device not responding to setup address.
usb 1-1: device not accepting address 15, error -71
usb usb1-port1: unable to enumerate USB device
and lsusb doesn’t list the previous device anymore.
I did use the same USB-A to USB-C on my laptop and tower PC. The only difference is that my laptop runs NixOS and my tower arch. Therefore I concluded that it could be a bug on the NixOS side or the android-tool package.
Probably a hardware problem (usb port or usb 2.0 cable) on my side. I had to open a second terminal window, execute the sideload command on the first one and booted the device into fastboot on the second window.