Edit/create udev
rules (use vi, nano, or any text editor). * Note: The filename/order can be different as per personal preferences. 45-stdfu-permissions.rules
is typical of most Cleanflight/Betaflight installations/documents.
Copy/paste this content and save it: (See STM list here: https://devicehunt.com/view/type/usb/vendor/0483)
Then reload the rules:
You must add yourself (username) to plugdev group.
Also, add yourself to the dialout group for tty/serial permissions: (Fixes Failed to open serial port: FILE_ERROR_ACCESS_DENIED
)
Often, ModemManger is installed by default, but we rarely use phone-line dial-up modems any more, so fix some issues by removing it: (usually required)
Optionally, uninstall it:
Required: After the above usermod
commands are applied, you must logout/login to update user access rights. They will not apply until re-login. Afterward, you may run Configurator which should properly connect to flight controllers.
Similar to the above, but plugdev
group is not needed. Instead use uaccess
tag in your udev rule for dfu:
Caveat: I know nothing about USB in Fedora; This was taken from documentation and may be incomplete.
Similar to all of the above, except GROUP
/MODE
can be replaced with TAG
:
If other app are locking the port, or it is otherwise stuck/occupied, try resetting it with stty sane -F /dev/PORT
. e.g.: