Machine not recognized on Ubuntu 22.04

I cannot get my XUbuntu 22.04 PC to recognize my Atomstack A20 machine while it works fine on my XUbuntu 20.04 laptop.

My user is part of dialout and tty groups.

As per https://forum.lightburnsoftware.com/t/no-connection-to-lightburn-after-upgrading-to-ubuntu-22-04/67655, i commented out the Braille device entry in /usr/lib/udev/rules.d/85-brltty.rules and added the line in /usr/lib/udev/rules.d/70-uaccess.rules.

lsusb | grep -i 1A86:7523 displays:

Bus 001 Device 002: ID 1a86:7523 QinHeng Electronics CH340 serial converter

and lsusb -t shows:

...
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/16p, 480M
    |__ Port 6: Dev 2, If 0, Class=Vendor Specific Class, Driver=ch341, 12M
...

The tty device entry looks OK. ls -l /dev/ttyUSB*:

crw-rw---- 1 root dialout 188, 0 juil. 21 12:50 /dev/ttyUSB0

When clicking the Devices/Find my laser button in LightBurn, i get the following console output:

Found port: PID 29987 VID 6790
Manufacturer: "1a86"
Product: "USB Serial" on "ttyUSB0"
attempting connection... DTR setting: false
attempting connection... DTR setting: false
Found port: PID 0 VID 0
Manufacturer: ""
Product: "" on "ttyS0"
attempting connection... DTR setting: false
Port open succeeded
opener
$i response
Vend: 7531 Prod: 3
Vend: 7531 Prod: 2
Vend: 7531 Prod: 3
Vend: 7531 Prod: 2
Vend: 7531 Prod: 3
Vend: 7531 Prod: 2
Vend: 1507 Prod: 1878
Vend: 1921 Prod: 21889
Vend: 7531 Prod: 3
Vend: 2821 Prod: 6387
Vend: 1507 Prod: 1552
Vend: 6790 Prod: 29987
Vend: 2821 Prod: 6258
Vend: 32903 Prod: 41
Vend: 1133 Prod: 50475
Vend: 7531 Prod: 2

However, no machine appears in the Device Discovery Wizard panel.

Trying to run a laser job, i get the dialog message There was a problem sending data to the laser. The machine may be busy or paused.

In the meantime, I have success using a laptop on XUbuntu 20.04.This validates the laser machine and cable hardware. I also copied the LightBurn configuration in ~/.config/LightBurn from the laptop to the PC.

On the laptop, lsusb | grep -i 1A86:7523 displays:

Bus 001 Device 031: ID 1a86:7523 QinHeng Electronics HL-340 USB-Serial adapter

and lsusb -t shows:

...
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/12p, 480M
    |__ Port 1: Dev 31, If 0, Class=Vendor Specific Class, Driver=usbserial_generic, 12M
...

As you can see on the laptop (working) the driver shows usbserial_generic while on the PC (not working), this is ch341. I do not know if the difference is related to the problem or if it is just a change from Ubuntu 20.04 and 22.04.

For those who had success running LightBurn on Ubuntu 22.04, what do lsusb and lsusb -t show ? Any idea what the problem could be ?

After you did this, what happened when you started LightBurn? It’s possible that “Find my laser” doesn’t work while actually connectivity does. In these cases manual configuration can address the issue.

After starting LightBurn make sure the correct serial port is being selected in Laser window. Please attach a screenshot of LightBurn with the Laser window showing.

Separately, have you tried connecting to the serial port with a terminal program? That would show if drivers and permissions are working.

Note that i copied the LightBurn configuration from the laptop to the PC after other tests failed.

I don’t have much choice regarding the ttyUSB port: if the laser if not physically connected, there is not /dev/ttyUSB* driver entry. Once connected, there is only one, generally /dev/ttyUSB0, sometimes /dev/ttyUSB1 or /dev/ttyUSB2.

laser-window

mig@snak:~$ tio /dev/ttyUSB1 
[tio 16:54:08] tio v1.32
[tio 16:54:08] Press ctrl-t q to quit
[tio 16:54:08] Connected
ok
<Idle|MPos:0.000,0.000,0.000|FS:0,0|Pn:P|WCO:0.000,0.000,0.000>
ok

Note the first ok appears after i type Enter. The 2 other lines after typing ?. I do not know the syntax being used between the computer and the laser but it looks like there is no permission problem on the serial port.

Also tried to run LightBurn as root and got the same issue.

What does it show in LightBurn Console when you connect? I feel like things should work.

Can you capture the Console output?

Also, can you take a screenshot of Edit->Device Settings?

The LightBurn console:

lightburn-console

No idea what to type in the input field to see a response.

The device settings:

Also, the result of sudo dmesg when connecting the USB cable:

mig@snak:~$ sudo dmesg
[21013.900990] usb 1-6: new full-speed USB device number 9 using xhci_hcd
[21014.049822] usb 1-6: New USB device found, idVendor=1a86, idProduct=7523, bcdDevice=81.33
[21014.049831] usb 1-6: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[21014.049835] usb 1-6: Product: USB Serial
[21014.051590] ch341 1-6:1.0: ch341-uart converter detected
[21014.052066] usb 1-6: ch341-uart converter now attached to ttyUSB0

Try reducing baud rate to 115,200. Also experiment with toggling DTR if that doesn’t work.

Your port is working and the controller responding so I have to think it should be capable of connecting.

It looks like lowering the baud rate was the key, thanks ! Switching back and forth between 230400 115200 seems to demonstrate this pretty consistently.
It still does not auto-detect the laser using Find My Laser but creating the device manually seems to work.
Not quite sure whose fault it is, the laser, LightBurn, the PC, Ubuntu 22.04, the ghost in the machine, … but many thanks for your help !

Glad that worked for you. I’m not sure under what conditions the auto-detect doesn’t work but it’s quite common. I suspect certain usb-serial drivers behave slightly different than others so may be related.

It turns out that solution is not 100% satisfying. After turning off the laser machine, it takes many (like 10 or 20) attempts restarting LightBurn and the machine to get the app to recognize the laser. There is definitely an issue communicating through the serial USB port.

Try enabling DTR to see if that changes the behavior.

It could look like some flow control related problem but enabling/disabling the DTR does not seem to change the behaviour.

Hmm… Not sure what else there could be. You could potentially try blacklisting the current driver to see if it will fallback to the usb-serial driver used in the older Ubuntu release.

That was worth giving a try but it did not work. If i blacklist the ch341 driver, lsusb -t shows:

|__ Port 6: Dev 2, If 0, Class=Vendor Specific Class, Driver=, 12M

and there is no /dev/ttyUSB* device entry.

I can’t recall how offhand but you may need to associate that USB ID to the usb-serial driver for the module to be loaded.

I haven’t been able to make it fail again for several days. I don’t like the fact i don’t understand what happened but happy to be able to make use of the machine. Thanks again for your help.

Yeah. Not exactly comforting. But glad it’s working in the moment.

Don’t feel discriminated against, there are a bunch of us are sitting in that boat with you… :crazy_face:


I’ve never had to use UDP to get something to find the port on Linux.

It’s handy if you name it something useful and different than just ‘ttyUSB*’.

I set it up for the Arduino so the port is ‘arduino*’ But before the UDP, I could ls it as either ‘tty[AU]*’.

Have fun…

:smile_cat:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.