请选择 进入手机版 | 继续访问电脑版

33

阿木币

4

精华

32 小时

在线时间

技术大V

Rank: 4

发表于 2019-9-8 01:35:35 6620 浏览 5 回复

[入门教程] 不必通宵挂机,飞速克隆PX4源码的方法

本帖最后由 Bingo 于 2019-9-8 01:39 编辑

不必通宵挂机,飞速克隆PX4源码的方法

国内github网速,那是慢的没法说,克隆个PX4源码要半天,然后更新子模块,那不得需要一夜的时间,有时早上一来,刷刷的提示更新失败,那也得继续更新啊,几天都不一定能搞定。介于以上,好在我们国内也有git服务器,接下来我们可以把px4的源码fork到国内的码云上,然后打开.gitmodules文件,把其中需要clone的子模块全部fork到码云上,当然url地址也要修改成码云上的地址,工作量还是挺大的,不过我已经帮大家做好了,

直接clone如下仓库 ,仓库目前的版本支持PX4 v1.9.2及以下 当然我也会随着官网的更新而持续更新。

git clone https://gitee.com/bingobinlw/Firmware.git

然后更新子模块

git submodule update --init --recursive

如果出错的话,需要删除空白文件夹,再次更新子模块

make distclean
git submodule update --init --recursive

以上步骤就可以了,亲测有效,大概10多分钟就搞定了。

下面是我修改过的.gitmodules文件内容,供参考

[submodule "mavlink/include/mavlink/v2.0"]
        path = mavlink/include/mavlink/v2.0
        url = https://gitee.com/bingobinlw/c_library_v2.git
        branch = master
[submodule "src/drivers/uavcan/libuavcan"]
        path = src/drivers/uavcan/libuavcan
        url = https://gitee.com/bingobinlw/uavcan.git
        branch = px4
[submodule "msg/tools/genmsg"]
        path = msg/tools/genmsg
        url = https://gitee.com/bingobinlw/genmsg.git
        branch = px4
[submodule "msg/tools/gencpp"]
        path = msg/tools/gencpp
        url = https://gitee.com/bingobinlw/gencpp.git
        branch = px4
[submodule "Tools/jMAVSim"]
        path = Tools/jMAVSim
        url = https://gitee.com/bingobinlw/jMAVSim.git
        branch = master
[submodule "Tools/sitl_gazebo"]
        path = Tools/sitl_gazebo
        url = https://gitee.com/bingobinlw/sitl_gazebo.git
        branch = master
[submodule "src/lib/matrix"]
        path = src/lib/matrix
        url = https://gitee.com/bingobinlw/Matrix.git
        branch = master
[submodule "src/lib/DriverFramework"]
        path = src/lib/DriverFramework
        url = https://gitee.com/bingobinlw/DriverFramework.git
        branch = master
[submodule "src/lib/ecl"]
        path = src/lib/ecl
        url = https://gitee.com/bingobinlw/ecl.git
        branch = master
[submodule "boards/atlflight/cmake_hexagon"]
        path = boards/atlflight/cmake_hexagon
        url = https://gitee.com/bingobinlw/cmake_hexagon.git
        branch = px4
[submodule "src/drivers/gps/devices"]
        path = src/drivers/gps/devices
        url = https://gitee.com/bingobinlw/GpsDrivers.git
        branch = master
[submodule "src/modules/micrortps_bridge/micro-CDR"]
        path = src/modules/micrortps_bridge/micro-CDR
        url = https://gitee.com/bingobinlw/micro-CDR.git
        branch = px4
[submodule "platforms/nuttx/NuttX/nuttx"]
        path = platforms/nuttx/NuttX/nuttx
        url = https://gitee.com/bingobinlw/NuttX.git
        branch = px4_firmware_nuttx-7.29+
[submodule "platforms/nuttx/NuttX/apps"]
        path = platforms/nuttx/NuttX/apps
        url = https://gitee.com/bingobinlw/NuttX-apps.git
        branch = px4_firmware_nuttx-7.29+
[submodule "cmake/configs/uavcan_board_ident"]
        path = cmake/configs/uavcan_board_ident
        url = https://gitee.com/bingobinlw/uavcan_board_ident.git
        branch = master

扫一扫浏览分享
回复

使用道具 举报

45

阿木币

1

精华

2320 小时

在线时间

管理员

Rank: 9Rank: 9Rank: 9

发表于 2019-9-8 18:42:19
你行不行啊~~~~ 不发就不发  一发这么多存货
回复 点赞

使用道具 举报

176

阿木币

0

精华

349 小时

在线时间

版主

Rank: 7Rank: 7Rank: 7

发表于 2019-9-8 18:48:04
欢迎大家测试并提供反馈~~~
回复 点赞

使用道具 举报

3

阿木币

0

精华

1 小时

在线时间

应届白菜

Rank: 1

发表于 2019-9-9 09:19:25
支持,感谢分享
回复 点赞

使用道具 举报

3

阿木币

0

精华

0 小时

在线时间

应届白菜

Rank: 1

发表于 2019-9-13 21:42:26 来自手机
謝謝
回复 点赞

使用道具 举报

xiaobai 该用户已被删除
发表于 2019-9-30 19:46:31
提示: 作者被禁止或删除 内容自动屏蔽
回复 点赞

使用道具 举报

返回列表
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

快速回复 返回顶部 返回列表