News:

Let's find out together what makes a PIC Tick!

Main Menu

Curious issue with Auto Baud detection

Started by RGV250, Today at 06:35 PM

Previous topic - Next topic

RGV250

Hi,
I have modified the serial display from Les post here https://protoncompiler.com/index.php/topic,2116.0.html
I converted it to Amicus18 and then added BAUD selection via jumpers. I have always been interested in automatic BAUD detection so had a go at that and it was not that difficult.
The strange issue I have is that if the BAUD rate is set manually the display works fine, if I detect it automatically only the top line works, the bargraph on the bottom line does not.
I have attached all the files in case anyone is interested, I only need the serial displays for text debugging so it is not really an issue but I am curious as to why there is a difference.

Serial_LCD_Amicus_AUTO_1.zip

I have just realised I have not commented the section of code but it is very simple, the sender sends 5 x 0x55 and the receiver waits until BAUDCON.0 has changed from 1 to 0 which is when it has determined the rate.

Regards,
Bob

trastikata

You can check detected baud compared to the actual baud rate - if there is a difference of few bits, that might explain it.

RGV250

QuoteYou can check detected baud compared to the actual baud rate - if there is a difference of few bits, that might explain it.
Good point, how do I do that, just check the registers?
It is also a simulation so that could be an issue.

Regards,
Bob