Go to file
xunyingya 173873014c bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params
- Add PKG_USING_PNNACORE to Kconfig and drivers/SConscript recursion
- Create pnnacore/SConscript entry point
- Fix CPPPATH in pnna_drv/src/SConscript (inc, nbg_linker, pnna_hal/src)
- Update vendor_x16.h with real x16 hardware params (0x0A100000, IRQ 72)
- Clean up vendor_x16.c clock/power stubs
- Add NPU register region (0x0A100000) to board.c MMU page tables
- Fix NORMAL_NOCACHE_MEM bug in libcpu/mmu.c (MMU_MAP_K_RWCB → MMU_MAP_K_RW)
- Add missing includes and stub headers for RT-Thread port compilation
- Remove internal pnnacore planning .txt files
- Add integration docs to doc/

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-08-04 16:28:17 +08:00
applications first add 2026-07-29 10:29:55 +08:00
board bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params 2026-08-04 16:28:17 +08:00
doc bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params 2026-08-04 16:28:17 +08:00
drivers bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params 2026-08-04 16:28:17 +08:00
hal first add 2026-07-29 10:29:55 +08:00
packages first add 2026-07-29 10:29:55 +08:00
.gitignore Relocate project to D:/ws/rtt-x16, update doc paths and build config 2026-07-29 11:16:06 +08:00
Kconfig bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params 2026-08-04 16:28:17 +08:00
LICENSE Initial commit 2026-07-29 10:18:06 +08:00
README.md board: setup VBAR before MMU init to prevent silent hang; update README 2026-08-04 11:07:38 +08:00
SConscript first add 2026-07-29 10:29:55 +08:00
SConstruct Relocate project to D:/ws/rtt-x16, update doc paths and build config 2026-07-29 11:16:06 +08:00
link_ram.lds first add 2026-07-29 10:29:55 +08:00
rtconfig.h bsp: integrate pnnacore NPU driver with build config, MMU, and vendor params 2026-08-04 16:28:17 +08:00
rtconfig.py first add 2026-07-29 10:29:55 +08:00

README.md

x16 BSP — RT-Thread v5.1.0 板级支持包

本 BSP 面向 x16 板卡(单核 ARMv8-A AArch64 Cortex-A53GIC-400 中断控制器),基于 RT-Thread v5.1.0 内核,实现了系统稳定运行、线程调度及 FinSH/MSH Shell 控制台交互功能。

硬件平台

项目 规格
SoC x16 (yhft,x16)
CPU 单核 Cortex-A53 (ARMv8-A AArch64)
中断控制器 GIC-400
DDR 8 GB @ 0x80000000当前 MVP 启用 1 GB
控制台 PL011 UART0 @ 0x08070000115200 bps
OS Tick ARMv8 Generic Timer (PPI 14, GIC Vector 30)

目录结构

bsp/
├── board/          ← 板级启动编排board.c/h、MMU 页表、堆布局)
├── hal/            ← 裸机 HAL寄存器定义、零 RT-Thread 依赖)
├── drivers/        ← RT-Thread 设备驱动适配drv_uart 等)
├── applications/   ← 应用入口 + MSH 调试命令
├── packages/       ← 第三方库
├── doc/            ← 硬件映射、架构规范、移植记录
├── Kconfig / SConscript / rtconfig.py / rtconfig.h
└── link_ram.lds

BSP 严格遵循四层分离架构,各层准入条件与跨层引用约束见 doc/x16_bsp_architecture.md

快速开始

# 编译
cd bsp
"C:/Users/xunyi/AppData/Local/Programs/Python/Python313/Scripts/scons.exe" -j4

# 配置
scons --menuconfig

# GDB 调试
aarch64-none-elf-gdb rtthread-a64.elf
(gdb) target remote :2331
(gdb) load
(gdb) continue

工具链:aarch64-none-elf-gcc 15.2.1E:/8016/toolchain/bin)。 产物:rtthread-a64.elf(调试)、rtthread-a64.bin(烧录)、rtthread.map

当前状态

功能 状态
系统启动MMU + BSS 清零 + EL1 入口) 正常
多线程调度 正常
FinSH/MSH Shell键盘输入 + 命令补全 + 历史) 正常
PL011 UART0 轮询输出 / 中断接收 正常
OS Tick (Generic Timer, PPI 14, 1000 Hz) 正常
GIC-400 中断子系统 正常

文档索引

文档 用途
doc/x16_hardware_map.md 硬件真理源 — 地址映射、GIC 中断向量、PSC 时钟域、MMU 规则
doc/x16_bsp_architecture.md BSP 架构规范 — 目录准入条件、代码模板、初始化顺序、新增驱动流程
doc/x16_porting_issues.md 移植关键问题记录 — 根因分析与修复方案
doc/build_and_debug.md 编译环境、GCC 参数、GDB 调试指南

作者 {{xunyingya}}