跳到主要内容

板端启用 NPU

提示

使用 R2 或更高版本的系统镜像时,NPU 运行环境已预装,无需额外安装。

NPU 环境配置清单

  • fastrpc
  • /dev/fastrpc-adsp
  • /dev/fastrpc-cdsp
  • /dev/fastrpc-cdsp-secure
  • /usr/lib/dsp libraries

使用 radxa apt 源进行安装

前置条件

以下软件包依赖 Radxa 官方镜像里预置的 Radxa APT 源。请先确认设备运行的是对应机型的官方 RadxaOS 镜像;如果当前使用的是第三方 Ubuntu / Debian 镜像或自行更换过软件源,fastrpc / fastrpc-test 可能无法安装。

Device
sudo apt update
sudo apt install fastrpc libcdsprpc1

验证 fastrpc 状态

Device
sudo apt install fastrpc-test
fastrpc_test -a v68
rock@radxa-dragon-q8b:~$ fastrpc_test -a v68

Allocate 4000 bytes from ION heap
Creating sequence of numbers from 0 to 999
Compute sum on domain 3

Call calculator_sum on the DSP
Sum = 499500

Call calculator_max on the DSP
Max value = 999
[PASS] libcalculator.so


Demonstrating FARF run-time logging

hap_example function PASSED
Please look at the mini-dm logs or the adb logcat logs for DSP output

Demonstrating HAP_mem.h APIs

hap_example function PASSED
Please look at the mini-dm logs or the adb logcat logs for DSP output

Demonstrating HAP_perf.h APIs

hap_example function PASSED
Please look at the mini-dm logs or the adb logcat logs for DSP output
[PASS] libhap_example.so

Test PASSED
Please look at the mini-dm logs or the adb logcat logs for DSP output
[PASS] libmultithreading.so


========================================
Test Summary:
Total tests run: 3
Passed: 3
Failed: 0
Skipped: 0
========================================

RESULT: All applicable tests PASSED

    您需要登录 GitHub 才能发表评论。如果您已登录,请忽略此消息。

    Radxa-docs © 2026 by Radxa Computer (Shenzhen) Co.,Ltd. is licensed under CC BY 4.0