281
edits
No edit summary |
No edit summary |
||
Line 19: | Line 19: | ||
'''Description''' | '''Description''' | ||
* On aliexpress - this link (2019) - [https://www.aliexpress.com/item/1M-USB-to-RS232-Serial-9-Pin-Adapter-Cable-w-DB9-Female-to-DB25-Male-Connector/32836478283.html | * On aliexpress - this link (2019) - [https://www.aliexpress.com/item/1M-USB-to-RS232-Serial-9-Pin-Adapter-Cable-w-DB9-Female-to-DB25-Male-Connector/32836478283.html] | ||
* This name "1M USB to RS232 Serial 9 Pin Adapter Cable w DB9 Female to DB25 Male Connector" | * This name "1M USB to RS232 Serial 9 Pin Adapter Cable w DB9 Female to DB25 Male Connector" | ||
* Raspberry Pi driver for Noobs 3.0.0 - [https://github.com/koss822/raspberrypi-ch340-driver] | * Raspberry Pi driver for Noobs 3.0.0 - [https://github.com/koss822/raspberrypi-ch340-driver] | ||
Line 28: | Line 28: | ||
'''Disadvantages''' | '''Disadvantages''' | ||
* USB Id is set to zero (all devices has same ID), so you cannot set exact device in Udev for more of these USB serial convertors | * USB Id is set to zero (all devices has same ID), so you cannot set exact device in Udev for more of these USB serial convertors | ||
== Serial bracket == | |||
[[File:Serial-bracket.png|200px|thumb|left|USB serial]] | |||
'''Description''' | |||
* On aliexpress - this link (2019) - [https://www.aliexpress.com/item/32885248044.html] | |||
* This name "Serial 9 pin DB9 RS232 Motherboard Com Port Ribbon Cable Connector Bracket 27cm Cables" | |||
'''Advantages''' | |||
* price (just 1 USD) | |||
* works with most mainboards (many mainboards has integrated serial ports, there is just no bracket in package) | |||
* works correctly with Grub | |||
== Grub configuration (tested on Ubuntu 18.04) == | |||
'''Key notes''' | |||
* Please keep in mind that if your mainboard supports it, using serial bracket over PCI Express card (which does not have to work correctly in Grub menu) is recommended | |||
* Serial speed 9600 is recommended (I run into the issues when using 115200) | |||
* If you update your GRUB configuration you won't see anything on the screen (only serial port) | |||
* Please backup your GRUB config file before making any changes | |||
* If you run into the issues with GRUB, you will have to boot from Installation CD, recover your backed-up GRUB file using this tutorial - [https://askubuntu.com/questions/493612/how-to-reinstall-grub/493616#493616] | |||
'''Modified /etc/default/grub''' | |||
<syntaxhighlight lang="bash"> | |||
# If you change this file, run 'update-grub' afterwards to update | |||
# /boot/grub/grub.cfg. | |||
# For full documentation of the options in this file, see: | |||
# info -f grub -n 'Simple configuration' | |||
GRUB_DEFAULT=0 | |||
GRUB_TIMEOUT_STYLE=menu | |||
GRUB_TIMEOUT=5 | |||
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` | |||
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash console=tty0 console=ttyS0,9600n8" | |||
GRUB_CMDLINE_LINUX="" | |||
# Uncomment to enable BadRAM filtering, modify to suit your needs | |||
# This works with Linux (no patch required) and with any kernel that obtains | |||
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) | |||
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef" | |||
# Uncomment to disable graphical terminal (grub-pc only) | |||
#GRUB_TERMINAL=console | |||
GRUB_TERMINAL=serial | |||
GRUB_SERIAL_COMMAND="serial --speed=9600 --unit=0 --word=8 --parity=no --stop=1" | |||
# The resolution used on graphical terminal | |||
# note that you can use only modes which your graphic card supports via VBE | |||
# you can see them in real GRUB with the command `vbeinfo' | |||
#GRUB_GFXMODE=640x480 | |||
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux | |||
#GRUB_DISABLE_LINUX_UUID=true | |||
# Uncomment to disable generation of recovery mode menu entries | |||
#GRUB_DISABLE_RECOVERY="true" | |||
# Uncomment to get a beep at grub start | |||
#GRUB_INIT_TUNE="480 440 1" | |||
</syntaxhighlight> | |||
'''Usage''' | |||
* After you modify file, please run "sudo update-grub" | |||
* Make sure you double check information about serial port device and make backup of your original file! | |||
== Accessing machine serial port from Raspberry Pi == | |||
[[File:Rpi.jpg|200px|thumb|left|Raspberry Pi]] | |||
* For accessing serial port use this command: ''sudo screen /dev/ttyUSB0 9600'' | |||
* You can use USB serial convertor |