2009-01-06 08:50:43     usb boot

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

2009-01-06 08:50:43     usb boot

Nikolay Chokoev (IRELAND)

Message: 67474   

 

Hello,

 

 

 

At the moment I'm using u-boot to boot ucLinux using seral connection. Is it possible to use USB instead RS232 or Ethernet instead?

 

 

 

Best regards,

 

Nikolay

QuoteReplyEditDelete

 

 

2009-01-06 09:01:43     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67475   

 

latest trunk supports reading usb thumb drives with bf52x/bf54x

 

QuoteReplyEditDelete

 

 

2009-01-07 04:36:24     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67543   

 

Thanks Mike,

 

I'll take a look next days!

 

Best Regards,

 

Nikolay

QuoteReplyEditDelete

 

 

2009-01-07 06:06:55     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67547   

 

Hi Mike,

 

Could you explain me a little bit more about the usb thumb. I went trough the README and under the USB support it is described that u-boot supports usb-drives (works in host mode). Does it support RS over USB for example? What I imagine is a mode in which when the board is connected to the PC to be enumerated like virtual COM port for example, and to operate at the same way like regular serial connection, but at the usb speed.

 

Best Regards,

 

Nikolay

QuoteReplyEditDelete

 

 

2009-01-07 06:11:43     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67548   

 

u-boot supports mass storage devices.

 

i dont know what "RS over USB" is, but if you're referring to "RS-232" devices, then there might be drivers for it in the tree.  but we havent tested any of that stuff so i cant say.

QuoteReplyEditDelete

 

 

2009-01-08 09:33:59     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67625   

 

Hi Mike,

 

Yes, I'm referring RS-232. I want to use exactly the same hardware, but instead RS232 cable, to make the connection to the PC via USB. If there is any (even untested) support for that, can you point me to the sources, or any information, please.

 

Best Regards,

 

Nikolay

QuoteReplyEditDelete

 

 

2009-01-08 10:32:54     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67628   

 

no idea ... probably grep around the u-boot source tree

QuoteReplyEditDelete

 

 

2009-01-09 05:10:49     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67700   

 

I was not able to find such support for BF. Now I'm trying to rutn 'USB MassStorage' support. I've add:

 

#define CONFIG_USB_UHCI

#define CONFIG_USB_STORAGE

 

to the 'bf527-ezkit.h' and built the u-boot, but the new u-boot still seems doesn't support usb. I tried the commands from here:

 

http://blackfin.uclinux.org/gf/project/u-boot/tracker/?action=TrackerItemEdit&tracker_item_id=3545

 

What I'm missing?

QuoteReplyEditDelete

 

 

2009-01-09 05:32:18     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67704   

 

as i said, only the latest trunk is supported.  attempts to do usb with bf52x/bf54x and any other version will not work.

 

also, defining UHCI makes no sense.  the Blackfin parts have a MUSB_HCD as their controller, not a UHCI one.

QuoteReplyEditDelete

 

 

2009-01-09 06:58:19     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67709   

 

Hi Mike,

 

You are right!

 

Now, trying to build the latest trunk I have an error:

 

bfin-uclinux-objcopy -O srec u-boot u-boot.srec

bfin-uclinux-objcopy --gap-fill=0xff -O binary u-boot u-boot.bin

tools/envcrc --binary > env-ldr.o

bfin-uclinux-ldr -T bf527-0.0 -c u-boot.ldr u-boot -J --bmode PARA --use-vmas --initcode cpu/blackfin/initcode.o --punchit $((0x4000)):$((0x2000)):env-ldr.o

create: invalid option -- J

bfin-uclinux-ldr: Unknown option 'J' or argument missing

 

Backtrace:

bfin-uclinux-ldr[0x8049d7a]

bfin-uclinux-ldr[0x804a718]

bfin-uclinux-ldr[0x804ae27]

/lib/tls/libc.so.6(__libc_start_main+0xc8)[0x40043ea8]

bfin-uclinux-ldr(wait+0x35)[0x8049571]

make: *** [u-boot.ldr] Error 1

 

 

Can you advise me with this, please.

 

Best regards,

 

Nikolay

QuoteReplyEditDelete

 

 

2009-01-09 07:11:15     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67711   

 

this is a FAQ ... only svn trunk versions are tested against each other, so you would normally need a svn trunk toolchain in order to build things

 

however if you want to cheat, you can checkout just the ldr-utils subdir of our svn toolchain and build that up and replace your host bfin-uclinux-ldr util.  it should be much faster than building the whole toolchain.

QuoteReplyEditDelete

 

 

2009-01-09 07:19:58     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67713   

 

I removed '-J' option from the 'blackfin_config.mk' file and it seems to work. I was able to read from USB Flash and boot the kernel! That's fantastic! Good job!

 

Can I expect something bad removing '-J' option?

 

 

QuoteReplyEditDelete

 

 

2009-01-09 07:31:22     Re: usb boot

Mike Frysinger (UNITED STATES)

Message: 67715   

 

mmmm now that i think about it, no, it should run OK

QuoteReplyEditDelete

 

 

2009-01-09 08:52:33     Re: usb boot

Nikolay Chokoev (IRELAND)

Message: 67719   

 

Thanks! That's fine!

Attachments

    Outcomes