2010-06-28 08:03:01     same kernel produces different baudrates on different boards

Document created by Aaronwu Employee on Aug 22, 2013
Version 1Show Document
  • View in full screen mode

2010-06-28 08:03:01     same kernel produces different baudrates on different boards

Samuel Jaißle (GERMANY)

Message: 90679   


Hi everybody,




I'm a supervising the embedded systems lab at my university as a tutor. We use the BF537-stamp boards. The students learn how to set up uClinux on the blackfin and run an application with can-communication between two boards. Now my problem:


There are few boards that won't produce a clear output with minicom. I found out, that the baud rate in uClinux is set to 38400 baud instead of 57600. Minicom and U-Boot are set to 57600 and so when booting, I get the output of U-Boot correctly but when uClinux takes over the control, it isn't readable any more (for it is send with 38400 baud and recieved with 67600).


Exactly the same kernel image on another board works fine with 57600 baud. And when I take one of these boards with 38400 baud and set the baudrate of U-Boot and minicom to 38400 baud, too, it works fine again. But that isn't a practical workaround, for the students don't have specific boards they use every lesson, so it might be every week a different group that has to work with a different baud rate. To avoid this, I am looking for the reason that these few boards are using a different baud rate with the same settings. The only difference I found between these that work with 57600 baud and the few that don't, is that U-Boot of these few is set to 125 MHz system clock, while the rest works with 100 MHz. But as soon as the kernel is running, the frequencys are the same on all boards.


Does anyone have an idea where to go on searching? Thanks a lot!








2010-06-28 12:42:36     Re: same kernel produces different baudrates on different boards

Mike Frysinger (UNITED STATES)

Message: 90694   


you didnt say what version of software you're running, or show any kernel boot logs, so it's hard to say anything that isnt a guess


considering the SCLK differences, you probably arent running the same u-boot version, so you should go through and upgrade them all to the same exact version




2010-07-01 05:18:37     Re: same kernel produces different baudrates on different boards

Samuel Jaißle (GERMANY)

Message: 90801   


Sorry, just forgot that.


I'm using uclinux 2009R1.1-RC4 and the toolchain version 2009R1.1-RC2.


The boards have different u-boot versions, but I couldn't find that it is a specific version that causes the trouble. But I'll test it with one board, if an update makes a differece for the baud rate.


Now the boot log:




CPU:   ADSP BF537 Rev.: 0.2

Board: ADI BF537 stamp board

       Support:   blackfin.uclinux.org/

Clock: VCO: 500 MHz, Core: 500 MHz, System: 125 MHz



In:    serial

Out:   serial

Err:   serial

Net:    ADI BF537 EMAC

I2C:   ready

Hit any key to stop autoboot:  0

Using MAC Address 00:E0:22:FE:41:AB                                           

TFTP from server; our IP address is                  

Filename 'linux'.                                                             

Load address: 0x1000000                                                       

Loading: #################################################################    



Bytes transferred = 8958561 (88b261 hex)                                      

Loading .text @ 0x00001000 (1084400 bytes)                                    

Loading .rodata @ 0x00109bf0 (266936 bytes)                                   

Loading .init.rodata @ 0x0014aea8 (128 bytes)                                 

Loading __ksymtab @ 0x0014af28 (15832 bytes)                                  

Loading __ksymtab_gpl @ 0x0014ed00 (5064 bytes)                               

Loading __ksymtab_strings @ 0x001500c8 (46757 bytes)                          

Loading __init_rodata @ 0x0015b770 (316 bytes)                                

Loading __param @ 0x0015b8ac (380 bytes)                                      

Clearing .bss @ 0x0015c000 (71664 bytes)                                      

Loading .data @ 0x0016d7f0 (67600 bytes)                                      

Loading .init.text @ 0x0017e000 (102308 bytes)                                

Loading .init.data @ 0x00196fa4 (13684 bytes)                                 

Loading .init.setup @ 0x0019a518 (632 bytes)                                  

Loading .initcall.init @ 0x0019a790 (560 bytes)                               

Loading .con_initcall.init @ 0x0019a9c0 (4 bytes)                             

Loading .init.ramfs @ 0x0019a9c4 (6728704 bytes)                              

Loading .text_l1 @ 0xffa00000 (11564 bytes)                                   

sh_addr: FFA00000, p_paddr: 008055C4                                          

Loading from: 017F5000 to 008055C4, size: 11564                               

Loading .data_l1 @ 0xff800000 (192 bytes)                                     

