mirror of
https://github.com/DrHo1y/orangepi-build.git
synced 2026-03-27 02:56:42 +07:00
opiaimax: install npu driver
This commit is contained in:
@@ -1885,6 +1885,22 @@ install_wiringop()
|
||||
rm $SDCARD/root/*.deb >/dev/null 2>&1
|
||||
}
|
||||
|
||||
|
||||
install_310b-npu-driver()
|
||||
{
|
||||
local driver_path="$EXTER/cache/sources/ascend-driver"
|
||||
local driver_name="Ascend-hdk-310b-npu-driver_23.0.5_linux-aarch64-opiaimax.run"
|
||||
local driver=${driver_path}/${driver_name}
|
||||
|
||||
if [[ -f "${driver}" ]]; then
|
||||
display_alert "Installing" "$driver_name" "info"
|
||||
cp "${driver}" "${SDCARD}/opt/"
|
||||
chmod +x "${SDCARD}/opt/Ascend-hdk-310b-npu-driver_23.0.5_linux-aarch64-opiaimax.run"
|
||||
chroot "${SDCARD}" /bin/bash -c "/opt/${driver_name} --chroot --full --install-username=orangepi --install-usergroup=orangepi --install-for-all"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
install_docker() {
|
||||
|
||||
[[ $install_docker != yes ]] && return
|
||||
|
||||
@@ -449,6 +449,12 @@ if [[ ${IGNORE_UPDATES} != yes ]]; then
|
||||
|
||||
fi
|
||||
|
||||
if [[ ${BOARD} =~ orangepiaimax ]]; then
|
||||
|
||||
[[ $BUILD_OPT =~ image ]] && fetch_from_repo "https://github.com/orangepi-xunlong/ascend-driver.git" "${EXTER}/cache/sources/ascend-driver" "branch:main"
|
||||
|
||||
fi
|
||||
|
||||
if [[ ${BOARD} =~ orangepi4|orangepi4-lts|orangepi800 && $RELEASE =~ focal|buster|bullseye|bookworm ]]; then
|
||||
|
||||
[[ ${BUILD_OPT} == image ]] && fetch_from_repo "https://github.com/orangepi-xunlong/rk-rootfs-build.git" "${EXTER}/cache/sources/rk-rootfs-build-${RELEASE}" "branch:rk-rootfs-build-${RELEASE}"
|
||||
|
||||
Reference in New Issue
Block a user