Joke Collection Website - Public benefit messages - The Problem of Controlling Serial Port of A6GSM Module with Single Chip Microcomputer

The Problem of Controlling Serial Port of A6GSM Module with Single Chip Microcomputer

The problem is that the baud rate between A6 and MCU is inconsistent. MCU is generally set to 9600, and A6 defaults to 1 15200. If the baud rate of the single chip microcomputer is set to 1 15200, communication can be achieved. However, if the crystal oscillator used by the single chip microcomputer is 1 1M, it is not easy to adjust it to 1 15200 (I have tried many times and failed). I use the computer serial port to connect A6 first, use AT+IPR=9600 to adjust its baud rate to 9600, and then connect the serial port of the single chip microcomputer to A6 (hot plug dialing), so that A6 can't be powered off (because A6 can't seem to save the settings, but the single chip microcomputer can restart), so that the single chip microcomputer can communicate with A6. You can verify the above method by writing a program on a single chip microcomputer to respond to different led lights according to the content of short messages. The above pro-test passed.