P89V51 and FM at 31.25kbaud

Started by Joseph Goldburg, May 19, 2005, 03:10:30 PM

Previous topic - Next topic

Joseph Goldburg

Hi all,

Q1
The data sheet on the 89V51RD2 says the bootload autobaud rates
by detecting a 'U' character.

Does anyone know weather 31.25Kbaud will be detected correctly or only the standard baud rates.... 9600, 19.2k,..... etc?

Q2,
Does  flash  magic have command line to run FM with set paramter?

Can I fix / lock bad rate at 31.25k baud?


Thanks in advance


Joseph

Andy Ayre

I'm not sure if a PC can produce a baud rate that slow or if a bootloader would be able to accurately measure it. The best way to find out is to give it a try. You can directly enter the baud rate you want to use into Flash Magic. It has to be an integer though.

Flash Magic does have a command line interface. It's documented in the manual which is available from the start menu in Windows and the Help menu in Flash Magic.

Embedded Systems Academy, Inc.
support at esacademy dot com

Joseph Goldburg

HI Andy,

Just to clarify .... The Baud rate is   31250 baud

Can FM handle this?


Regards
Joseph

Andy Ayre

Flash Magic can only handle integers in the baud rate box, so you would have to enter "31". I don't know if a PC can generate 31kbps as a baud rate.

Why are you trying to use such a low baud rate? What crystal frequency are you using and why?

Embedded Systems Academy, Inc.
support at esacademy dot com

Jan Waclawek

From the PC point of view:

1. The standard PC 16C550-compatible UART can generate only integer fractions of 115200 baud.
2. FM probably uses the Win API to set the baudrates, which is designed in a very unfortunate way, allowing only a even more limited choice of baudrates from the wider selection according to 1. (Andy can correct me).
3. The drivers of FTDI USB-RS232 chip allow to "fake" a different baudrate for a given WinAPI setting, e.g. you can have a real 31500 baud (if the FTDI chip allows it, but it generates the baudrates dividing from several megaherts so probably you can get close enough) when setting it to 9600 baud (from any application). There might be other USB-RS232 convertors or RS232 cards available with similar properties of their drivers.

From the microcontroller point of view:

The reliability of autobauding and following communication depends on particular combination of . You can read more at http://www.efton.sk/t0t1/autobaud_error.htm .


Generally:

You can design your own down/up convertor using a microcontroller with double UART (or any similar solution), buffering in both directions. Then you can possibly connect from PC using a different baudrate (e.g. 38400 baud) and to the mcu using your desired 31500 baud.


Jan Waclawek