Embedded bootloader technology insider (three)
4. About the design and implementation of the serial terminal in the Boot Loader program, there is nothing to be more exciting than the printed information from the serial port terminal. In addition, printing information to the serial terminal is also a very important and effective debugging means. However, we often touch the serial terminal to display garbled or have no problems at all. There are two main reason for this problem: (1) Boot loader is incorrect to the initialization setting of the serial port. (2) The terminal emulation program running at the Host end is incorrect to the serial port, including: baud rate, parity, data bit, and stop bit settings. In addition, sometimes this problem will be encountered, that is: In the operation of the Boot Loader, we can correctly output information to the serial terminal, but when the Boot Loader starts the kernel, it is not possible to see the launch output information of the kernel. The reason for this problem can be considered from the following aspects: (1) First confirm that your kernel is configured with support for serial terminals when compiling and configures the correct serial driver. (2) Your Boot Loader's initialization settings for serial port may be inconsistent with the initial setting of the serial port. Furthermore, for the CPU such as S3C44B0X, the setting of the CPU clock frequency will also affect the serial port, so if the Boot Loader and the kernel are inconsistent with its CPU clock frequency, the serial terminal cannot display information correctly. (3) Finally, it is also necessary to confirm that the kernel base address used by Boot Loader must be consistent with the running base address used in compilation, especially for Uclinux. Suppose your kernel image is using the base address for compiling is 0xc0008000, but your Boot Loader loads it to the 0xC0010000, then the kernel image must not be executed correctly. V. Conclusion Boot Loader design and implementation is a very complex process. If you can't receive the exciting "uncompressing linux .................... DONE, BOOTING THE KERNEL ..."