WhyCan Forum(哇酷开发者社区)

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn

您尚未登录。

#1 2020-08-13 21:54:15

明月照我沟渠
会员
注册时间: 2020-07-09
累计积分: 99

感谢 @aodzip @达克罗德, 我的小智X3开发板u-boot ums运行成功, TF卡和eMMC都能模拟成U盘挂载到电脑.

QQ截图20200813215048.png

这是把eMMC (mmc1)通过 ums 1 mmc 1 命令挂载成U盘



u-boot 2020.v07 开启:
CONFIG_USB_FUNCTION_MASS_STORAGE=y

即可.






Widora TINY200 R2 体验版开源开发包,修复了大部分F1C100s/F1C200s的遗留问题
http://whycan.cn/t_5061.html#p51862
(出处:哇酷开发者社区【全志 V3S/F1C100s/X3】)

求助:A33主线uboot跑起来了,但是无法从 eMMC 启动
http://whycan.cn/t_3633.html#p32970
(出处:哇酷开发者社区【全志 V3S/F1C100s/X3】)

离线

#2 2020-08-13 22:31:31

明月照我沟渠
会员
注册时间: 2020-07-09
累计积分: 99

Re: 感谢 @aodzip @达克罗德, 我的小智X3开发板u-boot ums运行成功, TF卡和eMMC都能模拟成U盘挂载到电脑.

不过, X3 eMMC 启动 u-boot 还没解决

离线

#3 2020-08-13 22:49:08

明月照我沟渠
会员
注册时间: 2020-07-09
累计积分: 99

Re: 感谢 @aodzip @达克罗德, 我的小智X3开发板u-boot ums运行成功, TF卡和eMMC都能模拟成U盘挂载到电脑.

=> mmc dev 0
switch to partitions #0, OK
mmc0 is current device
=>
=> mmc dev 1
switch to partitions #0, OK
mmc1(part 0) is current device
=>
=> mmc info
Device: mmc@1c11000
Manufacturer ID: 15
OEM: 100
Name: 8GTF4
Bus Speed: 52000000
Mode: MMC High Speed (52MHz)
Rd Block Len: 512
MMC version 5.1
High Capacity: Yes
Capacity: 7.3 GiB
Bus Width: 4-bit
Erase Group Size: 512 KiB
HC WP Group Size: 8 MiB
User Capacity: 7.3 GiB WRREL
Boot Capacity: 4 MiB ENH
RPMB Capacity: 512 KiB ENH
Boot area 0 is not write protected
Boot area 1 is not write protected
=>

X3 u-boot 切换 TF/eMMC正常

https://linux-sunxi.org/Bootable_eMMC

离线

#4 2020-08-13 23:29:52

达克罗德
会员
注册时间: 2018-04-10
累计积分: 957

Re: 感谢 @aodzip @达克罗德, 我的小智X3开发板u-boot ums运行成功, TF卡和eMMC都能模拟成U盘挂载到电脑.

感谢分享!

离线

#5 2020-09-28 16:55:24

qianfan
会员
注册时间: 2019-11-29
累计积分: 9

Re: 感谢 @aodzip @达克罗德, 我的小智X3开发板u-boot ums运行成功, TF卡和eMMC都能模拟成U盘挂载到电脑.

我用的R40, 在添加UMS的时候, 编译出错: 请问这个是需要udc的驱动吗?

```
cmd/built-in.o: In function `do_usb_mass_storage':
/home/qianfan/debug/port/github-os/u-boot/cmd/usb_mass_storage.c:218: undefined reference to `usb_gadget_handle_interrupts'
drivers/usb/gadget/built-in.o: In function `usb_composite_register':
/home/qianfan/debug/port/github-os/u-boot/drivers/usb/gadget/composite.c:1171: undefined reference to `usb_gadget_register_driver'
drivers/usb/gadget/built-in.o: In function `usb_composite_unregister':
/home/qianfan/debug/port/github-os/u-boot/drivers/usb/gadget/composite.c:1189: undefined reference to `usb_gadget_unregister_driver'
drivers/usb/gadget/built-in.o: In function `sleep_thread':
/home/qianfan/debug/port/github-os/u-boot/drivers/usb/gadget/f_mass_storage.c:682: undefined reference to `usb_gadget_handle_interrupts'
arm-linux-gnueabihf-ld.bfd: BFD (Linaro_Binutils-2017.02) 2.27.0.20161019 assertion fail /home/tcwg-buildslave/workspace/tcwg-make-release/label/docker-trusty-amd64-tcwg-build/target/arm-linux-gnueabihf/snapshots/binutils-gdb.git~linaro_binutils-2_27-branch/bfd/elf32-arm.c:8784
arm-linux-gnueabihf-ld.bfd: BFD (Linaro_Binutils-2017.02) 2.27.0.20161019 assertion fail /home/tcwg-buildslave/workspace/tcwg-make-release/label/docker-trusty-amd64-tcwg-build/target/arm-linux-gnueabihf/snapshots/binutils-gdb.git~linaro_binutils-2_27-branch/bfd/elf32-arm.c:8784
arm-linux-gnueabihf-ld.bfd: BFD (Linaro_Binutils-2017.02) 2.27.0.20161019 assertion fail /home/tcwg-buildslave/workspace/tcwg-make-release/label/docker-trusty-amd64-tcwg-build/target/arm-linux-gnueabihf/snapshots/binutils-gdb.git~linaro_binutils-2_27-branch/bfd/elf32-arm.c:8784
Makefile:1753: recipe for target 'u-boot' failed
make: *** [u-boot] Error 1
➜  u-boot git:(master) ✗ grep -nr usb_gadget_register_driver
include/linux/usb/gadget.h:861: * usb_gadget_register_driver - register a gadget driver
include/linux/usb/gadget.h:871:int usb_gadget_register_driver(struct usb_gadget_driver *driver);
drivers/usb/musb-new/musb_uboot.c:388:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
drivers/usb/gadget/pxa25x_udc.c:1903:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
drivers/usb/gadget/ci_udc.c:1010:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
drivers/usb/gadget/composite.c:1171:    res = usb_gadget_register_driver(&composite_driver);
drivers/usb/gadget/dwc2_udc_otg.c:243:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
Binary file drivers/usb/gadget/built-in.o matches
drivers/usb/gadget/fotg210.c:914:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
Binary file drivers/usb/gadget/g_dnl.o matches
drivers/usb/gadget/atmel_usba_udc.c:1209:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
drivers/usb/gadget/udc/udc-core.c:348:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
drivers/usb/gadget/udc/udc-core.c:352:EXPORT_SYMBOL_GPL(usb_gadget_register_driver);
drivers/usb/gadget/ether.c:2384:        if (usb_gadget_register_driver(&priv->eth_driver) < 0)
drivers/usb/gadget/at91_udc.c:1439:int usb_gadget_register_driver(struct usb_gadget_driver *driver)
➜  u-boot git:(master) ✗ cat drivers/usb/gadget/udc/Makefile
# SPDX-License-Identifier: GPL-2.0+
#
# USB peripheral controller drivers

ifndef CONFIG_$(SPL_)DM_USB_GADGET
obj-$(CONFIG_USB_DWC3_GADGET)   += udc-core.o
endif

obj-$(CONFIG_$(SPL_)DM_USB_GADGET)      += udc-core.o
obj-$(CONFIG_$(SPL_)DM) += udc-uclass.o
➜  u-boot git:(master) ✗
```

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB