I want to know the difference between
ttyAMA0 on Linux.
ttyS0is the device for the first UART serial port on x86 and x86_64 architectures. If you have a PC motherboard with serial ports you'd be using a
ttySnto attach a modem or a serial console.
ttyUSB0is the device for the first USB serial convertor. If you have an USB serial cable you'd be using a
ttyUSBnto connect to the serial port of a router.
ttyAMA0is the device for the first serial port on ARM architecture. If you have an ARM-based TV box with a serial console and running Android or OpenELEC, you'd be using a
ttyAMAnto attach a console to it.
What you get on host when you connect to target with this:
This port is not present on most laptops or small devboards, but is still present on desktops, and is very convenient for OS developers.
You also get it with
qemu -device isa-serial.
What you get on host when using either of:
And this is how I connect the GPIOs of my Raspberry Pi to my laptop!
And another RPI connector type:
An ARM thing as mentioned by Sato.
Haven't run into that for real hardware, will post pics when I do. I think I would be able to connect my desktop with a serial port to my RPI with that interface: https://raspberrypi.stackexchange.com/questions/69697/what-is-dev-ttyama0
But I've used it with QEMU: https://github.com/buildroot/buildroot/tree/27d7ef126bc7f4eb1a757128466befa11245bbfd/board/qemu/arm-versatile
It seems that AMA is shortened form of AMBA? https://www.raspberrypi.org/forums/viewtopic.php?t=8075 But why would they shorten a 4 character acronym?!
The only interesting Linux kernel hits are under: https://github.com/torvalds/linux/blob/v4.16/drivers/tty/serial/amba-pl011.c#L2488 so it seems to be strictly linked to the PL011: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0183g/index.html which is a UART controller licensed by ARM, which I think is the dominating implementation.