在 Raspberry Pi 上开发

使用Qt Edu for Developers软件包,您还可以为以 Raspberry Pi 为目标硬件的嵌入式设备进行开发。只需在现有的 Qt 安装中添加Qt Board Support Package(QBSP),并在 Raspberry Pi 使用的 SD 卡上闪存一个 Boot to Qt系统映像。

注意: 支持 Windows 和 Linux 作为开发主机,但不支持 macOS。

首先,在继续之前完成Qt Edu for Developers 的安装步骤。

1.下载 QBSP

登录你的Qt 账户。转到Downloads 部分,从Product 字段的下拉菜单中选择Qt for Device Creation QBSP for the EDU license

为您的开发主机(Windows 或 Linux)下载正确版本的.qbsp文件。

2.运行维护工具

进入 Qt XML 的安装文件夹,运行MaintenanceTool

维护工具允许您修改现有的 Qt 安装。导航至Custom installation 并选择Next

选择Browse QBSP files 。在文件对话窗口中,定位并选择您从 Qt 账户下载的.qbsp 文件。

之后,可用组件列表会更新。在 Boot to Qt Software Stack下,选择Raspberry Pi ,然后选择Next 。这将为 Raspberry Pi 安装Boot to Qt 系统映像和工具链。

3.打开Qt Creator

要完成设置,需要将Boot to Qt 系统映像闪存到用作 Raspberry Pi 启动盘的 SD 卡上。此外,还需要对Qt Creator 进行配置,以便使用有线或无线网络连接连接到运行Boot to Qt 软件栈的设备。

这些步骤在Qt Creator 中执行,详情请参阅Qt Creator: 连接Boot to Qt 设备

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.