How to Use edge TWRP on Edge-V

Use edge TWRP Step:

1,Please get the khadas-edge-pie SDK and setup the build environment.

2,Back up the default recovery, the directory path is bootable/recovery, so that you can restore the recovery at any time to provide the full SDK.

$mv bootable/recovery ../

3,Delete the default original recovery

$rm -rf bootable/recovery

4,cp TWRP source

$cp -rf xx/recovery_edge_TWRP bootable/recovery

5, Compilation, Clearing the previously compiled content, because the files in the out directory that have been generated conflict with TWRP, will cause TWRP compilation to fail.(make clean)
or you can restore the previously compiled content

$mv out ../

$source build/
$lunch rk3399-userdebug
$make recoveryimage -j36

6, Upgrade the compiled recovery.img separately (out/target/product/rk3399/recovery.img)

7, After upgrading, enter the system and execute the following command:
$adb reboot recovery


Thanks, I managed to build recovery.img, but is there a way to burn it separately to Edge-V?

I have packed recovery.img into update.img and burned to Edge-V, but now whenever device runs, TWRP loads (not the Android system) and it’s in Chinese :neutral_face: I can’t seem to be able to start Android…

Is there a way to have TWRP in English?

To only burn the stock recovery.img or TWRP.img recovery, you can use AndroidTool.
Only select the recovery partition and point it to the image location.
Also the last button on the bottom, it will get the partition layout from your device to get the correct location of the recovery partition, you must do this first.

For Linux flashing or TWRP in English only Khadas will be able to help.

1 Like


--- a/
+++ b/
@@ -20,7 +20,7 @@ RECOVERY_SDCARD_ON_DATA := true
 TW_THEME := landscape_hdpi

Excellent, now TWRP is built with English menu :+1:

Just one problem - when I reboot Edge-V it always boots to TWRP and from it’s menu when I choose Reboot > System or Reboot > Bootloader it says “No OS installed”. Is it so that TWRP does not recognize Android Pie?

There are two possibilities:

  1. Your system is broken
  2. You failed to install the system

So you have to think about what happened to it before

It seems that TWRP source might lack some files - I have initiated Android build having TWRP source as bootable/recovery and it gave me this:

make: Leaving directory '/home/gytis/khadas/edgev/external/rk_tee_user'
[ 11% 11742/100718] //external/one-true-awk:awk yacc awkgram.y
external/one-true-awk/awkgram.y: conflicts: 43 shift/reduce, 85 reduce/reduce
[ 11% 11752/100718] //external/one-true-awk:awk_vendor yacc awkgram.y
external/one-true-awk/awkgram.y: conflicts: 43 shift/reduce, 85 reduce/reduce
[ 13% 13324/100718] //bootable/recovery/applypatch:libapplypatch clang++ applypatch.cpp
FAILED: out/soong/.intermediates/bootable/recovery/applypatch/libapplypatch/android_arm64_armv8-a_cortex-a53_core_static/obj/bootable/recovery/applypatch/applypatch.o 
PWD=/proc/self/cwd prebuilts/clang/host/linux-x86/clang-4691093/bin/clang++ -c -Ibootable/recovery/applypatch/include -Ibootable/recovery/applypatch/include -Ibootable/recovery/applypatch  -Werror=implicit-function-declaration -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -no-canonical-prefixes -DNDEBUG -UDEBUG -fno-exceptions -Wno-multichar -O2 -g -fno-strict-aliasing -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -Wno-zero-as-null-pointer-constant -fdebug-prefix-map=$PWD/= -ffunction-sections -fdata-sections -fno-short-enums -funwind-tables -fstack-protector-strong -Wa,--noexecstack -D_FORTIFY_SOURCE=2 -Wstrict-aliasing=2 -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Werror=date-time -Werror=format-security -nostdlibinc -march=armv8-a -mcpu=cortex-a53 -Isystem/core/base/include -Iexternal/bsdiff/include -Iexternal/bzip2 -Iexternal/boringssl/src/include -Ibootable/recovery/edify/include -Ibootable/recovery/otafault/include -Ibootable/recovery/otautil/include -Iexternal/zlib -Iexternal/libcxx/include -Iexternal/libcxxabi/include -Isystem/core/include -Isystem/media/audio/include -Ihardware/libhardware/include -Ihardware/libhardware_legacy/include -Ihardware/ril/include -Ilibnativehelper/include -Iframeworks/native/include -Iframeworks/native/opengl/include -Iframeworks/av/include -isystem bionic/libc/include -isystem bionic/libc/kernel/uapi -isystem bionic/libc/kernel/uapi/asm-arm64 -isystem bionic/libc/kernel/android/scsi -isystem bionic/libc/kernel/android/uapi -Ilibnativehelper/include_jni -D_FILE_OFFSET_BITS=64 -DZLIB_CONST -Wall -Werror -target aarch64-linux-android -Bprebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/aarch64-linux-android/bin -DANDROID_STRICT -fPIC -D_USING_LIBCXX -std=gnu++14 -Wsign-promo -Wno-inconsistent-missing-override -Wno-null-dereference -D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS -Wno-thread-safety-negative -Wno-gnu-include-next -fvisibility-inlines-hidden -fno-rtti  -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -Wno-tautological-constant-compare -Wno-null-pointer-arithmetic -Wno-enum-compare -Wno-enum-compare-switch -MD -MF out/soong/.intermediates/bootable/recovery/applypatch/libapplypatch/android_arm64_armv8-a_cortex-a53_core_static/obj/bootable/recovery/applypatch/applypatch.o.d -o out/soong/.intermediates/bootable/recovery/applypatch/libapplypatch/android_arm64_armv8-a_cortex-a53_core_static/obj/bootable/recovery/applypatch/applypatch.o bootable/recovery/applypatch/applypatch.cpp
bootable/recovery/applypatch/applypatch.cpp:41:10: fatal error: 'bmlutils/bmlutils.h' file not found
#include "bmlutils/bmlutils.h"
1 error generated.
[ 13% 13327/100718] //system/core/libappfuse:libappfuse clang++ [arm]
ninja: build stopped: subcommand failed.
14:41:09 ninja failed with: exit status 1

#### failed to build some targets (20:35 (mm:ss)) ####

I checked the uploaded code again, there is no problem.

Code is fine, TWRP builds and works on Edge V :+1: