解决使用 CH34x 设备时与 brltty 冲突的问题

本文描述了作者在使用CH341设备时遇到与brltty相关的问题,日志显示brltty占用USB接口导致设备无法正常工作。文章详细介绍了通过停止brltty服务、禁止自动启动、卸载软件包等步骤来解决问题的过程,并提醒可能的影响。

最近在使用 CH341 设备时,我遇到了一个与`brltty`相关的问题。在查看系统日志后,发现CH341设备成功连接到`ttyUSB0`,但同时出现了与`brltty`的错误。

    [ 1907.594102] usb 3-1: USB disconnect, device number 3
    [ 1925.360472] usb 3-1: new full-speed USB device number 4 using xhci_hcd
    [ 1925.509626] usb 3-1: New USB device found, idVendor=1a86, idProduct=7523, bcdDevice= 2.64
    [ 1925.509637] usb 3-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
    [ 1925.509640] usb 3-1: Product: USB Serial
    [ 1925.510624] ch341 3-1:1.0: ch341-uart converter detected
    [ 1925.511069] usb 3-1: ch341-uart converter now attached to ttyUSB0
    [ 1925.682562] usb 3-1: usbfs: interface 0 claimed by ch341 while 'brltty' sets config #1
    [ 1925.683268] ch341-uart ttyUSB0: ch341-uart converter now disconnected from ttyUSB0
    [ 1925.683304] ch341 3-1:1.0: device disconnected

根据日志信息,`brltty` 继续占用着设备接口并设置了配置,导致 CH341 设备无法正常工作。为了解决这个问题,我尝试了以下步骤:

首先,停止 `brltty` 服务:
```
sudo systemctl stop brltty
```

然后,禁止 `brltty` 自动启动:
```
sudo systemctl disable brltty
```

接着,重新连接 CH341 设备,并观察是否还会出现相同的错误。然而,问题仍然存在。

因此,我决定彻底删除 `brltty`。下面是我执行的步骤:

1. 停止 `brltty` 服务:
```
sudo systemctl stop brltty
```

2. 禁止 `brltty` 自动启动:
```
sudo systemctl disable brltty
```

3. 卸载 `brltty` 软件包:
```
sudo apt remove brltty
```

4. 清理相关的配置文件和依赖项:
```
sudo apt autoremove
```

完成上述步骤后,`brltty` 已经被完全移除。请注意,这可能会对使用盲文终端的用户产生影响,请在删除之前确认其可能的后果。如果不确定,请备份重要数据或寻求进一步的指导。

希望这篇文章能帮助到遇到类似问题的人们解决他们的困扰。如果你有任何问题或建议,请随时留言!
 

Ubuntu绑定设备失败(3dmem) zrt@zrt:~$ sudo dmesg | grep ch34x [23948.109110] usbcore: registered new interface driver ch34x [23948.109121] usbserial: USB Serial support registered for ch34x [23948.109134] ch34x 1-8.4:1.0: ch34x converter detected [23948.109168] Modules linked in: ch34x(OE+) usbserial snd_usb_audio snd_usbmidi_lib snd_ump mc pcspkr ccm rfcomm nvidia_uvm(PO) mvfgvirtualserial(OE) cmlframegrabber(OE) cmac xofframegrabber(OE) algif_hash algif_skcipher af_alg cxpframegrabber(OE) bnep gevframegrabber(OE) gevfilter(OE) intel_rapl_msr intel_rapl_common intel_uncore_frequency intel_uncore_frequency_common intel_tcc_cooling x86_pkg_temp_thermal intel_powerclamp coretemp nvidia_drm(PO) nvidia_modeset(PO) nvidia(PO) snd_sof_pci_intel_tgl snd_sof_intel_hda_common soundwire_intel snd_sof_intel_hda_mlink soundwire_cadence snd_sof_intel_hda snd_sof_pci snd_sof_xtensa_dsp snd_sof binfmt_misc kvm_intel snd_sof_utils snd_soc_hdac_hda rtw89_8851be snd_hda_ext_core snd_soc_acpi_intel_match rtw89_8851b snd_soc_acpi snd_hda_codec_realtek soundwire_generic_allocation nls_iso8859_1 snd_hda_codec_generic soundwire_bus rtw89_pci snd_hda_codec_hdmi kvm snd_soc_core snd_compress irqbypass ac97_bus rtw89_core snd_pcm_dmaengine crct10dif_pclmul btusb polyval_clmulni [23948.109280] ch34x_attach+0x1a6/0x3d0 [ch34x] [23948.109304] ? __pfx_ch34x_init+0x10/0x10 [ch34x] [23948.109305] ch34x_init+0x23/0xff0 [ch34x] [23948.109762] usb 1-8.4: ch34x converter now attached to ttyUSB0 [23951.195800] usb 1-8.4: usbfs: interface 0 claimed by ch34x while 'brltty' sets config #1 [23951.196419] ch34x ttyUSB0: ch34x converter now disconnected from ttyUSB0 [23951.196427] ch34x 1-8.4:1.0: device disconnected [24071.682644] ch34x 1-8.4:1.0: ch34x converter detected [24071.683064] usb 1-8.4: ch34x converter now attached to ttyUSB0 [24072.212788] usb 1-8.4: usbfs: interface 0 claimed by ch34x while 'brltty' sets config #1 [24072.213372] ch34x ttyUSB0: ch34x converter now disconnected from ttyUSB0 [24072.213389] ch34x 1-8.4:1.0: device disconnected [24137.264924] ch34x 1-8.4:1.0: ch34x converter detected [24137.265809] usb 1-8.4: ch34x converter now attached to ttyUSB0 [24137.798412] usb 1-8.4: usbfs: interface 0 claimed by ch34x while 'brltty' sets config #1 [24137.798977] ch34x ttyUSB0: ch34x converter now disconnected from ttyUSB0 [24137.798985] ch34x 1-8.4:1.0: device disconnected [24143.229930] ch34x 1-8.4:1.0: ch34x converter detected [24143.230327] usb 1-8.4: ch34x converter now attached to ttyUSB0 [24143.756662] usb 1-8.4: usbfs: interface 0 claimed by ch34x while 'brltty' sets config #1 [24143.757207] ch34x ttyUSB0: ch34x converter now disconnected from ttyUSB0 [24143.757215] ch34x 1-8.4:1.0: device disconnected
07-18
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值