8bitdo-firmware icon indicating copy to clipboard operation
8bitdo-firmware copied to clipboard

Where is ebitdo-tool?

Open vanfanel opened this issue 9 months ago • 9 comments

Hi there,

Looking at this repo, I see ebitdo-tool mentioned as a method to flash the 8bitdo firmware. However, fwupdmgr doesn't have such a tool. I can grab the fw using this script, but other than using the propietary 8BitDo tools, is there a way to flash it currently on GNU/Linux?

vanfanel avatar Apr 06 '25 13:04 vanfanel

I think the spiritual successor is sudo fwupdtool install-blob --plugins ebitdo filename.dat

hughsie avatar Apr 06 '25 15:04 hughsie

Hey @hughsie , thanks for trying to clear things up! Indeed, fwupdtool install-blob --plugins ebitdo RetroKeyboard177.bin should work, but it seems that fwupdtool isn't able to find the keyboard:

manuel@debian:~$ fwupdtool install-blob --plugins ebitdo RetroKeyboard177.bin
Writing…                 [************                           ]
No detected devices

Since the WINE + proprietary offline flasher (https://tempfiles.8bitdo.com/HOT/RetroKeyboard177.zip) is working, fwupdtool should find it too, shouldn't it?

vanfanel avatar Apr 06 '25 17:04 vanfanel

but it seems that fwupdtool isn't able to find the keyboard

8bitdo stopped supporting fwupd and LVFS a few years ago, I don't think that device VID PID exists: https://github.com/fwupd/fwupd/blob/main/plugins/ebitdo/ebitdo.quirk

hughsie avatar Apr 06 '25 21:04 hughsie

but it seems that fwupdtool isn't able to find the keyboard

8bitdo stopped supporting fwupd and LVFS a few years ago, I don't think that device VID PID exists: https://github.com/fwupd/fwupd/blob/main/plugins/ebitdo/ebitdo.quirk

Do you mean the device's VID:PID should be added to ebitdo.quirk? As in... a PR to add it?

vanfanel avatar Apr 07 '25 11:04 vanfanel

If it works, I'd happily accept it -- but 8bitdo have tweaked the protocol over the years so it might get a bit more involved.

hughsie avatar Apr 07 '25 12:04 hughsie

I'm not familiar with building fwupd: is ebitdo.quirk part of the compiled sources, or is it installed along with the fwupd package? (I'm in Debian Testing)

So far tried find on /usr and /etc without any luck, so I suspect I'd have to build fwupd in order to add+test the new VID:PID,, right?

vanfanel avatar Apr 07 '25 13:04 vanfanel

You should be able to just ship whatever.quirk in /usr/share/fwupd/quirks.d/ or /var/lib/fwupd/quirks.d/

hughsie avatar Apr 07 '25 13:04 hughsie

Ah, I see. I created /usr/share/fwupd/quirks.d/8bitdo.quirk with this content (got VID:PID from lsusb):

# Retro Keyboard
[USB\VID_2DC8&PID_5200]
Plugin = ebitdo
Flags = ~is-bootloader
InstallDuration = 120

Then retried the flashing with not-so-good results:

manuel@debian:~/.wine/drive_c/8bitdo/RetroKeyboard177$ sudo fwupdtool install-blob --plugins ebitdo RetroKeyboard177.bin
Loading…                 [*******                                ]13:42:39.467 FuEngine             failed to add device /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2: failed to setup: failed to send to device on ep 0x01: USB error: Input/Output Error [-1]
Writing…                 [************                           ]
No detected devices

Is there anything else I could try?

vanfanel avatar Apr 07 '25 13:04 vanfanel

Is there anything else I could try?

I think "asking 8bitdo" needs to be high on your list. If that's fruitless, maybe we can dig into the device enumeration: https://github.com/fwupd/fwupd/blob/main/plugins/ebitdo/fu-ebitdo-device.c#L310

hughsie avatar Apr 07 '25 13:04 hughsie