PlatformIO IDE在创建新项目抛出PIO Core Call Error,同时修改Monitor波特率


PIO Core Call Error: "The current working directory C:\\Users\\sscy\\Documents\\PlatformIO\\Projects\\platformled will be used for the project.\r\n\r\n
The next files/directories have been created in C:\\Users\\sscy\\Documents\\PlatformIO\\Projects\\platformled\r\n
include - Put project header files here\r\n
lib - Put here project specific (private) libraries\r\n
src - Put project source files here\r\n
platformio.ini - Project Configuration File\r\n\n\n
Error: Detected unknown package 'framework-esp8266-nonos-sdk'"

上面是抛出的错误,是因为无法找到framework-esp8266-nonos-sdk这个包。

解决方法很简单,

方法1:打开C:\Users\sscy\Documents\PlatformIO\Projects文件夹,删掉当前的项目,然后关闭vscode,重新打开创建。

方法2:打开C:\\Users\\sscy\\Documents\\PlatformIO\\Projects\\platformled文件夹,删掉.pio文件夹,然后关闭vscode,重新打开项目。

 

由于Montor串口监控,默认使用9600波特率进行监控,导致都是乱码,需要改成115200.

C:\Users\sscy\.platformio\penv\Lib\site-packages\serial\tools进入这个文件夹,找到miniterm.py文件,将

parser.add_argument(
"baudrate",
nargs='?',
type=int,
help="set baud rate, default: %(default)s",
default=115200)

这句话中的default值改为115200.

然后删除本目录下的miniterm.pyc文件,再次开启串口监视器时会重新编译生成此文件。


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM