Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error When Trying to Mount Switch SD Card on EndeavourOS Linux #22

Open
nfox18212 opened this issue Jun 17, 2023 · 0 comments
Open

Error When Trying to Mount Switch SD Card on EndeavourOS Linux #22

nfox18212 opened this issue Jun 17, 2023 · 0 comments

Comments

@nfox18212
Copy link

Hello,
I ran the python script app.py with sudo and managed to load cfw onto my switch. However, when trying to mount the switch's sd card onto my laptop I ran into the following errors:

$ sudo python3 app.py

Important note: on desktop Linux systems, we currently require an XHCI host controller.
A good way to ensure you're likely using an XHCI backend is to plug your
device into a blue 'USB 3' port.

Identified a Linux system; setting up the appropriate backend.

Setting ourselves up to smash the stack...
Uploading payload...
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.11/tkinter/__init__.py", line 1948, in __call__
    return self.func(*args)
           ^^^^^^^^^^^^^^^^
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/app.py", line 98, in btn_mountusb_pressed
    fusee.do_hax(args)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 688, in do_hax
    switch.write(payload)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 525, in write
    self.write_single_buffer(chunk)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 535, in write_single_buffer
    return self.backend.write_single_buffer(data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 127, in write_single_buffer
    return self.dev.write(0x01, data, 1000)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 989, in write
    return fn(
           ^^^
  File "/usr/lib/python3.11/site-packages/usb/backend/libusb1.py", line 837, in bulk_write
    return self.__write(self.lib.libusb_bulk_transfer,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/backend/libusb1.py", line 938, in __write
    _check(retval)
  File "/usr/lib/python3.11/site-packages/usb/backend/libusb1.py", line 604, in _check
    raise USBError(_strerror(ret), ret, _libusb_errno[ret])
usb.core.USBError: [Errno 5] Input/Output Error

I'm honestly not sure how to interpret these error messages and googling "usb.core.USBError: [Errno 5] Input/Output Error" didn't turn up any meaningful results to me. When I tried to select the "mount sd card" button again, after the first time it gave a different error message:

Setting ourselves up to smash the stack...
Uploading payload...
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.11/tkinter/__init__.py", line 1948, in __call__
    return self.func(*args)
           ^^^^^^^^^^^^^^^^
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/app.py", line 98, in btn_mountusb_pressed
    fusee.do_hax(args)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 688, in do_hax
    switch.write(payload)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 525, in write
    self.write_single_buffer(chunk)
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 535, in write_single_buffer
    return self.backend.write_single_buffer(data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/nfox/Downloads/SwitchHomebrew/fusee-interfacee-tk/fusee_launcher.py", line 127, in write_single_buffer
    return self.dev.write(0x01, data, 1000)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 986, in write
    intf, ep = self._ctx.setup_request(self, endpoint)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 113, in wrapper
    return f(self, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 229, in setup_request
    self.managed_claim_interface(device, intf)
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 113, in wrapper
    return f(self, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/usb/core.py", line 178, in managed_claim_interface
    self.backend.claim_interface(self.handle, i)
  File "/usr/lib/python3.11/site-packages/usb/backend/libusb1.py", line 829, in claim_interface
    _check(self.lib.libusb_claim_interface(dev_handle.handle, intf))
  File "/usr/lib/python3.11/site-packages/usb/backend/libusb1.py", line 604, in _check
    raise USBError(_strerror(ret), ret, _libusb_errno[ret])
usb.core.USBError: [Errno 16] Resource busy

Every other time I tried to mount the sd card, it gave this same error message. Any assistance would be appreciated, and if I need to provide more information please tell me. This occurred regardless of if the sd card was mounted on the switch or not.

Relevant information:

$ uname -a
Linux YoRHa 6.1.32-1-lts #1 SMP PREEMPT_DYNAMIC Mon, 05 Jun 2023 18:23:39 +0000 x86_64 GNU/Linux
$ python --version
Python 3.11.3

Steps to reproduce for me:
Clone the repository
Run app.py with python3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant