Freetz erkennt USB-rs232 nicht

Nico84

Neuer User
Mitglied seit
27 Sep 2011
Beiträge
42
Punkte für Reaktionen
0
Punkte
0
Hallo,

ich habe diesen USB - RS232 Adapter. Irgendwie bekomme ich ihn nicht im Freetz zum laufen.

Code:
T:  Bus=01 Lev=02 Prnt=02 Port=01 Cnt=02 Dev#=  6 Spd=12  MxCh= 0
D:  Ver= 1.10 Cls=ff(vend.) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=1a86 ProdID=7523 Rev= 2.52
S:  Product=USB2.0-Serial
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr= 96mA
I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=02 Driver=(none)
E:  Ad=82(I) Atr=02(Bulk) MxPS=  32 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=  32 Ivl=0ms
E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=1ms

Einen anderen, ich glaube von Digitus, erkennt die Box problemlos.

Code:
T:  Bus=01 Lev=02 Prnt=02 Port=00 Cnt=01 Dev#=  3 Spd=12  MxCh= 0
D:  Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=0403 ProdID=6001 Rev= 4.00
S:  Manufacturer=fidi
S:  Product=usb serial conerter
S:  SerialNumber=ftAKHM09
C:* #Ifs= 1 Cfg#= 1 Atr=a0 MxPwr= 44mA
I:  If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=ftdi_sio
E:  Ad=81(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=  64 Ivl=0ms

Die Treiber habe ich beim Image erstellen ausgewählt. Was kann ich noch probieren?
 
Als was wird er denn unter Windows erkannt? pl2303? Dann brauchst du auch das entsprechende Modul auf der Box.

Gruß
Oliver
 
Gute Frage. Hilft das?

attachment.php


Der Adapter sieht blau grünlich aus. Wie die prolific Teile.

pl2303 habe ich aber mit drauf.
 

Anhänge

  • usb.JPG
    usb.JPG
    24.4 KB · Aufrufe: 124
Auf dem Bild steht auch nicht mehr drauf als im Text am Anfang, und ob das Gehäuse jetzt blau grünlich oder anders ist, spielt auch keine Rolle.

Anscheinend handelt es sich um eine Variante des CH341, wird aber mit dem normalen Treiber nicht erkannt. Auf welcher Box und mit welchen Kernel hast Du es denn versucht?
 
Ich habe eine 7141 mit dem freetz-stable-1.2 . Bin da aber flexibel.

Kernel : 2.6.13.1-ohio (2349) (gcc-Version 3.4.6)
 
Das Modul ist in der Kernel Config nicht aktiviert:
Code:
# CONFIG_USB_SERIAL_CH341 is not set
Und erst ab 2.6.28 verfügbar.

Gruß
Oliver
 
Wo bekomme ich den her? ich habe das Freetz-linux in einer vm laufen.
 
Für eine 7141: gar nicht
Denn diese läuft mit Kernel 2.6.13.1

Gruß
Oliver
 
Du kannst versuchen, folgendes (Aus Diesem 2.6.18-Backport geringfügig angepasst) unter dem Namen "ch341.patch" in make/linux/patches/2.6.13.1/ zu packen:
Code:
diff -uprN -X linux-2.6.13.1/Documentation/dontdiff linux-2.6.13.1/Documentation/usb/usb-serial.txt linux-2.6.13.1/Documentation/usb/usb-serial.txt
--- linux-2.6.13.1/Documentation/usb/usb-serial.txt	2007-08-21 19:57:50.000000000 +0100
+++ linux-2.6.13.1/Documentation/usb/usb-serial.txt	2011-09-28 11:10:02.000000000 +0100
@@ -428,6 +428,17 @@ Options supported:
   See http://www.uuhaus.de/linux/palmconnect.html for up-to-date
   information on this driver.

+Winchiphead CH341 Driver
+
+  This driver is for the Winchiphead CH341 USB-RS232 Converter. This chip
+  also implements an IEEE 1284 parallel port, I2C and SPI, but that is not
+  supported by the driver. The protocol was analyzed from the behaviour
+  of the Windows driver, no datasheet is available at present.
+  The manufacturer's website: http://www.winchiphead.com/.
+  For any questions or problems with this driver, please contact
+  [email protected].
+
+
 Generic Serial driver

   If your device is not one of the above listed devices, compatible with
diff -uprN -X linux-2.6.13.1/Documentation/dontdiff linux-2.6.13.1/drivers/usb/serial/Kconfig linux-2.6.13.1/drivers/usb/serial/Kconfig
--- linux-2.6.13.1/drivers/usb/serial/Kconfig	2007-08-21 19:57:27.000000000 +0100
+++ linux-2.6.13.1/drivers/usb/serial/Kconfig	2011-09-28 11:10:02.000000000 +0100
@@ -92,6 +92,16 @@ config USB_SERIAL_BELKIN
 	  To compile this driver as a module, choose M here: the
 	  module will be called belkin_sa.
 
+config USB_SERIAL_CH341
+	tristate "USB Winchiphead CH341 Single Port Serial Driver"
+	depends on USB_SERIAL
+	help
+	  Say Y here if you want to use a Winchiphead CH341 single port
+	  USB to serial adapter.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called ch341.
+
 config USB_SERIAL_WHITEHEAT
 	tristate "USB ConnectTech WhiteHEAT Serial Driver"
 	depends on USB_SERIAL
diff -uprN -X linux-2.6.13.1/Documentation/dontdiff linux-2.6.13.1/drivers/usb/serial/Makefile linux-2.6.13.1/drivers/usb/serial/Makefile
--- linux-2.6.13.1/drivers/usb/serial/Makefile	2007-08-21 19:57:26.000000000 +0100
+++ linux-2.6.13.1/drivers/usb/serial/Makefile	2011-09-28 11:10:02.000000000 +0100
@@ -15,6 +15,7 @@ obj-$(CONFIG_USB_SERIAL_AIRCABLE)		+= ai
 obj-$(CONFIG_USB_SERIAL_AIRPRIME)		+= airprime.o
 obj-$(CONFIG_USB_SERIAL_ARK3116)		+= ark3116.o
 obj-$(CONFIG_USB_SERIAL_BELKIN)			+= belkin_sa.o
+obj-$(CONFIG_USB_SERIAL_CH341)			+= ch341.o
 obj-$(CONFIG_USB_SERIAL_CP2101)			+= cp2101.o
 obj-$(CONFIG_USB_SERIAL_CYBERJACK)		+= cyberjack.o
 obj-$(CONFIG_USB_SERIAL_CYPRESS_M8)		+= cypress_m8.o
diff -uprN -X linux-2.6.13.1/Documentation/dontdiff linux-2.6.13.1/drivers/usb/serial/ch341.c linux-2.6.13.1/drivers/usb/serial/ch341.c
--- linux-2.6.13.1/drivers/usb/serial/ch341.c	1970-01-01 01:00:00.000000000 +0100
+++ linux-2.6.13.1/drivers/usb/serial/ch341.c	2007-08-21 20:34:03.000000000 +0100
@@ -0,0 +1,443 @@
+/*
+ * Copyright 2007, Frank A Kingswood <[email protected]>
+ *
+ * ch341.c implements a serial port driver for the Winchiphead CH341.
+ *
+ * The CH341 device can be used to implement an RS232 asynchronous
+ * serial port, an IEEE-1284 parallel printer port or a memory-like
+ * interface. In all cases the CH341 supports an I2C interface as well.
+ * This driver only supports the asynchronous serial interface.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License version
+ * 2 as published by the Free Software Foundation.
+ */
+
+#include <linux/kernel.h>
+#include <linux/init.h>
+#include <linux/tty.h>
+#include <linux/tty_flip.h>
+#include <linux/module.h>
+#include <linux/usb.h>
+#include "usb-serial.h"
+#include <linux/serial.h>
+
+#define DEFAULT_BAUD_RATE 2400
+#define DEFAULT_TIMEOUT   1000
+
+static int debug;
+
+static struct usb_device_id id_table [] = {
+	{ USB_DEVICE(0x4348, 0x5523) },
+	{ USB_DEVICE(0x1a86, 0x7523) },
+	{ },
+};
+MODULE_DEVICE_TABLE(usb, id_table);
+
+struct ch341_private {
+	unsigned baud_rate;
+	u8 dtr;
+	u8 rts;
+};
+
+/*
+ *	tty_termios_copy_hw	-	copy hardware settings
+ *	@new: New termios
+ *	@old: Old termios
+ *
+ *	Propogate the hardware specific terminal setting bits from
+ *	the old termios structure to the new one. This is used in cases
+ *	where the hardware does not support reconfiguration or as a helper
+ *	in some cases where only minimal reconfiguration is supported
+ */
+
+void tty_termios_copy_hw(struct termios *new, struct termios *old)
+{
+	/* The bits a dumb device handles in software. Smart devices need
+	   to always provide a set_termios method */
+	new->c_cflag = 1;
+	new->c_cflag &= HUPCL | CREAD | CLOCAL;
+	new->c_cflag |= old->c_cflag & ~(HUPCL | CREAD | CLOCAL);
+}
+
+static int ch341_control_out(struct usb_device *dev, u8 request,
+			     u16 value, u16 index)
+{
+	int r;
+	dbg("ch341_control_out(%02x,%02x,%04x,%04x)", USB_DIR_OUT|0x40,
+		(int)request, (int)value, (int)index);
+
+	r = usb_control_msg(dev, usb_sndctrlpipe(dev, 0), request,
+			    USB_TYPE_VENDOR | USB_RECIP_DEVICE | USB_DIR_OUT,
+			    value, index, NULL, 0, DEFAULT_TIMEOUT);
+
+	return r;
+}
+
+static int ch341_control_in(struct usb_device *dev,
+			    u8 request, u16 value, u16 index,
+			    char *buf, unsigned bufsize)
+{
+	int r;
+	dbg("ch341_control_in(%02x,%02x,%04x,%04x,%p,%u)", USB_DIR_IN|0x40,
+		(int)request, (int)value, (int)index, buf, (int)bufsize);
+
+	r = usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), request,
+			    USB_TYPE_VENDOR | USB_RECIP_DEVICE | USB_DIR_IN,
+			    value, index, buf, bufsize, DEFAULT_TIMEOUT);
+	return r;
+}
+
+static int ch341_set_baudrate(struct usb_device *dev,
+			      struct ch341_private *priv)
+{
+	short a, b;
+	int r;
+
+	dbg("ch341_set_baudrate(%d)", priv->baud_rate);
+	switch (priv->baud_rate) {
+	case 2400:
+		a = 0xd901;
+		b = 0x0038;
+		break;
+	case 4800:
+		a = 0x6402;
+		b = 0x001f;
+		break;
+	case 9600:
+		a = 0xb202;
+		b = 0x0013;
+		break;
+	case 19200:
+		a = 0xd902;
+		b = 0x000d;
+		break;
+	case 38400:
+		a = 0x6403;
+		b = 0x000a;
+		break;
+	case 115200:
+		a = 0xcc03;
+		b = 0x0008;
+		break;
+	default:
+		return -EINVAL;
+	}
+
+	r = ch341_control_out(dev, 0x9a, 0x1312, a);
+	if (!r)
+		r = ch341_control_out(dev, 0x9a, 0x0f2c, b);
+
+	return r;
+}
+
+static int ch341_set_handshake(struct usb_device *dev,
+			       struct ch341_private *priv)
+{
+	dbg("ch341_set_handshake(%d,%d)", priv->dtr, priv->rts);
+	return ch341_control_out(dev, 0xa4,
+		~((priv->dtr?1<<5:0)|(priv->rts?1<<6:0)), 0);
+}
+
+static int ch341_get_status(struct usb_device *dev)
+{
+	char *buffer;
+	int r;
+	const unsigned size = 8;
+
+	dbg("ch341_get_status()");
+
+	buffer = kmalloc(size, GFP_KERNEL);
+	if (!buffer)
+		return -ENOMEM;
+
+	r = ch341_control_in(dev, 0x95, 0x0706, 0, buffer, size);
+	if (r < 0)
+		goto out;
+
+	/* Not having the datasheet for the CH341, we ignore the bytes returned
+	 * from the device. Return error if the device did not respond in time.
+	 */
+	r = 0;
+
+out:	kfree(buffer);
+	return r;
+}
+
+/* -------------------------------------------------------------------------- */
+
+static int ch341_configure(struct usb_device *dev, struct ch341_private *priv)
+{
+	char *buffer;
+	int r;
+	const unsigned size = 8;
+
+	dbg("ch341_configure()");
+
+	buffer = kmalloc(size, GFP_KERNEL);
+	if (!buffer)
+		return -ENOMEM;
+
+	/* expect two bytes 0x27 0x00 */
+	r = ch341_control_in(dev, 0x5f, 0, 0, buffer, size);
+	if (r < 0)
+		goto out;
+
+	r = ch341_control_out(dev, 0xa1, 0, 0);
+	if (r < 0)
+		goto out;
+
+	r = ch341_set_baudrate(dev, priv);
+	if (r < 0)
+		goto out;
+
+	/* expect two bytes 0x56 0x00 */
+	r = ch341_control_in(dev, 0x95, 0x2518, 0, buffer, size);
+	if (r < 0)
+		goto out;
+
+	r = ch341_control_out(dev, 0x9a, 0x2518, 0x0050);
+	if (r < 0)
+		goto out;
+
+	/* expect 0xff 0xee */
+	r = ch341_get_status(dev);
+	if (r < 0)
+		goto out;
+
+	r = ch341_control_out(dev, 0xa1, 0x501f, 0xd90a);
+	if (r < 0)
+		goto out;
+
+	r = ch341_set_baudrate(dev, priv);
+	if (r < 0)
+		goto out;
+
+	r = ch341_set_handshake(dev, priv);
+	if (r < 0)
+		goto out;
+
+	/* expect 0x9f 0xee */
+	r = ch341_get_status(dev);
+
+out:	kfree(buffer);
+	return r;
+}
+
+/* allocate private data */
+static int ch341_attach(struct usb_serial *serial)
+{
+	struct ch341_private *priv;
+	int r;
+
+	dbg("ch341_attach()");
+
+	/* private data */
+	priv = kcalloc(1,sizeof(struct ch341_private), GFP_KERNEL);
+	if (!priv)
+		return -ENOMEM;
+
+	priv->baud_rate = DEFAULT_BAUD_RATE;
+	priv->dtr = 1;
+	priv->rts = 1;
+
+	r = ch341_configure(serial->dev, priv);
+	if (r < 0)
+		goto error;
+
+	usb_set_serial_port_data(serial->port[0], priv);
+	return 0;
+
+error:	kfree(priv);
+	return r;
+}
+
+/* shameless copy of usb_serial_generic_read_bulk_callback from generic.c */
+void usb_serial_ch341_read_bulk_callback (struct urb *urb, struct pt_regs *regs)
+{
+	struct usb_serial_port *port = (struct usb_serial_port *)urb->context;
+	struct usb_serial *serial = port->serial;
+	struct tty_struct *tty;
+	unsigned char *data = urb->transfer_buffer;
+	int i;
+	int result;
+
+	dbg("%s - port %d", __FUNCTION__, port->number);
+
+	if (urb->status) {
+		dbg("%s - nonzero read bulk status received: %d", __FUNCTION__, urb->status);
+		return;
+	}
+
+	usb_serial_debug_data(debug, &port->dev, __FUNCTION__, urb->actual_length, data);
+
+	tty = port->tty;
+	if (tty && urb->actual_length) {
+		for (i = 0; i < urb->actual_length ; ++i) {
+			/* if we insert more than TTY_FLIPBUF_SIZE characters, we drop them. */
+			if(tty->flip.count >= TTY_FLIPBUF_SIZE) {
+				tty_flip_buffer_push(tty);
+			}
+			/* this doesn't actually push the data through unless tty->low_latency is set */
+			tty_insert_flip_char(tty, data[i], 0);
+		}
+	  	tty_flip_buffer_push(tty);
+	}
+
+	/* Continue trying to always read  */
+	usb_fill_bulk_urb (port->read_urb, serial->dev,
+			   usb_rcvbulkpipe (serial->dev,
+				   	    port->bulk_in_endpointAddress),
+			   port->read_urb->transfer_buffer,
+			   port->read_urb->transfer_buffer_length,
+			   ((serial->type->read_bulk_callback) ? 
+			     serial->type->read_bulk_callback : 
+			     usb_serial_ch341_read_bulk_callback), port);
+	result = usb_submit_urb(port->read_urb, GFP_ATOMIC);
+	if (result)
+		dev_err(&port->dev, "%s - failed resubmitting read urb, error %d\n", __FUNCTION__, result);
+}
+
+
+
+/* open this device, set default parameters */
+static int ch341_open(struct usb_serial_port *port, struct file *filp)
+{
+	struct usb_serial *serial = port->serial;
+	struct ch341_private *priv = usb_get_serial_port_data(serial->port[0]);
+	int r;
+
+	dbg("ch341_open()");
+
+	priv->baud_rate = DEFAULT_BAUD_RATE;
+	priv->dtr = 1;
+	priv->rts = 1;
+
+	r = ch341_configure(serial->dev, priv);
+	if (r)
+		goto out;
+
+	r = ch341_set_handshake(serial->dev, priv);
+	if (r)
+		goto out;
+
+	r = ch341_set_baudrate(serial->dev, priv);
+	if (r)
+		goto out;
+	/* from here on copied from usb_serial_generic_open in generic.c */
+	dbg("%s - port %d", __FUNCTION__, port->number);
+
+	/* force low_latency on so that our tty_push actually forces the data through, 
+	   otherwise it is scheduled, and with high data rates (like with OHCI) data
+	   can get lost. */
+	if (port->tty)
+		port->tty->low_latency = 1;
+
+	/* if we have a bulk interrupt, start reading from it */
+	if (serial->num_bulk_in) {
+		/* Start reading from the device */
+		usb_fill_bulk_urb (port->read_urb, serial->dev,
+				   usb_rcvbulkpipe(serial->dev, port->bulk_in_endpointAddress),
+				   port->read_urb->transfer_buffer,
+				   port->read_urb->transfer_buffer_length,
+				   ((serial->type->read_bulk_callback) ?
+				     serial->type->read_bulk_callback :
+				     usb_serial_ch341_read_bulk_callback),
+				   port);
+		r = usb_submit_urb(port->read_urb, GFP_KERNEL);
+		if (r)
+			dev_err(&port->dev, "%s - failed resubmitting read urb, error %d\n", __FUNCTION__, r);
+	}
+
+
+out:	return r;
+}
+
+/* Old_termios contains the original termios settings and
+ * tty->termios contains the new setting to be used.
+ */
+static void ch341_set_termios(struct usb_serial_port *port,
+			      struct termios *old_termios)
+{
+	struct ch341_private *priv = usb_get_serial_port_data(port);
+	struct tty_struct *tty = port->tty;
+	unsigned baud_rate;
+
+	dbg("ch341_set_termios()");
+
+	baud_rate = tty_get_baud_rate(tty);
+
+	switch (baud_rate) {
+	case 2400:
+	case 4800:
+	case 9600:
+	case 19200:
+	case 38400:
+	case 115200:
+		priv->baud_rate = baud_rate;
+		break;
+	default:
+		dbg("Rate %d not supported, using %d",
+			baud_rate, DEFAULT_BAUD_RATE);
+		priv->baud_rate = DEFAULT_BAUD_RATE;
+	}
+
+	ch341_set_baudrate(port->serial->dev, priv);
+
+	/* Unimplemented:
+	 * (cflag & CSIZE) : data bits [5, 8]
+	 * (cflag & PARENB) : parity {NONE, EVEN, ODD}
+	 * (cflag & CSTOPB) : stop bits [1, 2]
+	 */
+
+	 /* Copy back the old hardware settings */
+	 tty_termios_copy_hw(tty->termios, old_termios);
+}
+
+static struct usb_driver ch341_driver = {
+	.name		= "ch341",
+	.probe		= usb_serial_probe,
+	.disconnect	= usb_serial_disconnect,
+	.id_table	= id_table,
+};
+
+static struct usb_serial_device_type ch341_device = {
+	.owner               = THIS_MODULE,
+	.name                = "ch341-uart",
+	.id_table            = id_table,
+	.num_interrupt_in    = NUM_DONT_CARE,
+	.num_bulk_in         = NUM_DONT_CARE,
+	.num_bulk_out        = NUM_DONT_CARE,
+	.num_ports           = 1,
+	.open                = ch341_open,
+	.set_termios         = ch341_set_termios,
+	.attach              = ch341_attach,
+};
+
+static int __init ch341_init(void)
+{
+	int retval;
+
+	retval = usb_serial_register(&ch341_device);
+	if (retval)
+		return retval;
+	retval = usb_register(&ch341_driver);
+	if (retval)
+		usb_serial_deregister(&ch341_device);
+	return retval;
+}
+
+static void __exit ch341_exit(void)
+{
+	usb_deregister(&ch341_driver);
+	usb_serial_deregister(&ch341_device);
+}
+
+module_init(ch341_init);
+module_exit(ch341_exit);
+MODULE_LICENSE("GPL");
+
+module_param(debug, bool, S_IRUGO | S_IWUSR);
+MODULE_PARM_DESC(debug, "Debug enabled or not");
+
+/* EOF ch341.c */

Danach: make kernel-dirclean && make kernel-menuconfig
Dann kannst du unter "Device Drivers" -> "USB Support" -> "USB Serial Converter support" den "USB Winchiphead CH341 Single Port Serial Driver" auswählen. Das resultierende Modul heißt ch341.ko (in drivers/usb/serial) und muss dann noch ins Image oder sonstwie auf die Box gelangen. usbcore.ko und usbserial.ko werden natürlich auch gebraucht.
Kompilieren und laden (insmod) lässt es sich, aber mangels so einem Adapter kann ich nicht ausprobieren ob es auch funktioniert. Permanent kaputt machen kann es theoretisch nichts (dafür kann ich aber keine Garantie übernehmen), höchstens einfach nicht funktionieren oder beim Gebrauch die Box zum Absturz bringen. Dann musst du es eben wieder rausnehmen (ch341.patch löschen, make kernel-dirclean, dann image neu bauen, bzw. falls du es gar nicht fest im Image hattest einfach das Modul wieder löschen) und doch einen anderen Adapter verwenden.
 
Da bekomme ich immer ein Fehler:
Code:
Last login: Wed Sep 28 15:37:59 2011 from 192.168.xxx.xxx
freetz@freetz-linux:~$ cd freetz-stable-1.2
freetz@freetz-linux:~/freetz-stable-1.2$ make kernel-dirclean && make kernel-menuconfig
checking structure...  unpacking...  preparing... patch: **** malformed patch at line 498:

ERROR: modpatch: Error in patch-file make/linux/patches/2.6.13.1/ch341.patch
make: *** [source/kernel/ref-ohio-8mb-04.76/.unpacked] Fehler 2
freetz@freetz-linux:~/freetz-stable-1.2$
 
Zuletzt bearbeitet:
Bei mir funktioniert der Patch, allerdings nicht exakt:
Code:
patching file linux-2.6.13.1/Documentation/usb/usb-serial.txt
Hunk #1 succeeded at 434 with fuzz 2 (offset 6 lines).
patching file linux-2.6.13.1/drivers/usb/serial/Kconfig
Hunk #1 succeeded at 73 with fuzz 1 (offset -19 lines).
patching file linux-2.6.13.1/drivers/usb/serial/Makefile
Hunk #1 succeeded at 13 with fuzz 2 (offset -2 lines).
patching file linux-2.6.13.1/drivers/usb/serial/ch341.c
Ich habe im Trac Ticket #1531 angelegt. Bitte um Rückmeldung, ob es funktioniert.
 
Dann kannst du unter "Device Drivers" -> "USB Support" -> "USB Serial Converter support" den "USB Winchiphead CH341 Single Port Serial Driver"

Die Frage bei CH341 [N/m/?] habe ich mit m beantwortet. war das richtig?
Muss ich dann nicht noch den Treiber über make menuconfig in Kernel modules -> drivers auswählen? Da finde ich ihn nicht.
 
Da wird er auch nicht sein, wenn nicht zusätzlich ein Eintrag in der Datei kernel/Config.in erstellt wird.

Du kannst dort entweder einen passenden Eintrag erstellen oder das Modul von Hand auf die Box bringen und in den Kernel laden.
 
Die Box läuft mit USB-root. Also kopiere ich die ch341.ko auf den Stick in \rootfs\lib\modules\2.6.13.1-ohio\kernel\drivers\usb\serial. Aber wie lade ich es dann?

Edit: im moment bleibe ich nach "make" hängen_

Making install in tests
---> library/libfreetz: downloading... preparing... building... done.
---> library/zlib: downloading... preparing... configuring... building... done.
---> library/libpng: downloading... preparing... configuring... building... done.
---> library/libart_lgpl: downloading... preparing... configuring... building... done.
---> library/freetype: downloading... preparing... configuring... building... done.
---> library/pcre: downloading... preparing... configuring... building... done.
---> package/rrdtool: downloading... preparing... configuring... building... done.
---> package/busybox: preparing... building... done.
---> kernel: kernel image... building... modules... done.
---> package/digitemp: downloading... preparing... building... ^Cmake: *** wait: Keine Kind-Prozesse. Schluss.
make: *** Warte auf noch nicht beendete Prozesse...
make: *** wait: Keine Kind-Prozesse. Schluss.
freetz@freetz-linux:~/freetz-stable-1.2$

