Questions Tagged With serialhttp://linuxexchange.org/tags/serial/?type=rssquestions tagged <span class="tag">serial</span>enMon, 01 Jul 2013 10:27:31 -0400how to redirect the output of serial console (e.g. /dev/ttyS0) to a buffer or filehttp://linuxexchange.org/questions/3129/how-to-redirect-the-output-of-serial-console-eg-devttys0-to-a-buffer-or-file<p>Is it possible to pipe serial console output to a file or a buffer or some virtual or pseudo device (in /dev)? The Kernel command line has in startup at this point "console=null,115200". (Normally it has "console=ttyS0,115200" - my requirement is: if "console=null,115200", should the output go to some other place than ttyS0, e.g. a virtual or pseudo device or to a file/buffer)</p> <p>Maybe somebody know if there is good solution available?</p> <p>Thanks a lot in advance!</p>cremeplawenMon, 01 Jul 2013 10:27:31 -0400http://linuxexchange.org/questions/3129/how-to-redirect-the-output-of-serial-console-eg-devttys0-to-a-buffer-or-fileserialconsolettykernel-spacelogsSerial port UART FIFO buffer overridehttp://linuxexchange.org/questions/504/serial-port-uart-fifo-buffer-override<p>I install multiport serial card with WCH CH352L chipset, it has driver for Linux:</p> <h1>dmesg|grep ttyS</h1> <p>[ 1.313772] serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A [ 1.313944] serial8250: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550A [ 1.314574] 00:08: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A [ 1.314866] 00:09: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550A [ 1.315268] 0000:00:07.0: ttyS2 at I/O 0xdf00 (irq = 18) is a XScale [ 1.315502] 0000:00:07.0: ttyS3 at I/O 0xe000 (irq = 18) is a XScale</p> <h1>setserial -g /dev/ttyS*</h1> <p>/dev/ttyS0, UART: 16550A, Port: 0x03f8, IRQ: 4 /dev/ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3 /dev/ttyS2, UART: 16550A, Port: 0xdf00, IRQ: 18 - multiport card /dev/ttyS3, UART: 16550A, Port: 0xe000, IRQ: 18 - multiport card</p> <p>It read nice. When try to transfer less then 17 byte it looks ok(ttyS1 and ttyS3 connected with null-modem cable):</p> <h1>echo "1234567890123456" > /dev/ttyS3</h1> <h1>cat /dev/ttyS1</h1> <p>1234567890123456</p> <p>But when more then 16 byte:</p> <h1>echo "12345678901234567890" > /dev/ttyS3</h1> <h1>cat /dev/ttyS1</h1> <p>78905678901234567890</p> <h1>echo "12345678901234567890abcdef" > /dev/ttyS3</h1> <h1>cat /dev/ttyS1</h1> <p>1890abcdef1234567890abcdef</p> <p>16550A Uart FIFO has 16 byte buffer and it looks like how bytes in fifo buffer rewrite from begin because uart don't have time to send it out.</p> <p>Can any help me? why it don't work fine?</p>MarWed, 12 May 2010 07:48:25 -0400http://linuxexchange.org/questions/504/serial-port-uart-fifo-buffer-overrideserialuart