mscherer / the-bus-pirate

Automatically exported from code.google.com/p/the-bus-pirate
0 stars 0 forks source link

Automatic Baud Detection on Transparent UART Bridge Mode #32

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
The UART bridge mode might include an option for automatic baud detection
if the target device's baud rate is unknown.

When the baud rate is unknown the bus pirate can look at a few incoming
characters and then time the received bits to figure out the proper baud rate.

After the incoming baud rate is detected, then it enters a mode where it
translates from that baud rate to the configured host baud rate (the user
defines it).

With this feature implemented the user can simply plug the bus pirate into
an unknown serial interface and read from it without going through the pain
of manually sweeping all available baud rates until ungarbled data starts
to appear.

Original issue reported on code.google.com by david.e...@gmail.com on 7 Aug 2009 at 12:47

GoogleCodeExporter commented 8 years ago

Original comment by ianles...@gmail.com on 25 Aug 2009 at 4:16

GoogleCodeExporter commented 8 years ago
Here's something I saw about this:
http://spritesmods.com/?art=autobaud&page=3

I'd like to add this as a macro.

Original comment by ianles...@gmail.com on 16 Oct 2009 at 10:43

GoogleCodeExporter commented 8 years ago

Original comment by ianles...@gmail.com on 2 Nov 2009 at 7:39

GoogleCodeExporter commented 8 years ago
What type of peripherals are available on the MISO pin?

Original comment by BrentBXR on 2 Dec 2011 at 7:13

GoogleCodeExporter commented 8 years ago
Ian; I have developed an automatic baud rate detection macro for the BP. 
Attached is a .hex file with the new UART macro. Also includes the 1wire 
library I created for BP. test it out; if you like it I will hand the source 
over to you.

Original comment by BrentBXR on 4 Dec 2011 at 10:48

Attachments:

GoogleCodeExporter commented 8 years ago
Forgot to mention; it outputs the actual calculated baud rate (using a 32bit 
timer; much like the getfreq function in auxpin.c. and it also outputs the 
'nearest common baud rate' like:

Actual Baud Rate: 9683
Nearest common baud: 9600

its pretty sweet. Cannot measure above 16000000bps because the BP speed. but 
thats the the hiest end of baud anyhow so it shouldnt be an issue. I just have 
the function tell the user; baud to high must use a logic analyzer or somthing 
of that nature.

Original comment by BrentBXR on 4 Dec 2011 at 10:50