sh_addr: FF800000, p_paddr: 008082F0                                          

Loading from: 017F8000 to 008082F0, size: 192                                 

## Starting application at 0x0018c888 ...                                     

console [ttyBF0] enabled, bootconsole disabled                                

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)                 

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)                  

Memory available: 48544k/65536k RAM, (6700k init code, 1058k kernel code, 466k )

Calibrating delay loop... 995.32 BogoMIPS (lpj=1990656)                       

Security Framework initialized                                                

Mount-cache hash table entries: 512                                           

Blackfin Scratchpad data SRAM: 4 KB                                           

Blackfin L1 Data A SRAM: 16 KB (15 KB free)                                   

Blackfin L1 Data B SRAM: 16 KB (16 KB free)                                   

Blackfin L1 Instruction SRAM: 48 KB (36 KB free)                              

net_namespace: 484 bytes                                                      

NET: Registered protocol family 16                                            

Blackfin DMA Controller                                                       

stamp_init(): registering device resources                                    

NET: Registered protocol family 2                                             

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)                

TCP established hash table entries: 2048 (order: 2, 16384 bytes)              

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)                      

TCP: Hash tables configured (established 2048 bind 2048)                      

TCP reno registered                                                           

NET: Registered protocol family 1                                             

msgmni has been set to 94                                                     

io scheduler noop registered                                                  

io scheduler anticipatory registered (default)                                

io scheduler cfq registered                                                   

simple-gpio: now handling 48 GPIOs: 0 - 47                                    

Serial: Blackfin serial driver                                                

bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART              

brd: module loaded                                                            

bfin_mii_bus: probed                                                          

bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc)

bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1        

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_7

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0                      

bfin-wdt: initialized: timeout=20 sec (nowayout=0)                            

TCP cubic registered                                                          

Initializing XFRM netlink socket                                              

NET: Registered protocol family 17                                            

rtc-bfin rtc-bfin: setting system clock to 1970-01-01 00:12:23 UTC (743)      

IP-Config: Complete:                                                          

     device=eth0, addr=, mask=, gw=,       

     host=BF537, domain=, nis-domain=(none),                                  

     bootserver=, rootserver=, rootpath=              

Freeing unused kernel memory: 6700k freed                                     

dma_alloc_init: dma_page @ 0x00806000 - 256 pages at 0x03f00000               


        a8888b.           / Welcome to the uClinux distribution \             

       d888888b.         /       _     _                         \            

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |           

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |           

       8'    .88       \        | |   | |  _ \| | | | \  /        |           

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |           

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |           

     dP   .    Y8b.       \   For embedded processors including   |           

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /            

   d8"         'Y88b        \___________________________________/             

  :8P    '      :888                                                          

   8a.   :     _a88P         For further information, check out:              

._/"Yaa_:   .| 88P|            -   blackfin.uclinux.org/                

\    YP"    `| 8P  `.          -   docs.blackfin.uclinux.org/           

/     \.___.d|    .'           -   www.uclinux.org/                     

`--..__)8888P`._.'  jgs/a:f    -   www.analog.com/blackfin              


Have a lot of fun...                                                          



BusyBox v1.13.4 (2010-05-07 06:32:27 PDT) built-in shell (msh)                

Enter 'help' for P HiYt:o  0u:l0-1n c-m aLdi.n                                


                                                oits/  Up - 100/Full




2010-07-01 11:17:35     Re: same kernel produces different baudrates on different boards


Message: 90809   




Booting elf images is not supported - use the uImage.






2010-07-06 10:49:55     Re: same kernel produces different baudrates on different boards

Samuel Jaißle (GERMANY)

Message: 90964   


Ok, I wonderd what you mean by "not supportet" because I had adoptet that from my predecessor and it was always used the elf image. So I looked for it and found the hint in the docs. Thanks for the tip, Robin, I wouldn't have realised that.


When I tried the the uImage.initramfs, it stopped at


starting kernel at 0018c88


without any reaction or error message, earlyprintk didn't give any further information. But now, as I updatet u-boot from 2005R3 to 2009R1.1-RC1 everything works fine. So it was just a misconfigured u-boot. The baud rate problem was probably caused by a wrong bootpargs parameter, but I'll see that on the other boards.


Thanks to Mike, too.






2010-07-06 17:25:08     Re: same kernel produces different baudrates on different boards


Message: 90974   




Glad things are working - if you ever get a non-output board again, have a look at: