[possible fix] HL-340 USB don't work correctly (ch340 based usb-rs232 adapter)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi list,

I've got recently following device.

Bus 003 Device 014: ID 1a86:7523 QinHeng Electronics HL-340 USB-Serial adapter

ch431 kernel driver don't work correctly with this device,
when URB_FUNCTION_BULK_OR_INTERRUPT_TRANSFER answer/send wrong character

After some experiment  by passing command retrieved from usbsnoop log
it seems that ch341.c  starts working if comment out following line

// r = ch341_control_out(dev, 0x9a, 0x2518, 0x0050);

my windows driver usbsnoop  | grep "18 25"
000007: 000003 ms 000398 ms c0 95 18 25 00 00 02 00 <<<  c3 00
000036: 000004 ms 000620 ms 40 9a 18 25 c2 00 00 00 >>>
000075: 000003 ms 011673 ms 40 9a 18 25 c3 00 00 00 >>>

as you can see I get c3 while who first logged windows driver sniff get 56.

So it seems that windows driver read 2518 registry...
it mask some byte and write back
finally it restore it back to original value before communication starts.

please note that my device after following command
r = ch341_control_in(dev, 0x5f, 0, 0, buffer, size); (
answer 0x3000, so it should be a more recent hardware version.

ch34x linux driver from the oem confirmed that 0x5f means hardware version)

I need someone that have same device or other devices that needs
ch341.ko to check that it works properly even if you comment out
before sending a patch back to the ML.

Regards

Eddi De Pieri
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux