PS:在编写代码之后爆红不要担心
PS:找不到串口
可能是电源线只能充电(离谱)
串口被虚拟机占用
主机缺少驱动
。。。
(参考:
CSDN博主「helwens」
No SConstruct file found._helwens的博客-CSDN博客
)
开发编译执行hpm dist遇到以下问题
Generating Third Party Open Source Notice...
Third Party Open Source Notice generated.
Building: bearpi_hm_nano
/usr/lib/scons/SCons/Defaults.py:213: SyntaxWarning: "is not" with a literal. Did you mean "!="?
if len(operation_list) is not 2:
scons: *** No SConstruct file found.
File "/usr/lib/scons/SCons/Script/Main.py", line 924, in _main
Distribution error: Failed to find the distribution bundle from bearpi_hm_nano.
Check error details by "/home/bearpi/.hpm/log/debug/debug.2021-11-20-10-54-17.log"
先说结论
这个开发板的代码(bearpi-hm_nano)代码获取方式有四种方式
从镜像站点获取的称之为code_1
我这里没有这个源码,遂弃
Code_2未有消息
hpm init -t default
hpm i @bearpi/bearpi_hm_nano
在视频中称之为code_3
这种方式才是编译
hpm dist
其中一个从git clone,在视频中称之为code_4
编译方式使用
python build.py BearPi-HM_Nano
如果用后者编译前者的代码就会抛出以上错误。
----
不过这个过程也让我知道了Python 3.8 是不支持is not这种语句只能改为 !=
另外要更新sconst,可以在/usr/lib/sconst
python -m pip install scons
进行更新