How do I disable brltty?

I have a microcontroller system to be connected via USB, which sets up a /dev/ttyUSB0. I recently noticed that the Braille driver (brltty) tries to grab the device and fails, since it is not a braille device. This did not happen earlier (can’t tell when).

  502.380633] usbcore: registered new interface driver usbserial_generic
  502.380641] usbserial: USB Serial support registered for generic
  502.382066] usbcore: registered new interface driver cp210x
  502.382072] usbserial: USB Serial support registered for cp210x
  502.382084] cp210x 1-11:1.0: cp210x converter detected
  502.383648] usb 1-11: cp210x converter now attached to ttyUSB0
  502.422511] usb 1-11: usbfs: interface 0 claimed by cp210x while 'brltty' sets config #1
  502.422924] cp210x ttyUSB0: cp210x converter now disconnected from ttyUSB0
  502.422935] cp210x 1-11:1.0: device disconnected

When I uninstall the brltty packages, it works, but they are reinstalled on every zypper dup. It seems more reasonable to disable the service, but I could not get systemctl to do that.

# systemctl stop brltty@-dev-bus-usb-001-004.service
Failed to stop brltty@-dev-bus-usb-001-004.service: Operation refused, unit brltty@-dev-bus-usb-001-004.service may be requested by dependency only (it is configured to refuse manual start/stop).
See system logs and 'systemctl status brltty@-dev-bus-usb-001-004.service' for details.

Suggestions welcome.

Lock those packages?

man zyppr

under “Package Locks Management”.

Please check the output of “rpm --query --whatrequires brltty”.

  • On this Leap 15.0 system, there are no packages which “require” require the package “brltty” – which is why it ain’t installed here …
  • It may be that, a YaST “pattern” which is forcing the installation of “brltty” – but, on searching Leap 15.0 I can’t find a pattern which could be causing this issue …

It’s about Tumbleweed, not Leap.

# rpm --query --whatrequires brltty

I know that I can prevent reinstallations by blocking, but I’d prefer not to keep records of stuff that I blocked over time. My understanding is that I should be able to turn off services that I don’t need.

Typically, I’d disable services with systemctl, but in this case I can’t find which is the component that originally requests it. The brltty is “static” in systemctl is-enabled.

Googling reveals that brltty has been interfering with ttyUSB for more than 10 years…

You ‘mask’ the static service… (not running here)

systemctl status brltty.path 

● brltty.path - Default BRLTTY Instance
   Loaded: loaded (/usr/lib/systemd/system/brltty.path; disabled; vendor preset: disabled)
   Active: inactive (dead)

systemctl mask brltty.path 

Created symlink /etc/systemd/system/brltty.path → /dev/null.


Looking at the “Requires” list, the culprit may well be ‘xbrlapi’ – please check “whatrequires” the X system Braille API …

I found a way to disable it:

ln -s /dev/null /etc/udev/rules.d/69-brltty.rules

There is a file with the same name in /usr/lib/udev/rules.d/. This seems to launch the brltty. I wonder why this issue appeared again (seemed to be going back for 10 years); maybe the rules have a bug. I noticed a comment in /etc/brltty.conf that says that a braille display behind a serial-to-USB adapter will not work via the “usb:” path but the actual virtual interface (ttyUSB0) must be specified. Maybe some brltty dev felt really smart and lets it grab the first ttyUSBx that shows up.

It may be better to simply invoke “rpm --query --whatprovides /etc/udev/rules.d/69-brltty.rules /usr/lib/udev/rules.d/69-brltty.rules” …

  • If they ain’t being provided by any package, simply remove those two files …