Linux - Embedded & Single-board computerThis forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi,
I am working on LPC3250 board on linux(3.0.10) ubuntu(11.10).Basically only one UART1 has been enabled for BOOTING Process.But,In this board i want to use total 7 UARTS at a time.Then i need any special drivers for that or is it enough to enable the Standard UARTS(3,4,5,6) and HIGH SPEED UARTS(1,2,7) in menuconfig option of kernel?Please help me.
I have no experience with that board, but if I had to guess I'd say that all of them are probably "enabled" already, you just need to start using them. One of them (UART1) has been confiscated by the bootloader, and is probably hosting a TTY for the OS as well, but once you're in the OS the other 6 should be available in /dev/ like normal.
By default UART1 is displaying the booting messages But,Actually i want to display the booting messages with all UARTS at a time for my project requirement. How can i get that? Is any UART drivers are required to display booting messages by using all UARTS? I was also tried to enable them for displaying booting messages by enabling Standard and high speed UARTs in MENUCONFIG option of kernel but i didnt got it.I hope you understand what i want do sir.
sorry for asked unrelated questions.Actually i have gone through the Lpc3250 manual and in that he told that by UART1 only we can display Booting messages and we cant display the booting messages using other UARTS.Actually i want to ask the thing is how to send and recieve the data using other UARTS in Linux kernel. I have idea about KEIL in windows. Is there any tool to execute serial communication programs in linux kernel?
Lots of tools exist. The driver is built into the kernel, so you can open up the device and read and write to it using nearly any programming language you want.
You can even run something like this from the command line to dump a message out over the serial line:
You would see the message on whatever device is attached to the other end of that serial connection, or you could hook up a logic analyzer to the Tx line to capture the message.
Use a terminal emulator such as C-Kermit or minicom. On the serial interface connector, connect the Tx pin the the Rx pin. With that done, everything you type in your terminal emulator should be echoed back to the screen. This is the simplest test of a serial interface possible to perform without any test equipment. A scope on the Tx pin should show the serial output data. Continuously transmitting the 'U' character will send a nice square wave, since the bit pattern of 'U' is alternating 1 & 0.
--- rod.
I tested with another PC which is attached to the UART5 of my LPC3250 and i have make echo then the data is recieved at that PC hyperterminal. But if i perform same operation with other UARTs like 2,3,4,6,7 of my board, then nothing is displayed on another end of PC hyperterminal.What may be the problem actually?
All kinds of potential problems. If you first perform the loopback test like I suggested, we can at east start to narrow down the possibilities. What does the datasheet for your board say about the nature of the UARTs in the system? Do you have a kernel with the correct drivers built in, or with the correct loadable modules installed? If you try to communicate through the serial interface, you need to have all of the communications parameters set in accordance with the peer host settings. Have you confirmed that this has been correctly done? Many devices use non-standard wiring of their connectors in order to save connector real-estate. How have you confirmed that your serial connectors are correctly connected to the peer PC?
The Datasheet states that we can load the loaders like kickstart and Stage1 using UART5 and we can boot the kernel messages using UART1 and it is not mentioned anything about other UARTs whether they are used for load and displaying purpose or not. I didnot performed loopback test but i am sure that all UARTs working properly in windows with KEIL but problem is when i am checking in LINUX KERNEL 2.6.34 version (I was installed this version on my host PC).is this version contains all UARTS drivers or not?If this version dont have all UART drivers then how can we install other drivers? If you idea please post the reply. I am waiting for reply.
The Datasheet states that we can load the loaders like kickstart and Stage1 using UART5 and we can boot the kernel messages using UART1 and it is not mentioned anything about other UARTs whether they are used for load and displaying purpose or not. I didnot performed loopback test but i am sure that all UARTs working properly in windows with KEIL but problem is when i am checking in LINUX KERNEL 2.6.34 version (I was installed this version on my host PC).is this version contains all UARTS drivers or not?If this version dont have all UART drivers then how can we install other drivers? If you idea please post the reply. I am waiting for reply.
Thanks & Regards,
MOHAMMAD BIYABANI
The kernel uses one and only one UART for it's default console. I have never heard of having multiple kernel consoles running concurrently, and don't see this being any kind of standard that the kernel could accommodate without modification. The kernel can be told by the bootloader which serial port to use as the console, and there is probably a built in default that is used in the absence of any specified console.
How is it that you are sure that all UART's are working, by doing some kind of test from a completely different host? They may well be working, but without actually exercising them, you are only assuming that. Simply running a similar kernel version on some other hardware tells you absolutely nothing whatsoever. The driver(s) for the UARTs depends on the type of hardware that implements the UART. Without knowing the nature of that hardware, it is impossible to know whether the drivers are installed, or even exist at all. There are many kinds of UARTs, and on small ARM systems, it is not uncommon for there to be custom UART implementations done in on-board FPGAs. In that case, only the vendor knows for sure how to interface to them, and this should be documented.
I suggest a Google search for 'Linux serial console' as a jumping off point for further research. It will undoubtedly turn up a link to the Linux Serial Console HOWTO, among others.
Today i have tested my board with loopback method(i connected TX to RX of UARTs) when i enter the characters on keyboard using UART5 and UART2 but nothing displayed on console(i used minicom program)linux os. I was checked my code which is dumping into my board that contains all code related to UARTs. And i also cheched my linux kernel that also contains the TTY drivers. can i confirm that fault in hardware or we need any extra drivers for serial communication?
If the loopback test fails, then either the drivers are not loaded (but this is probably not the case),the hardware is faulty, or your port require some related handshake pins to be enabled, such as CTS. On boot (or with dmesg), do you see log entries that show successful loading of drivers for all ports? you say you've found drivers built into your kernel, but have you verified that they are actually the correct drivers? Are you sure you're using device names correctly associated with the respective UARTS (e.g. /dev/ttySx)? When you run setserial against each serial port, what are the results? Are you certain that you've connected the proper port pins in the loopback test?
Since you're now talking about your own code, here are some links to augment your understanding of matters related to that. Also, a link to a superior IMHO serial communications package.
Hi sir,
1.MY console displaying messages about serial ports at the time of booting in linux(minicom)
Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0x40090000 (irq = 9) is a 16550A
serial8250.0: ttyS1 at MMIO 0x40080000 (irq = 7) is a 16550A
serial8250.0: ttyS2 at MMIO 0x40088000 (irq = 8) is a 16550A
serial8250.0: ttyS3 at MMIO 0x40098000 (irq = 10) is a 16550A
lpc32xx_hsuart.0: ttyTX0 at MMIO 0x40014000 (irq = 26) is a lpc32xx_hsuart
console [ttyTX0] enabled
lpc32xx_hsuart.0: ttyTX1 at MMIO 0x40018000 (irq = 25) is a lpc32xx_hsuart
lpc32xx_hsuart.0: ttyTX2 at MMIO 0x4001c000 (irq = 24) is a lpc32xx_hsuart
brd: module loaded
loop: module loaded
2.In application the drivers i have are (in linux after booting)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.