Edit2:

Hat nun doch geklappt, habe die Datei auf den Stick kopiert, aber wie lade ich den nun?
 
Zuletzt bearbeitet:
okay, verwenden tut er ihn nun anscheinend:
Code:
T:  Bus=01 Lev=02 Prnt=02 Port=01 Cnt=02 Dev#=  6 Spd=12  MxCh= 0
D:  Ver= 1.10 Cls=ff(vend.) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=1a86 ProdID=7523 Rev= 2.52
S:  Product=USB2.0-Serial
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr= 96mA
I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=02 Driver=ch341
E:  Ad=82(I) Atr=02(Bulk) MxPS=  32 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=  32 Ivl=0ms
E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=1ms

Allerdings funktioniert digitemp damit nicht. Oder muss ich noch etwas einstellen?
 
Wie kann ich das von Hand testen? Wenn ich dann den funktionierenden Adapter anstecke ist der ttyUSB1 und funktioniert dann auch. Aber auf ttyUSB0 geht nix.
 

Statistik des Forums

Themen
246,243
Beiträge
2,248,649
Mitglieder
373,818
Neuestes Mitglied
RainerP
Holen Sie sich 3CX - völlig kostenlos!
Verbinden Sie Ihr Team und Ihre Kunden Telefonie Livechat Videokonferenzen

Gehostet oder selbst-verwaltet. Für bis zu 10 Nutzer dauerhaft kostenlos. Keine Kreditkartendetails erforderlich. Ohne Risiko testen.

3CX
Für diese E-Mail-Adresse besteht bereits ein 3CX-Konto. Sie werden zum Kundenportal weitergeleitet, wo Sie sich anmelden oder Ihr Passwort zurücksetzen können, falls Sie dieses vergessen haben.