Disable USB Autosuspend

Is there an easy way to disable USB autosuspend within Balena OS?

i.e. this file I would need to set to -1

/sys/module/usbcore/parameters/autosuspend

Hey there, balenaOS does not have a dedicated switch for that but the file should be writable from a container so you can do that during the startup of the application at runtime.

There are two requirements:

  1. The container must be privileged
  2. To mount sysfs, the container must use the io.balena.features.sysfs label as described in docker-compose.yml fields - Balena Documentation

Let us know if you’re able to get this working!