Navigation

    全志在线开发者论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • 在线文档
    • 社区主页

    测试 D1s的符合USB gadget设备

    MR Series
    2
    4
    2026
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      memory LV 7 last edited by memory

      基于 tina v2.0

      修改:/etc/init.d/S50usb

      在 mkdir /sys/kernel/config/usb_gadget/g1/functions/mass_storage.usb0

      后面添加:

      echo /mnt/UDISK/disk.bin > /sys/kernel/config/usb_gadget/g1/functions/mass_storage.usb0/lun.0/file

      这样电脑就能同时出现 adb 和 u盘了.

      当然得提前准备文件:
      dd if=/dev/zero of=/mnt/UDISK/disk.bin bs=1M count=4

      597c1b66-186c-47e1-a14a-7476d565169d-image.png

      记得勾上这个: CONFIG_USB_CONFIGFS_MASS_STORAGE=y

      1 Reply Last reply Reply Quote Share 0
      • M
        memory LV 7 last edited by

        tina v2.0 下载,约4G:
        链接: https://pan.baidu.com/s/1rTyKuWIwMUlBY4xLJofWEg?pwd=awol
        提取码:awol

        文件:

        tina_d1_open_v2.tar.bz2.aa 
        tina_d1_open_v2.tar.bz2.ab 
        tina_d1_open_v2.tar.bz2.ac
        

        ①解压:
        cat tina_d1_open_v2.tar.bz2.a* | tar -xjv

        ②从本地repo仓库同步SDK
        repo sync -l.

        ③ source build/envsetup.sh
        ④ lunch
        ⑤ make
        ⑥ pack

        BedRock 1 Reply Last reply Reply Quote Share 0
        • M
          memory LV 7 last edited by

          参考文章: D1_Linux_USB_开发指南.pdf

          1 Reply Last reply Reply Quote Share 0
          • BedRock
            BedRock LV 6 @memory last edited by

            @memory
            建议在repo sync 后加上
            repo start tina-2.0 --all
            为所有同步过来的仓库新建分支

            1 Reply Last reply Reply Quote Share 0
            • 1 / 1
            • First post
              Last post

            Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号

            行为准则 | 用户协议 | 隐私权政策