Ardupilot开源飞控工程项目编译回顾

05-14 阅读 0评论

Ardupilot开源飞控工程项目编译回顾

  • 1. 源由
  • 2. 工程编译
  • 3. 命令列表
    • 3.1 工作环境设置
    • 3.2 获取工程代码
    • 3.3 建立编译环境
    • 3.4 编译工程代码
    • 3.5 保存编译结果
    • 3.6 清理编译结果
    • 3.7 编译设备目标
    • 4. 补充

      1. 源由

      最近,有点莫名的连续遇到了2次Ardupilot编译报错。百思不得其解,特地记录下,以便后续不要犯类似的毛病。

      Ardupilot开源飞控工程项目编译回顾,Ardupilot开源飞控工程项目编译回顾,词库加载错误:未能找到文件“C:\Users\Administrator\Desktop\火车头9.8破解版\Configuration\Dict_Stopwords.txt”。,使用,命令,开源,第1张
      (图片来源网络,侵删)

      问题/现象这里不重复了,请看链接: Build error compiling 4.5.1 Copter with F405 (4.4.x) target #26785

      2. 工程编译

      正常工作编译,大家可以参考:

      • 【1】ArduPilot飞控AOCODARC-H7DUAL固件编译

        好处:中文

        坏处:无法与官方项目同步

        • 【2】ArduPilot - Building the code

          好处:最新同步文档

          坏处:英语不习惯的人,。。。。不多说,反正永远也不会习惯。。。。

          Ardupilot开源飞控工程项目编译回顾,Ardupilot开源飞控工程项目编译回顾,词库加载错误:未能找到文件“C:\Users\Administrator\Desktop\火车头9.8破解版\Configuration\Dict_Stopwords.txt”。,使用,命令,开源,第2张
          (图片来源网络,侵删)

          3. 命令列表

          这里罗列一些日常常用的工程编译命令

          3.1 工作环境设置

          1. git代理设置
          $ git config --global "url.ssh://git@ssh.github.com:443/.insteadOf" git@github.com:
          $ git config --global http.proxy http://192.168.1.9:808
          $ git config --global https.proxy http://192.168.1.9:808
          
          1. http/https代理设置
          $ export https_proxy=http://192.168.1.9:808/
          $ export http_proxy=http://192.168.1.9:808/
          

          3.2 获取工程代码

          通常git协议容易获取代码,https不是很方便,而且开发角度使用git会更好。

          $ git clone git@github.com:ArduPilot/ardupilot.git
          

          3.3 建立编译环境

          $ cd ardupilot
          $ ./Tools/environment_install/install-prereqs-ubuntu.sh -y
          

          3.4 编译工程代码

          $ cd ardupilot
          $ ./Tools/gittools/submodule-sync.sh
          $ ./Tools/scripts/build_bootloaders.py Aocoda-RC-H743Dual
          $ ./waf configure --board Aocoda-RC-H743Dual
          $ ./waf copter
          

          3.5 保存编译结果

          $ cd ardupilot
          $ cd build
          $ rm -rf ArduCopter lib libraries modules .dep .wafpickle-linux*
          $ zip -r Aocoda-RC-H743Dua.zip Aocoda-RC-H743Dual
          

          3.6 清理编译结果

          $ ./waf clean
          

          3.7 编译设备目标

          $ ./waf copter  //多旋翼
          $ ./waf heli  //直升机
          $ ./waf antennatracker  //跟踪天线
          $ ./waf blimp  //飞艇
          $ ./waf plane  //固定翼
          $ ./waf rover  //车
          $ ./waf sub   //潜水艇
          

          4. 补充

          暂时,先到这里,如果有其他想法的朋友,可以评论区告诉我。

          Ardupilot开源飞控工程项目编译回顾,Ardupilot开源飞控工程项目编译回顾,词库加载错误:未能找到文件“C:\Users\Administrator\Desktop\火车头9.8破解版\Configuration\Dict_Stopwords.txt”。,使用,命令,开源,第3张
          (图片来源网络,侵删)

免责声明
本网站所收集的部分公开资料来源于AI生成和互联网,转载的目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。
文章版权声明:除非注明,否则均为主机测评原创文章,转载或复制请以超链接形式并注明出处。

发表评论

快捷回复: 表情:
评论列表 (暂无评论,人围观)

还没有评论,来说两句吧...

目录[+]