diff --git a/README.md b/README.md
index dbb7d04c469aeabaa809c81f7161af4fc5ca9082..e5b45ac8d8ad8b445426e75200e62d726ef323d0 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ Members:
- Vincent
- Arnau
- Manoj
-
+- Frank
Community:
- Ingo
@@ -37,9 +37,19 @@ Reviewer
developer:
- [Vincent Bourgmayer](vincent.bourgmayer@e.email)
+- Frank Preel
- Israel Yago pereira
## Changelogs
+### v0.14.0 (candidate)
+- Update Readme
+- Update version number to v0.14.0
+- Use of the same unit (Mb, Gb..) on the download progress bar
+- Add Android Q support for the model below
+ - star2lte
+ - starlte
+-Add emerald support
+
### v0.13.4-beta (current - unreleased)
- Fix Ubuntu build's docker image - by Israel & Omer Akram & Nicolas
- Refactor classes related to script execution
diff --git a/build.gradle b/build.gradle
index 216d5dfbca38c39c0e00d944b6e6426163ad6a25..e98557a7f3e0e022cd4a910b7fe551332016699b 100644
--- a/build.gradle
+++ b/build.gradle
@@ -147,6 +147,11 @@ tasks.jlink {
from('buildSrc/windows/heimdall')
into("${buildDir}/image/${appLauncher}-${windowsPlatform}/bin")
include 'heimdall.exe', 'libusb-1.0.dll', 'libgcc_s_seh-1.dll', 'libstdc++-6.dll', 'libwinpthread-1.dll', 'wdi-simple.exe'
+ }
+ copy {
+ from('buildSrc/windows/heimdall/Drivers')
+ into("${buildDir}/image/${appLauncher}-${windowsPlatform}/bin")
+ include 'zadig.exe'
}
copy {
from('buildSrc/windows/adb')
diff --git a/flash-scripts/linux/emerald-flashingUnlock.sh b/flash-scripts/linux/emerald-flashingUnlock.sh
new file mode 100755
index 0000000000000000000000000000000000000000..88442b5fd139b9b4d453a8805cec4d9804fcbcb8
--- /dev/null
+++ b/flash-scripts/linux/emerald-flashingUnlock.sh
@@ -0,0 +1,53 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: device id
+# $2: fastboot folder path
+
+# Exit status
+# - 0 : bootloader locked
+# - 1 : unknown error
+# - 2 : Flashing unlocked failed
+# - 101 : $DEVICE_ID missing
+# - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+DEVICE_ID=$1
+FASTBOOT_FOLDER_PATH=$2
+
+# check serial number has been provided
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+# Check fastboot parent folder path has been provided
+if [ -z "$FASTBOOT_FOLDER_PATH" ]
+then
+ exit 102
+fi
+
+# Build fastboot path
+FASTBOOT_PATH=${FASTBOOT_FOLDER_PATH}"fastboot"
+
+# Unlock bootloader
+if ! "$FASTBOOT_PATH" -s "$DEVICE_ID" flashing unlock
+then
+ exit 2
+fi
+
+sleep 1
diff --git a/flash-scripts/linux/emerald-install-from-bootloader.sh b/flash-scripts/linux/emerald-install-from-bootloader.sh
new file mode 100755
index 0000000000000000000000000000000000000000..6fd529b5db4b4164acb257ad8ba15e415ce31f79
--- /dev/null
+++ b/flash-scripts/linux/emerald-install-from-bootloader.sh
@@ -0,0 +1,120 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: DEVICE_ID device id
+# $2: ARCHIVE_PATH path to archive
+# $3: fastboot folder path
+# $4: Java folder path
+
+
+# Exit status
+# - 0 : device flashed
+# - 1 : generic error
+# - 10: can't unpack system.img
+# - 11: can't wipe userdata
+# - 11: can't wipe metadata
+# - 20-30 : see partition_name index below
+# - 101 : DEVICE_ID missing
+# - 102 : ARCHIVE_PATH missing
+# - 103 : fastboot folder path missing
+
+partition_name=(gz_a lk_a md1img_a scp_a spmfw_a sspm_a tee_a boot_a dtbo_a vbmeta_a super)
+partition_image=(gz.img lk.img md1img.img scp.img spmfw.img sspm.img tee.img boot.img dtbo.img vbmeta.img super.img)
+partition_error=(20 21 22 23 24 25 26 27 28 29 30)
+
+DEVICE_ID=$1
+ARCHIVE_PATH=$2
+FASTBOOT_FOLDER_PATH=$3
+JAVA_FOLDER_PATH=$4
+
+# Check serial number has been provided
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+# check path to rom has been provided
+if [ -z "$ARCHIVE_PATH" ]
+then
+ exit 102
+fi
+
+#check path to adb/fasboot has been provided
+if [ -z "$FASTBOOT_FOLDER_PATH" ]
+then
+ exit 103
+fi
+
+# Check java folder has been provided
+if [ -z "$JAVA_FOLDER_PATH" ]
+then
+ exit 104
+fi
+
+# Build fastboot path
+FASTBOOT_PATH=${FASTBOOT_FOLDER_PATH}"fastboot"
+
+# Build java jar path
+JAR_PATH=${JAVA_FOLDER_PATH}"/bin/jar"
+
+# Build archive folder path
+ARCHIVE_FOLDER_PATH=$(dirname "$ARCHIVE_PATH")"/"
+
+# unzip for system.img
+cd "$ARCHIVE_FOLDER_PATH" || exit 104
+
+if ! "$JAR_PATH" -x -v -f "$ARCHIVE_PATH" ;
+then
+ exit 10
+fi
+
+echo "unpacked archive"
+
+sleep 1
+
+
+# Wipe user data
+if ! "$FASTBOOT_PATH" erase userdata ;
+then
+ exit 11
+fi
+
+echo "user data wiped"
+sleep 5
+
+if ! "$FASTBOOT_PATH" erase metadata ;
+then
+ exit 12
+fi
+
+echo "meta data wiped"
+sleep 5
+
+#Flash partition
+for i in ${!partition_name[@]}; do
+ if ! "$FASTBOOT_PATH" -s "$DEVICE_ID" flash ${partition_name[$i]} ${partition_image[$i]}
+ then
+ exit ${partition_error[$i]}
+ fi
+ sleep 1
+ echo "Flased ${partition_name[$i]}"
+done
+
+
+"$FASTBOOT_PATH" --set-active=a
+
diff --git a/flash-scripts/linux/emerald-wait-reboot-from-fastboot.sh b/flash-scripts/linux/emerald-wait-reboot-from-fastboot.sh
new file mode 100755
index 0000000000000000000000000000000000000000..b11780c2b57904164de536710b39ca49c01f4b04
--- /dev/null
+++ b/flash-scripts/linux/emerald-wait-reboot-from-fastboot.sh
@@ -0,0 +1,50 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+
+# $1: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+# Exit status
+# - 0 : success
+# - 1 : unknown error
+# - 10 : fastboot reboot command failed
+# - 101 : no device found in fastboot
+
+FASTBOOT_FOLDER_PATH=$1
+FASTBOOT_PATH=${FASTBOOT_FOLDER_PATH}"fastboot"
+
+echo "fastboot path: $FASTBOOT_PATH"
+
+#check that device is in recovery mode
+if ! "$FASTBOOT_PATH" devices 2>&1 | grep "fastboot"
+then
+ echo "Device not detected in fastboot"
+ exit 101
+fi
+
+# Reboot the device
+if ! "$FASTBOOT_PATH" reboot
+then
+ exit 10
+fi
+
+#Then we wait that it left this state
+while [ "$($FASTBOOT_PATH devices | grep -q fastboot; echo $?)" = 0 ]
+do
+ sleep 1s
+done
\ No newline at end of file
diff --git a/flash-scripts/linux/install-e-recovery-boot.sh b/flash-scripts/linux/install-e-recovery-boot.sh
new file mode 100755
index 0000000000000000000000000000000000000000..1e09a9c4535c3f77b48d5bd1f394d96b5ae3eafa
--- /dev/null
+++ b/flash-scripts/linux/install-e-recovery-boot.sh
@@ -0,0 +1,64 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: FASTBOOT_PATH
+# $2: E_IMAGE_PATH need twrp path
+# Exit status
+# - 0 : Recovery installed
+# - 101 : FASTBOOT_PATH missing
+# - 102 : E_IMAGE_PATH missing
+
+#This script performs the same kind of job like `install-e-recovery` on the boot partion (rather than recovery patition)
+
+FASTBOOT_PATH=$1
+E_IMAGE_PATH=$2
+
+if [ -z "$FASTBOOT_PATH" ]
+then
+ echo "Fastboot path is empty"
+ exit 101
+fi
+
+if [ -z "$E_IMAGE_PATH" ]
+then
+ echo "E Image path is empty"
+ exit 102
+fi
+
+#"$FASTBOOT_CMD" reboot bootloader
+#sleep 10
+
+# Build fastboot and adb commands
+FASTBOOT_CMD=${FASTBOOT_PATH}"fastboot"
+ADB_CMD=${FASTBOOT_PATH}"adb"
+
+# Wipe user data
+#if ! "$FASTBOOT_CMD" erase userdata ;
+#then
+# exit 11
+#fi
+
+#echo "user data wiped"
+#sleep 1
+
+#if ! "$FASTBOOT_CMD" erase metadata ;
+#then
+# exit 12
+#fi
+
+"$FASTBOOT_CMD" flash boot ${E_IMAGE_PATH}
diff --git a/flash-scripts/linux/install-e-recovery.sh b/flash-scripts/linux/install-e-recovery.sh
new file mode 100755
index 0000000000000000000000000000000000000000..b31a2a0d141a02b9c8e1d4bc4c3529ad90eb5ab5
--- /dev/null
+++ b/flash-scripts/linux/install-e-recovery.sh
@@ -0,0 +1,62 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: FASTBOOT_PATH
+# $2: E_IMAGE_PATH need twrp path
+# Exit status
+# - 0 : Recovery installed
+# - 101 : FASTBOOT_PATH missing
+# - 102 : E_IMAGE_PATH missing
+
+FASTBOOT_PATH=$1
+E_IMAGE_PATH=$2
+
+if [ -z "$FASTBOOT_PATH" ]
+then
+ echo "Fastboot path is empty"
+ exit 101
+fi
+
+if [ -z "$E_IMAGE_PATH" ]
+then
+ echo "E Image path is empty"
+ exit 102
+fi
+
+#"$FASTBOOT_CMD" reboot bootloader
+#sleep 10
+
+# Build fastboot and adb commands
+FASTBOOT_CMD=${FASTBOOT_PATH}"fastboot"
+ADB_CMD=${FASTBOOT_PATH}"adb"
+
+# Wipe user data
+#if ! "$FASTBOOT_CMD" erase userdata ;
+#then
+# exit 11
+#fi
+
+#echo "user data wiped"
+#sleep 1
+
+#if ! "$FASTBOOT_CMD" erase metadata ;
+#then
+# exit 12
+#fi
+
+"$FASTBOOT_CMD" flash recovery ${E_IMAGE_PATH}
diff --git a/flash-scripts/linux/install-from-e-recovery.sh b/flash-scripts/linux/install-from-e-recovery.sh
new file mode 100755
index 0000000000000000000000000000000000000000..28ce53b88886cdf5d494dba1e8181b02e1fd6541
--- /dev/null
+++ b/flash-scripts/linux/install-from-e-recovery.sh
@@ -0,0 +1,65 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: DEVICE_ID device id
+# $2: ARCHIVE_PATH path to archive
+# $3: fastboot folder path
+
+
+# Exit status
+# - 0 : device flashed
+# - 1 : generic error
+
+DEVICE_ID=$1
+ARCHIVE_FILE=$2
+FASTBOOT_FOLDER_PATH=$3
+
+# Check serial number has been provided
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+# check path to rom has been provided
+if [ -z "$ARCHIVE_FILE" ]
+then
+ exit 102
+fi
+
+#check path to adb/fasboot has been provided
+if [ -z "$FASTBOOT_FOLDER_PATH" ]
+then
+ exit 103
+fi
+
+# Build fastboot and adb commands
+ADB_CMD=${FASTBOOT_FOLDER_PATH}"adb"
+
+"$ADB_CMD" sideload ${ARCHIVE_FILE}
+ret=${?}
+
+echo "adb sideload retuns = "${ret}
+# ret = 0 if adb command is fine, 1 on error
+
+if [ ${ret} -lt 2 ]
+then
+ echo "handle adb: failed to read command: Success."
+ exit 0
+fi
+
+exit ${ret}
diff --git a/flash-scripts/linux/oneplus-flashingUnlock.sh b/flash-scripts/linux/oneplus-flashingUnlock.sh
new file mode 100755
index 0000000000000000000000000000000000000000..5c08fcba66ddc7892a86f124422ba2ab3a515d39
--- /dev/null
+++ b/flash-scripts/linux/oneplus-flashingUnlock.sh
@@ -0,0 +1,68 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: device id
+# $2: fastboot folder path
+
+# Exit status
+# - 0 : bootloader locked
+# - 1 : unknown error
+# - 2 : Flashing unlocked failed
+# - 101 : $DEVICE_ID missing
+# - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+DEVICE_ID=$1
+FASTBOOT_FOLDER_PATH=$2
+
+# check serial number has been provided
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+# Check fastboot parent folder path has been provided
+if [ -z "$FASTBOOT_FOLDER_PATH" ]
+then
+ exit 102
+fi
+
+# Build fastboot path
+FASTBOOT_PATH=${FASTBOOT_FOLDER_PATH}"fastboot"
+
+if [ "$($FASTBOOT_PATH getvar unlocked 2>&1 | grep -q yes; echo $?)" = 1 ]
+then
+ # Unlock bootloader
+ if ! "$FASTBOOT_PATH" -s "$DEVICE_ID" oem unlock
+ then
+ exit 2
+ fi
+else
+ sleep 30
+ # Already unlocked use the same way
+ "$FASTBOOT_PATH" -s "$DEVICE_ID" reboot
+ exit 0
+fi
+
+while [ "$($FASTBOOT_PATH getvar unlocked 2>&1 | grep -q yes; echo $?)" = 1 ]
+do
+ echo "locked"
+ sleep 1
+done
+
+echo "unlock.."
+sleep 1
diff --git a/flash-scripts/linux/pixel-flashingUnlock.sh b/flash-scripts/linux/pixel-flashingUnlock.sh
new file mode 100755
index 0000000000000000000000000000000000000000..9bdd6d1a7f91b53f91fba30f968b86a5764f91e3
--- /dev/null
+++ b/flash-scripts/linux/pixel-flashingUnlock.sh
@@ -0,0 +1,65 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: device id
+# $2: fastboot folder path
+
+# Exit status
+# - 0 : bootloader locked
+# - 1 : unknown error
+# - 2 : Flashing unlocked failed
+# - 101 : $DEVICE_ID missing
+# - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+DEVICE_ID=$1
+FASTBOOT_FOLDER_PATH=$2
+
+# check serial number has been provided
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+# Check fastboot parent folder path has been provided
+if [ -z "$FASTBOOT_FOLDER_PATH" ]
+then
+ exit 102
+fi
+
+# Build fastboot path
+FASTBOOT_PATH=${FASTBOOT_FOLDER_PATH}"fastboot"
+
+if [ "$($FASTBOOT_PATH getvar unlocked 2>&1 | grep -q yes; echo $?)" = 1 ]
+then
+ # Unlock bootloader
+ if ! "$FASTBOOT_PATH" -s "$DEVICE_ID" flashing unlock
+ then
+ exit 2
+ fi
+else
+ exit 0
+fi
+
+while [ "$($FASTBOOT_PATH getvar unlocked 2>&1 | grep -q yes; echo $?)" = 1 ]
+do
+ echo "locked"
+ sleep 1
+done
+
+echo "unlock.."
+sleep 1
diff --git a/flash-scripts/linux/wait-download.sh b/flash-scripts/linux/wait-download.sh
index 8ff8483dd6b9005adf48e100d1d6f2dbd18f94b4..d4315ad068245859bec98dbb3c57a9014b93d951 100755
--- a/flash-scripts/linux/wait-download.sh
+++ b/flash-scripts/linux/wait-download.sh
@@ -2,6 +2,7 @@
# Copyright (C) 2019 ECORP SAS - Author: Romain Hunault
# Copyright (C) 2020 ECORP SAS - Author: Vincent Bourgmayer
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -32,8 +33,8 @@ echo "Heimdall path: $HEIMDALL_PATH"
while [ "$($HEIMDALL_PATH detect > /dev/null 2>&1; echo $?)" = 1 ]
do
- sleep 1s
+ sleep 1
done
-sleep 5s
+sleep 5
echo "Download mode detected"
\ No newline at end of file
diff --git a/flash-scripts/linux/wait-e-reboot.sh b/flash-scripts/linux/wait-e-reboot.sh
new file mode 100755
index 0000000000000000000000000000000000000000..20917988f44e3c52a71bd8d9a415c3ac9714ac8f
--- /dev/null
+++ b/flash-scripts/linux/wait-e-reboot.sh
@@ -0,0 +1,52 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Romain Hunault
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: DEVICE_ID Device we are waiting for reboot
+# $2: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+# Exit status
+# - 0 : success
+# - 1 : Error
+# - 10 : DEVICE_ID is missing
+# - 101 : device with DEVICE_ID is not detected
+
+DEVICE_ID=$1
+ADB_FOLDER_PATH=$2
+
+ADB_PATH=${ADB_FOLDER_PATH}"adb"
+
+echo "ADB path: $ADB_PATH"
+
+if [ -z "$DEVICE_ID" ]
+then
+ exit 10
+fi
+
+
+#1 On check that device is in recovery mode
+if ! "$ADB_PATH" -s "$DEVICE_ID" get-state 2>&1 | grep "recovery"
+then
+ echo "Device not detected in recovery"
+ exit 101
+fi
+
+#Then we wait that it left this state
+while "$ADB_PATH" -s "$DEVICE_ID" get-state 2> /dev/null
+do
+ sleep 1
+done
\ No newline at end of file
diff --git a/flash-scripts/linux/wait-e-recovery-sideload.sh b/flash-scripts/linux/wait-e-recovery-sideload.sh
new file mode 100755
index 0000000000000000000000000000000000000000..f0be174ec8b783dafa244386d8f70f1791b3e815
--- /dev/null
+++ b/flash-scripts/linux/wait-e-recovery-sideload.sh
@@ -0,0 +1,44 @@
+#!/bin/bash
+
+# Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
+# Parameter
+# $1: DEVICE_ID ID of the device to wait
+# $2: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+# Exit status
+# - 0 : success
+# - 101 : adb wait sideload failed
+
+DEVICE_ID=$1
+ADB_FOLDER_PATH=$2
+
+if [ -z "$DEVICE_ID" ]
+then
+ exit 101
+fi
+
+ADB_PATH=${ADB_FOLDER_PATH}"adb"
+
+echo "waiting for recovery"
+if "$ADB_PATH" -s "$DEVICE_ID" wait-for-sideload
+then
+ echo "device found in recovery"
+ exit 0
+else
+ echo "device not detected in recovery"
+ exit 101
+fi
diff --git a/flash-scripts/linux/wait-reboot.sh b/flash-scripts/linux/wait-reboot.sh
index c30eff812e9b8bdc1518a164d3b7f92b6bdb92c9..cdfbea2a3d9104877b5849df8256ba09ff1c535d 100755
--- a/flash-scripts/linux/wait-reboot.sh
+++ b/flash-scripts/linux/wait-reboot.sh
@@ -50,4 +50,4 @@ fi
while "$ADB_PATH" -s "$DEVICE_ID" get-state 2> /dev/null
do
sleep 1
-done
\ No newline at end of file
+done
diff --git a/flash-scripts/windows/emerald-flashingUnlock.bat b/flash-scripts/windows/emerald-flashingUnlock.bat
new file mode 100755
index 0000000000000000000000000000000000000000..75b2ba9f2d6f6e138ea210301ddfefc1af0d017d
--- /dev/null
+++ b/flash-scripts/windows/emerald-flashingUnlock.bat
@@ -0,0 +1,47 @@
+@echo off
+
+:: Coyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: device id
+:: $2: fastboot folder path
+
+:: Exit status
+:: - 0 : bootloader locked
+:: - 1 : unknown error
+:: - 2 : Flashing unlocked failed
+:: - 101 : $DEVICE_ID missing
+:: - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+
+SET DEVICE_ID=%~1
+SET FASTBOOT_FOLDER_PATH=%~2
+
+IF not defined %DEVICE_ID (
+ exit /b 101
+)
+IF not defined %FASTBOOT_FOLDER_PATH (
+ exit /b 102
+)
+
+SET FASTBOOT_PATH="%FASTBOOT_FOLDER_PATH%fastboot"
+%FASTBOOT_PATH% -s %DEVICE_ID% flashing unlock
+if errorlevel 1 (
+ exit /b 2
+)
+
+timeout 1 >nul 2>&1
+exit /b 0
diff --git a/flash-scripts/windows/emerald-install-from-bootloader.bat b/flash-scripts/windows/emerald-install-from-bootloader.bat
new file mode 100755
index 0000000000000000000000000000000000000000..be287ed0e9c45524a78c739a64a749cbcbae3aaf
--- /dev/null
+++ b/flash-scripts/windows/emerald-install-from-bootloader.bat
@@ -0,0 +1,131 @@
+@echo off
+
+:: Coyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: DEVICE_ID device id
+:: $2: ARCHIVE_PATH path to archive
+:: $3: fastboot folder path
+:: $4: Java folder path
+
+
+:: Exit status
+:: - 0 : device flashed
+:: - 1 : generic error
+:: - 10: can't unpack system.img
+:: - 11: can't wipe userdata
+:: - 11: can't wipe metadata
+:: - 20-30 : see partition_name index below
+:: - 101 : DEVICE_ID missing
+:: - 102 : ARCHIVE_PATH missing
+:: - 103 : fastboot folder path missing
+
+SET partition_name[0]=gz_a
+SET partition_name[1]=lk_a
+SET partition_name[2]=md1img_a
+SET partition_name[3]=scp_a
+SET partition_name[4]=spmfw_a
+SET partition_name[5]=sspm_a
+SET partition_name[6]=tee_a
+SET partition_name[7]=boot_a
+SET partition_name[8]=dtbo_a
+SET partition_name[9]=vbmeta_a
+SET partition_name[10]=super
+
+SET partition_image[0]=gz.img
+SET partition_image[1]=lk.img
+SET partition_image[2]=md1img.img
+SET partition_image[3]=scp.img
+SET partition_image[4]=spmfw.img
+SET partition_image[5]=sspm.img
+SET partition_image[6]=tee.img
+SET partition_image[7]=boot.img
+SET partition_image[8]=dtbo.img
+SET partition_image[9]=vbmeta.img
+SET partition_image[10]=super.img
+
+SET partition_error[0]=20
+SET partition_error[1]=21
+SET partition_error[2]=22
+SET partition_error[3]=23
+SET partition_error[4]=24
+SET partition_error[5]=25
+SET partition_error[6]=26
+SET partition_error[7]=27
+SET partition_error[8]=28
+SET partition_error[9]=29
+SET partition_error[10]=30
+
+SET DEVICE_ID=%~1
+SET ARCHIVE_PATH=%~2
+SET FASTBOOT_FOLDER_PATH=%~3
+SET JAVA_FOLDER_PATH=%~4
+
+IF not defined %DEVICE_ID (
+ exit /b 101
+)
+IF not defined %ARCHIVE_PATH (
+ exit /b 102
+)
+IF not defined %FASTBOOT_FOLDER_PATH (
+ exit /b 103
+)
+IF not defined %JAVA_FOLDER_PATH (
+ exit /b 104
+)
+
+:: Build fastboot path
+SET FASTBOOT_PATH="%FASTBOOT_FOLDER_PATH%fastboot"
+
+:: Build java jar path
+SET JAR_PATH="%JAVA_FOLDER_PATH%/bin/jar"
+
+:: Build archive folder path
+for %%a in ("%ARCHIVE_PATH%") do (
+ set ARCHIVE_FOLDER_PATH=%%~dpa"
+ echo %ARCHIVE_FOLDER_PATH%
+)
+
+:: unzip for system.img
+cd "%ARCHIVE_FOLDER_PATH%"
+%JAR_PATH% -x -v -f "%ARCHIVE_PATH%"
+if errorLevel 1 ( exit /b 10 )
+echo "unpacked archive"
+timeout 1 >nul 2>&1
+
+
+:: Wipe user data
+%FASTBOOT_PATH% erase userdata
+if errorLevel 1 ( exit /b 11 )
+echo "user data wiped"
+timeout 5 >nul 2>&1
+
+:: Wipe meta data
+%FASTBOOT_PATH% erase userdata
+if errorLevel 1 ( exit /b 12 )
+echo "meta data wiped"
+timeout 5 >nul 2>&1
+
+:: Flash partition
+(for /L %%i in (0,1,10) do (
+ %FASTBOOT_PATH% -s %DEVICE_ID% flash %%partition_name[%%i]%% %%partition_image[%%i]%%
+ if errorLevel 1 ( exit /b %%partition_error[%%i]%% )
+ timeout 1 >nul 2>&1
+ call echo "Flashed %%partition_name[%%i]%% "
+))
+
+%FASTBOOT_PATH% --set-active=a
+
diff --git a/flash-scripts/windows/emerald-wait-reboot-from-fastboot.bat b/flash-scripts/windows/emerald-wait-reboot-from-fastboot.bat
new file mode 100755
index 0000000000000000000000000000000000000000..d7cf1b12ff1d2e6559d8b26fe36da552489cd859
--- /dev/null
+++ b/flash-scripts/windows/emerald-wait-reboot-from-fastboot.bat
@@ -0,0 +1,55 @@
+@echo off
+
+:: Coyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+
+:: $1: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+:: Exit status
+:: - 0 : success
+:: - 1 : unknown error
+:: - 10 : fastboot reboot command failed
+:: - 101 : no device found in fastboot
+
+SET FASTBOOT_FOLDER_PATH=%~1
+SET FASTBOOT_PATH=%FASTBOOT_FOLDER_PATH%"fastboot"
+
+echo "fastboot path: %FASTBOOT_PATH%"
+
+:: check that device is in recovery mode
+%FASTBOOT_PATH% devices 2>&1 | findstr fastboot
+if %errorLevel% NEQ 0 (
+ echo "Device not detected in fastboot"
+ exit /b 101
+)
+
+:: Reboot the device
+%FASTBOOT_PATH% reboot
+if %errorlevel% NEQ 0 ( exit /b 10 )
+
+:: Then we wait that it left this state
+
+:fastboot_detect
+%FASTBOOT_PATH% devices 2>&1 | findstr fastboot
+if %errorLevel% EQU 0 (
+ ping 127.0.0.1 -n 2 -w 1000 >NUL
+ goto :fastboot_detect
+) else (exit /b 0)
+
+call :fastboot_detect
+
+exit /b 0
diff --git a/flash-scripts/windows/gs290-wait-reboot-from-fastboot.bat b/flash-scripts/windows/gs290-wait-reboot-from-fastboot.bat
index 99dc45aae218e964b4e879e656ef648b5674627e..42c4e1c66e837dab311dba59e8c44948571931f0 100755
--- a/flash-scripts/windows/gs290-wait-reboot-from-fastboot.bat
+++ b/flash-scripts/windows/gs290-wait-reboot-from-fastboot.bat
@@ -1,3 +1,5 @@
+@echo off
+
:: Copyright (C) 2021 ECORP SAS - Author: Vincent Bourgmayer
::
:: This program is free software: you can redistribute it and/or modify
diff --git a/flash-scripts/windows/install-e-recovery-boot.bat b/flash-scripts/windows/install-e-recovery-boot.bat
new file mode 100644
index 0000000000000000000000000000000000000000..1965aa4ef311662ec8390052cf38e63e4c1388e5
--- /dev/null
+++ b/flash-scripts/windows/install-e-recovery-boot.bat
@@ -0,0 +1,55 @@
+@echo off
+
+:: !/bin/bash
+
+:: Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: FASTBOOT_PATH
+:: $2: E_IMAGE_PATH need twrp path
+:: Exit status
+:: - 0 : Recovery installed
+:: - 101 : FASTBOOT_PATH missing
+:: - 102 : E_IMAGE_PATH missing
+
+SET FASTBOOT_PATH=%~1
+SET E_IMAGE_PATH=%~2
+
+IF not defined %FASTBOOT_PATH (
+ echo "Fastboot path is empty"
+ exit /b 101
+)
+
+IF not defined %E_IMAGE_PATH (
+ echo "E Image path is empty"
+ exit /b 102
+)
+SET FASTBOOT_CMD="%FASTBOOT_PATH%fastboot"
+SET ADB_CMD="%FASTBOOT_PATH%adb"
+
+:: %FASTBOOT_CMD% erase userdata
+:: if errorlevel 1 (
+:: exit /b 11
+:: )
+
+:: timeout 1 >nul 2>&1
+
+:: %FASTBOOT_CMD% erase metadata
+:: if errorlevel 1 (
+:: exit /b 12
+:: )
+
+%FASTBOOT_CMD% flash boot %E_IMAGE_PATH%
diff --git a/flash-scripts/windows/install-e-recovery.bat b/flash-scripts/windows/install-e-recovery.bat
new file mode 100644
index 0000000000000000000000000000000000000000..9fac9a3ccf14243c7996b8ef1ee36d66201e141f
--- /dev/null
+++ b/flash-scripts/windows/install-e-recovery.bat
@@ -0,0 +1,55 @@
+@echo off
+
+:: !/bin/bash
+
+:: Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: FASTBOOT_PATH
+:: $2: E_IMAGE_PATH need twrp path
+:: Exit status
+:: - 0 : Recovery installed
+:: - 101 : FASTBOOT_PATH missing
+:: - 102 : E_IMAGE_PATH missing
+
+SET FASTBOOT_PATH=%~1
+SET E_IMAGE_PATH=%~2
+
+IF not defined %FASTBOOT_PATH (
+ echo "Fastboot path is empty"
+ exit /b 101
+)
+
+IF not defined %E_IMAGE_PATH (
+ echo "E Image path is empty"
+ exit /b 102
+)
+SET FASTBOOT_CMD="%FASTBOOT_PATH%fastboot"
+SET ADB_CMD="%FASTBOOT_PATH%adb"
+
+:: %FASTBOOT_CMD% erase userdata
+:: if errorlevel 1 (
+:: exit /b 11
+:: )
+
+:: timeout 1 >nul 2>&1
+
+:: %FASTBOOT_CMD% erase metadata
+:: if errorlevel 1 (
+:: exit /b 12
+:: )
+
+%FASTBOOT_CMD% flash recovery %E_IMAGE_PATH%
diff --git a/flash-scripts/windows/install-from-e-recovery.bat b/flash-scripts/windows/install-from-e-recovery.bat
new file mode 100644
index 0000000000000000000000000000000000000000..cc87ba302448245f94648b29586334732659b1e9
--- /dev/null
+++ b/flash-scripts/windows/install-from-e-recovery.bat
@@ -0,0 +1,53 @@
+@echo off
+
+:: Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: DEVICE_ID device id
+:: $2: ARCHIVE_PATH path to archive
+:: $3: fastboot folder path
+
+
+:: Exit status
+:: - 0 : device flashed
+:: - 1 : generic error
+
+SET DEVICE_ID=%~1
+SET ARCHIVE_FILE=%~2
+SET FASTBOOT_FOLDER_PATH=%~3
+
+::IF "-z" "%DEVICE_ID%" (
+:: exit "101"
+::)
+::IF "-z" "%ARCHIVE_FILE%" (
+:: exit "102"
+::)
+::IF "-z" "%FASTBOOT_FOLDER_PATH%" (
+:: exit "103"
+::)
+
+SET ADB_CMD="%FASTBOOT_FOLDER_PATH%adb"
+"%ADB_CMD%" "sideload" "%ARCHIVE_FILE%"
+if errorlevel==0 (
+ echo "Sideload OK"
+ exit /b 0
+)
+if errorlevel==1 (
+ echo "Sideload OK"
+ exit /b 0
+)
+echo "Sideload fails"
+exit /b 1
diff --git a/flash-scripts/windows/oneplus-flashingUnlock.bat b/flash-scripts/windows/oneplus-flashingUnlock.bat
new file mode 100644
index 0000000000000000000000000000000000000000..f1e327ef77417991abce86f3a349f53ca040538a
--- /dev/null
+++ b/flash-scripts/windows/oneplus-flashingUnlock.bat
@@ -0,0 +1,64 @@
+@echo off
+
+:: Coyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: device id
+:: $2: fastboot folder path
+
+:: Exit status
+:: - 0 : bootloader locked
+:: - 1 : unknown error
+:: - 2 : Flashing unlocked failed
+:: - 101 : $DEVICE_ID missing
+:: - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+
+SET DEVICE_ID=%~1
+SET FASTBOOT_FOLDER_PATH=%~2
+
+IF not defined %DEVICE_ID (
+ exit /b 101
+)
+IF not defined %FASTBOOT_FOLDER_PATH (
+ exit /b 102
+)
+
+SET FASTBOOT_PATH="%FASTBOOT_FOLDER_PATH%fastboot"
+
+%FASTBOOT_PATH% getvar unlocked 2>&1 | findstr "yes"
+if errorlevel 0 (
+ echo "The device is unlocked"
+ %FASTBOOT_PATH% -s %DEVICE_ID% reboot
+ timeout 30 >nul 2>&1
+ exit /b 0
+) else (
+ echo "The device is locked"
+ %FASTBOOT_PATH% -s %DEVICE_ID% oem unlock
+ if errorlevel 1 ( exit /b 2)
+)
+
+:fastboot_detect
+%FASTBOOT_PATH% getvar unlocked 2>&1 | findstr "yes"
+if errorLevel 1 (
+ echo "..."
+ timeout 2 >nul 2>&1
+ goto :fastboot_detect
+)
+
+call fastboot_detect
+
+exit /b 0
diff --git a/flash-scripts/windows/pixel-flashingUnlock.bat b/flash-scripts/windows/pixel-flashingUnlock.bat
new file mode 100644
index 0000000000000000000000000000000000000000..cf1a04eff376c9abee4f4980db492c2901e27366
--- /dev/null
+++ b/flash-scripts/windows/pixel-flashingUnlock.bat
@@ -0,0 +1,63 @@
+@echo off
+
+:: Coyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: device id
+:: $2: fastboot folder path
+
+:: Exit status
+:: - 0 : bootloader locked
+:: - 1 : unknown error
+:: - 2 : Flashing unlocked failed
+:: - 101 : $DEVICE_ID missing
+:: - 102 : $FASTBOOT_FOLDER_PATH is missing
+
+
+SET DEVICE_ID=%~1
+SET FASTBOOT_FOLDER_PATH=%~2
+
+IF not defined %DEVICE_ID (
+ exit /b 101
+)
+IF not defined %FASTBOOT_FOLDER_PATH (
+ exit /b 102
+)
+
+SET FASTBOOT_PATH="%FASTBOOT_FOLDER_PATH%fastboot"
+
+%FASTBOOT_PATH% getvar unlocked 2>&1 | findstr "yes"
+if errorlevel 0 (
+ echo "The device is unlocked"
+ timeout 1 >nul 2>&1
+ exit /b 0
+) else (
+ echo "The device is locked"
+ %FASTBOOT_PATH% -s %DEVICE_ID% flashing unlock
+ if errorlevel 1 ( exit /b 2)
+)
+
+:fastboot_detect
+%FASTBOOT_PATH% getvar unlocked 2>&1 | findstr "yes"
+if errorLevel 1 (
+ echo "..."
+ timeout 2 >nul 2>&1
+ goto :fastboot_detect
+)
+
+call fastboot_detect
+
+exit /b 0
diff --git a/flash-scripts/windows/reboot-fastboot.bat b/flash-scripts/windows/reboot-fastboot.bat
index b425fac789796339d3ffda71e1912a9bc73bca7c..d2175397ce8e2a82aec296ba680ca647ead5b643 100755
--- a/flash-scripts/windows/reboot-fastboot.bat
+++ b/flash-scripts/windows/reboot-fastboot.bat
@@ -1,3 +1,5 @@
+@echo off
+
:: Copyright (C) 2021 ECORP SAS - Author: Vincent Bourgmayer
::
:: This program is free software: you can redistribute it and/or modify
diff --git a/flash-scripts/windows/wait-e-reboot.bat b/flash-scripts/windows/wait-e-reboot.bat
new file mode 100644
index 0000000000000000000000000000000000000000..eddccb41c01cd333cd77b0d0cd2be653817e5ed9
--- /dev/null
+++ b/flash-scripts/windows/wait-e-reboot.bat
@@ -0,0 +1,40 @@
+@echo off
+
+:: Copyright (C) 2022 ECORP SAS - Author: Romain Hunault
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: DEVICE_ID Device we are waiting for reboot
+:: $2: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+:: Exit status
+:: - 0 : success
+:: - 1 : Error
+:: - 10 : DEVICE_ID is missing
+:: - 101 : device with DEVICE_ID is not detected
+
+
+SET DEVICE_ID=%~1
+SET ADB_FOLDER_PATH=%~2
+SET ADB_PATH="%ADB_FOLDER_PATH% adb"
+echo "ADB path: %ADB_PATH%"
+::IF "-z" "%DEVICE_ID%" (
+:: exit "10"
+::)
+::IF REM UNKNOWN: {"type":"Pipeline","commands":[{"type":"Command","name":{"text":"!","type":"Word"},"suffix":[{"text":"\"$ADB_PATH\"","expansion":[{"loc":{"start":1,"end":9},"parameter":"ADB_PATH","type":"ParameterExpansion"}],"type":"Word"},{"text":"-s","type":"Word"},{"text":"\"$DEVICE_ID\"","expansion":[{"loc":{"start":1,"end":10},"parameter":"DEVICE_ID","type":"ParameterExpansion"}],"type":"Word"},{"text":"get-state","type":"Word"},{"type":"Redirect","op":{"text":">&","type":"greatand"},"file":{"text":"1","type":"Word"},"numberIo":{"text":"2","type":"io_number"}}]},{"type":"Command","name":{"text":"grep","type":"Word"},"suffix":[{"text":"recovery","type":"Word"}]}]} (
+:: echo "Device not detected in recovery"
+:: exit "101"
+::)
+::REM UNKNOWN: {"type":"While","clause":{"type":"CompoundList","commands":[{"type":"Command","name":{"text":"\"$ADB_PATH\"","expansion":[{"loc":{"start":1,"end":9},"parameter":"ADB_PATH","type":"ParameterExpansion"}],"type":"Word"},"suffix":[{"text":"-s","type":"Word"},{"text":"\"$DEVICE_ID\"","expansion":[{"loc":{"start":1,"end":10},"parameter":"DEVICE_ID","type":"ParameterExpansion"}],"type":"Word"},{"text":"get-state","type":"Word"},{"type":"Redirect","op":{"text":">","type":"great"},"file":{"text":"/dev/null","type":"Word"},"numberIo":{"text":"2","type":"io_number"}}]}]},"do":{"type":"CompoundList","commands":[{"type":"Command","name":{"text":"sleep","type":"Word"},"suffix":[{"text":"1","type":"Word"}]}]}}
\ No newline at end of file
diff --git a/flash-scripts/windows/wait-e-recovery-sideload.bat b/flash-scripts/windows/wait-e-recovery-sideload.bat
new file mode 100644
index 0000000000000000000000000000000000000000..668fc8f206139d006310429bb764915581d06c5b
--- /dev/null
+++ b/flash-scripts/windows/wait-e-recovery-sideload.bat
@@ -0,0 +1,41 @@
+@echo off
+
+:: Copyright (C) 2022 ECORP SAS - Author: Frank Preel
+
+:: This program is free software: you can redistribute it and/or modify
+:: it under the terms of the GNU General Public License as published by
+:: the Free Software Foundation, either version 3 of the License, or
+:: (at your option) any later version.
+
+:: This program is distributed in the hope that it will be useful,
+:: but WITHOUT ANY WARRANTY; without even the implied warranty of
+:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+:: GNU General Public License for more details.
+
+:: You should have received a copy of the GNU General Public License
+:: along with this program. If not, see .
+
+:: Parameter
+:: $1: DEVICE_ID ID of the device to wait
+:: $2: ADB_FOLDER_PATH: the path where runnable adb is stored
+
+:: Exit status
+:: - 0 : success
+:: - 101 : adb wait sideload failed
+
+SET DEVICE_ID=%~1
+SET ADB_FOLDER_PATH=%~2
+
+SET ADB_PATH="%ADB_FOLDER_PATH%adb"
+echo "waiting for recovery"
+
+echo %ADB_PATH% -s %DEVICE_ID% wait-for-sideload
+
+%ADB_PATH% -s %DEVICE_ID% wait-for-sideload
+if not errorlevel 1 (
+ echo "device found in recovery"
+ exit /b 0
+) ELSE (
+ echo "device not detected in recovery"
+ exit /b 101
+)
diff --git a/pkg/arch/PKGBUILD b/pkg/arch/PKGBUILD
index a05adab7e6467b3fda00baf8fb56057bc6bb0318..5dfae96a2b0ce271778296eabbaee8a8bec83215 100644
--- a/pkg/arch/PKGBUILD
+++ b/pkg/arch/PKGBUILD
@@ -1,7 +1,7 @@
# Maintainer: efoundation
# Maintainer: steadfasterX
pkgname=easy-installer
-pkgver=0.13.4
+pkgver=0.14.0
pkgrel=1
pkgdesc="The Easy Installer is a desktop application which helps users install Android /e/ (https://doc.e.foundation/what-s-e) on supported devices."
arch=('x86_64')
diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
index 7629ce799eca0f68113fc6c0dd80e7c32c85fae8..bf716906f1d451606a65cc452e73a12b7e443b08 100644
--- a/snap/snapcraft.yaml
+++ b/snap/snapcraft.yaml
@@ -1,5 +1,5 @@
name: easy-installer
-version: 'v0.13.4-beta'
+version: 'v0.14.0'
summary: Easy installation of /e/ OS - the Google-free Android-based mobile OS
description: |
The /e/ OS Installer has been created to make the installation of
diff --git a/src/main/java/ecorp/easy/installer/AppConstants.java b/src/main/java/ecorp/easy/installer/AppConstants.java
index 2929c0d905b3a25aae2cce829e55c4c6537911fd..6f7afe4edadd49b5c3bc7f3ce664467cfcf7ea35 100644
--- a/src/main/java/ecorp/easy/installer/AppConstants.java
+++ b/src/main/java/ecorp/easy/installer/AppConstants.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2021 - ECORP SAS
+ * Copyright 2019-2022 - ECORP SAS
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -23,10 +23,11 @@ import java.nio.file.Paths;
* @TODO make all final static field with uppercase or lowcase but not a mix of both
* @author Vincent Bourgmayer
* @author Omer Akram
+ * @author Frank Preel
*/
public abstract class AppConstants {
- public final static String APP_VERSION = "v0.13.4-beta";
+ public final static String APP_VERSION = "v0.14.0";
public final static String Separator = FileSystems.getDefault().getSeparator();
public final static String OsName = System.getProperty("os.name");
public final static String JavaHome = System.getProperty("java.home");
@@ -51,7 +52,24 @@ public abstract class AppConstants {
private static String TWRP_IMAGE_PATH;
private static String E_ARCHIVE_PATH;
private static String DEVICE_MODEL;
-
+ private static String PATCH_PATH;
+
+ /**
+ * Get the path of patch
+ * @return can return null if not already setted
+ */
+ public static String getPatchPath() {
+ return PATCH_PATH;
+ }
+
+ /**
+ * Define the path to access patch to flash
+ * @param eImagePath
+ */
+ public static void setPatchPath(String patchPath) {
+ PATCH_PATH = patchPath;
+ }
+
/**
* This methods set the model of the device
* @todo remove this
@@ -174,10 +192,14 @@ public abstract class AppConstants {
* @return
*/
public static String getRootPath(){
- if(System.getProperty("IDE", null) != null)
- return Paths.get("").toAbsolutePath().toString()+Separator;
- else
- return JavaHome+Separator+"bin"+Separator;
+ String rootPath = JavaHome+Separator+"bin"+Separator;
+ if(System.getProperty("IDE", null) != null) {
+ rootPath = Paths.get("").toAbsolutePath().toString()+Separator;
+ }
+ if (rootPath.indexOf(" ")>0){ //K1ZFP set quote to full path
+ rootPath = "\"" + rootPath + "\"";
+ }
+ return rootPath;
}
/**
@@ -228,4 +250,4 @@ public abstract class AppConstants {
public static boolean isWindowsOs(){
return OsName.toLowerCase().contains("win");
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/EasyInstaller.java b/src/main/java/ecorp/easy/installer/EasyInstaller.java
index c7cd361e447c6bea883124e04e81cf0888659160..e6b48705609dcaa9ad499970222a9a47d37dc7cd 100644
--- a/src/main/java/ecorp/easy/installer/EasyInstaller.java
+++ b/src/main/java/ecorp/easy/installer/EasyInstaller.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 - ECORP SAS
+ * Copyright 2019-2022 - ECORP SAS
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -18,24 +18,30 @@ package ecorp.easy.installer;
import static ecorp.easy.installer.AppConstants.JavaHome;
import static ecorp.easy.installer.AppConstants.OsName;
-import ecorp.easy.installer.controllers.MainWindowController;
+
+import java.net.URL;
import java.nio.file.Paths;
import java.util.Locale;
import java.util.ResourceBundle;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import ecorp.easy.installer.controllers.MainWindowController;
import javafx.application.Application;
-import static javafx.application.Application.launch;
import javafx.fxml.FXMLLoader;
+import javafx.fxml.Initializable;
import javafx.scene.Parent;
import javafx.scene.Scene;
+import javafx.scene.control.MenuBar;
+import javafx.scene.control.MenuItem;
import javafx.scene.text.Font;
import javafx.stage.Screen;
import javafx.stage.Stage;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
/**
* this is the entry point of the software
- * @author Vincent Bourgmayer
+ * @authors Vincent Bourgmayer, Frank Preel
*/
public class EasyInstaller extends Application {
private final static Logger logger = LoggerFactory.getLogger(EasyInstaller.class);
@@ -50,7 +56,8 @@ public class EasyInstaller extends Application {
*/
@Override
public void start(Stage stage) throws Exception {
- logger.debug("\nOS name = {}\nJava Home = {}\nCurrent working dir = {}\nADB folder path = {}", OsName, JavaHome, Paths.get("").toAbsolutePath().toString(), AppConstants.getADBFolderPath());
+
+ logger.debug("\nOS name = {}\nJava Home = {}\nCurrent working dir = {}\nADB folder path = {}", OsName, JavaHome, Paths.get("").toAbsolutePath().toString(), AppConstants.getADBFolderPath());
Locale currentLocale= Locale.getDefault();
i18n = ResourceBundle.getBundle("lang.translation", currentLocale);
@@ -58,14 +65,39 @@ public class EasyInstaller extends Application {
logger.debug("language = {}, country = {} ", currentLocale.getLanguage(), currentLocale.getCountry());
//Load main view
- FXMLLoader loader = new FXMLLoader(getClass().getResource(FXML_PATH+"mainWindow.fxml"));
+ URL r = getClass().getResource(FXML_PATH+"mainWindow.fxml");
+ FXMLLoader loader = new FXMLLoader(r);
loader.setResources(i18n);
Parent root = loader.load() ;
controller = loader.getController();
+
+
//Defines some properties
Scene scene = new Scene(root);
+
stage.setTitle(i18n.getString("appTitle")+AppConstants.APP_VERSION);
+
+
+
+
+
+ /*
+ try {
+ MenuBar mb = (MenuBar) root.getChildrenUnmodifiable().get(1);
+ if( System.getProperty("os.name","UNKNOWN").equals("Mac OS X")) {
+ logger.debug("Detected Mac OS.");
+ mb.setUseSystemMenuBar(true);
+
+
+
+ } else {
+ mb.setVisible(false);
+ }
+ } catch (Exception e) {
+ logger.debug("Error - cannot find menu bar");
+ }*/
+
stage.setScene(scene);
stage.setResizable(true);
@@ -104,4 +136,4 @@ public class EasyInstaller extends Application {
// Save file
controller.onStop();
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DeviceDetectedController.java b/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DeviceDetectedController.java
index 916cb4c7fc9d0f6e7bcc907f3e44c1eedf11d799..dd237064df409f30953ed50764f7d2aad916e205 100644
--- a/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DeviceDetectedController.java
+++ b/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DeviceDetectedController.java
@@ -106,11 +106,20 @@ public class DeviceDetectedController extends AbstractSubController{
return;
}
- if("Teracube_2e".equals(phone.getAdbDevice()) || "2e".equals(phone.getAdbDevice())){
+ if("2e".equals(phone.getAdbDevice())){
displayIncompatibleDeviceFound(phone.getAdbModel());
return;
}
+ if("emerald".equals(phone.getAdbDevice()) ||
+ "Teracube_2e".equals(phone.getAdbDevice()) ){
+ final String serial = phone.getSerialNo();
+ if ( ! serial.startsWith("202111") ) {
+ displayIncompatibleDeviceFound(phone.getAdbModel());
+ return;
+ }
+ }
+
//If device is unauthorized
if(!phone.isAdbAuthorized()){
displayUnauthorizedDeviceFound();
@@ -223,4 +232,4 @@ public class DeviceDetectedController extends AbstractSubController{
logger.debug("goToShop()");
parentController.openUrlInBrowser("https://esolutions.shop/");
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DownloadSrcController.java b/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DownloadSrcController.java
index 0196865d2338211593833058701b683b7fd58a9c..a8ed2fc46ad62e33c1d7001a35d9da2dc3a5e374 100644
--- a/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DownloadSrcController.java
+++ b/src/main/java/ecorp/easy/installer/controllers/subcontrollers/DownloadSrcController.java
@@ -141,6 +141,7 @@ public class DownloadSrcController extends AbstractSubController {
String sourcesFolderPath = AppConstants.getSourcesFolderPath();
CommandExecutionTask.updateCommonParam("TWRP_IMAGE_PATH", sourcesFolderPath+AppConstants.getTwrpImgPath());
CommandExecutionTask.updateCommonParam("ARCHIVE_PATH", sourcesFolderPath+AppConstants.getEArchivePath());
+ CommandExecutionTask.updateCommonParam("PATCH_PATH", sourcesFolderPath+AppConstants.getPatchPath());
parentController.disableNextButton(false);
}
@@ -208,4 +209,4 @@ public class DownloadSrcController extends AbstractSubController {
super.failed(); //no sure of its use.
}
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/helpers/DeviceHelper.java b/src/main/java/ecorp/easy/installer/helpers/DeviceHelper.java
index 52193b9df873eb4632b7f24cb70bdb98fe5dc010..a84e61aac988422fc2f2480982074964417017ed 100644
--- a/src/main/java/ecorp/easy/installer/helpers/DeviceHelper.java
+++ b/src/main/java/ecorp/easy/installer/helpers/DeviceHelper.java
@@ -50,6 +50,10 @@ public class DeviceHelper {
put("FP3", "0008");
put("GS290", "0009");
put("Teracube_2e", "0011");
+ put("emerald", "0012"); //Teracube A10
+ put("OnePlus7T", "0013");
+ put("OnePlus8", "0014");
+ put("sunfish", "0015");
}};
/**
@@ -121,4 +125,4 @@ public class DeviceHelper {
return flashingProcess;
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/tasks/CommandExecutionTask.java b/src/main/java/ecorp/easy/installer/tasks/CommandExecutionTask.java
index 992b26834f5177fabc5743ae75c78154333916d4..5c0671fed3bbbff8612cfe857794de052429c336 100644
--- a/src/main/java/ecorp/easy/installer/tasks/CommandExecutionTask.java
+++ b/src/main/java/ecorp/easy/installer/tasks/CommandExecutionTask.java
@@ -23,7 +23,10 @@ import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
+import java.util.ArrayList;
+import java.util.Arrays;
import java.util.HashMap;
+import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import javafx.concurrent.Task;
@@ -151,7 +154,7 @@ public class CommandExecutionTask extends Task {
* @return ProcessBuilder instance containing the full command to run
*/
protected ProcessBuilder getProcessBuilder(){
- final ProcessBuilder pb = new ProcessBuilder(getFullCmd().split(" "));
+ final ProcessBuilder pb = new ProcessBuilder(getFullCmd());
pb.redirectErrorStream(true);
return pb;
}
@@ -161,34 +164,47 @@ public class CommandExecutionTask extends Task {
* the full command to be run
* @return String the full command
*/
- protected String getFullCmd(){
- final StringBuilder sb = new StringBuilder();
+ private final String[] getFullCmd(){
+ ArrayList rtn = new ArrayList(10);
// Prepare base of the command
String cmdBase = command.getCommandBase();
+ final StringBuilder _cmdBase = new StringBuilder();
if(AppConstants.isWindowsOs()){
- cmdBase = "cmd.exe /c \"\""+cmdBase+"\"";
- }
- sb.append(cmdBase);
+ rtn.add("cmd.exe");
+ rtn.add("/c");
+ _cmdBase.append("\"");
+ _cmdBase.append("\"");
+ _cmdBase.append(cmdBase.replaceAll("\"", ""));
+ _cmdBase.append("\"");
+ //rtn.add("\""+_cmdBase+"\"");
+ } else
+ rtn.add(cmdBase);
updateParameters();
//Add the parameters
- if(command.getParameters() != null && !command.getParameters().isEmpty()){
- command.getParameters().values().forEach((param) -> {
- if(AppConstants.isWindowsOs()){
- param = "\""+param+"\"";
- }
- sb.append(" ").append(param);
+ final Map parameters = command.getParameters();
+ if(parameters != null && !parameters.isEmpty()){
+ parameters.values().forEach((param) -> {
+ if(AppConstants.isWindowsOs()){
+ _cmdBase.append(" \"");
+ _cmdBase.append(param.replaceAll("\"", ""));
+ _cmdBase.append("\"");
+ } else {
+ rtn.add(param);
+ }
+
});
}
// Close the full command
if(AppConstants.isWindowsOs()){
- sb.append("\"");
+ _cmdBase.append("\"");
+ rtn.add(_cmdBase.toString());
}
- logger.debug("getFullCmd(), full command = {}", sb.toString());
- return sb.toString();
+ logger.debug("getFullCmd(), full command = {}", rtn.toString());
+ return Arrays.copyOf(rtn.toArray(), rtn.size(), String[].class);
}
diff --git a/src/main/java/ecorp/easy/installer/tasks/DeviceDetectionTask.java b/src/main/java/ecorp/easy/installer/tasks/DeviceDetectionTask.java
index 0226c61e1c68a17b464151856f6db308f6c9a4a5..f6d7583b844b63407ee04f41f9232fa6a283d267 100644
--- a/src/main/java/ecorp/easy/installer/tasks/DeviceDetectionTask.java
+++ b/src/main/java/ecorp/easy/installer/tasks/DeviceDetectionTask.java
@@ -146,7 +146,7 @@ public class DeviceDetectionTask extends Task{
}else if(stringPart.contains("device:")){
logger.debug(" \"device\" keyword has been found");
String device = stringPart.substring("device:".length() );
- if(device.equals("2e")) device ="Teracube_2e";
+ if(device.equals("Teracube_2e")) device ="emerald";
//if(device.equals("k63v2_64_bsp")) device="GS290"; //bad idea. Device not really compatible.
result.setAdbDevice(device);
}
@@ -156,4 +156,4 @@ public class DeviceDetectionTask extends Task{
}
return result;
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/ecorp/easy/installer/tasks/DownloadTask.java b/src/main/java/ecorp/easy/installer/tasks/DownloadTask.java
index eaa4a5e822967fd3327e30765a0a4986b3a89827..235dc2f1e215ccbebf3051056940614922995fdb 100644
--- a/src/main/java/ecorp/easy/installer/tasks/DownloadTask.java
+++ b/src/main/java/ecorp/easy/installer/tasks/DownloadTask.java
@@ -56,16 +56,25 @@ public class DownloadTask extends Task{
/**
* Constant size
*/
- private static final long[] CST_SIZE = {1024, 1024*1024, 1024*1024*1024, 1024*1024*1024*1024};
+ private static final long[] CST_SIZE = {1, 1024, 1024*1024, 1024*1024*1024, 1024*1024*1024*1024};
/**
* Constants units
*/
- private static final String[] CST_UNITS = {"KB", "MB", "GB", "TB"};
+ private static final String[] CST_UNITS = {"B", "KB", "MB", "GB", "TB"};
+
+
+ private static final DecimalFormat[] CST_FORMAT = {
+ new DecimalFormat("#0"),
+ new DecimalFormat("##0"),
+ new DecimalFormat("#,##0"),
+ new DecimalFormat("#,##0.00"),
+ new DecimalFormat("#,##0.000")
+ };
final private ResourceBundle i18n;
final private String targetUrl;
final private String fileName;
-
+
/**
* COnstruction of the download task
* @param targetUrl the web path to the resource
@@ -219,9 +228,10 @@ public class DownloadTask extends Task{
logger.debug("full file size = {}", fullFileSize);
//Update UI
- final String formattedFileSize = formatFileSize(fullFileSize); //used for UI
+ final int unitIndex = getDownloadUnit(fullFileSize);
+ final String formattedFileSize = formatFileSize(fullFileSize, unitIndex); //used for UI
updateProgress(-1, fullFileSize);
- updateMessage(formatFileSize(previouslyDownloadedAmount)+" / "+formattedFileSize );
+ updateMessage(formatFileSize(previouslyDownloadedAmount, unitIndex)+" / "+formattedFileSize );
boolean downloaded = false;
@@ -236,13 +246,14 @@ public class DownloadTask extends Task{
timeoutThread.start();
long downloadAmount = previouslyDownloadedAmount;
+
while ( rbc.isOpen() && !isCancelled() && ! downloaded ){
final long precedentAmount = downloadAmount;
- downloadAmount += fos.getChannel().transferFrom(rbc,downloadAmount,1 << 18);
+ downloadAmount += fos.getChannel().transferFrom(rbc,downloadAmount,1 << 20); //~1MB
if(precedentAmount == downloadAmount){ //it means nothing had been downloaded
- logger.warn("precedent amount = downloaded amount");
+ logger.warn("precedent amount = downloaded amount");
downloaded = false;
rbc.close();
connect.disconnect();
@@ -250,7 +261,7 @@ public class DownloadTask extends Task{
timeoutRunnable.amountIncreased(); //delay the timeout
updateProgress(downloadAmount, fullFileSize);
- updateMessage( formatFileSize(downloadAmount)+" / "+formattedFileSize);
+ updateMessage( formatFileSize(downloadAmount, unitIndex)+" / "+formattedFileSize);
fos.flush();
downloaded = (downloadAmount == fullFileSize);
@@ -265,20 +276,30 @@ public class DownloadTask extends Task{
}
/**
- * Format file size to use correct size name (mb, gb, ...)
- * @todo definitively should be in the UI
- * @param value the file size formatted witht the good size category
- * @return
+ * Get the download file unit index (mb, gb, ...) (1,2...)
+ * @param value the file size
+ * @return the index
*/
- public String formatFileSize(final double value){
- double size;
- for (int i = 0; i < 3; i++) {
+ private final int getDownloadUnit(final double value){
+ double size = 0;
+ for (int i = 0; i < CST_SIZE.length; i++) {
size=value/CST_SIZE[i];
if (size <= 1024) {
- return new DecimalFormat("#,##0.#").format(size) + " " + CST_UNITS[i] ;
- }
+ return i;
+ }
}
- return null;
+ return -1;
+ }
+
+ /**
+ * Format file size to use correct size name (mb, gb, ...)
+ * @todo definitively should be in the UI
+ * @param value the file size
+ * @param unitIndex info about unit
+ * @return
+ */
+ private final String formatFileSize(final double value, final int unitIndex){
+ return CST_FORMAT[unitIndex].format(value/CST_SIZE[unitIndex]) + " " + CST_UNITS[unitIndex] ;
}
diff --git a/src/main/java/ecorp/easy/installer/utils/ConfigParser.java b/src/main/java/ecorp/easy/installer/utils/ConfigParser.java
index 0f05b1b807382d8201a8b370e53ed8d464d855c1..d7f7f4be74d4e51536b669a7c61e3728f88783d8 100644
--- a/src/main/java/ecorp/easy/installer/utils/ConfigParser.java
+++ b/src/main/java/ecorp/easy/installer/utils/ConfigParser.java
@@ -248,9 +248,12 @@ public class ConfigParser {
if(key.equals("twrp")){
AppConstants.setTwrpImgPath((String) source.get("filePath"));
}
+ if(key.equals("patch")){
+ AppConstants.setPatchPath((String) source.get("filePath"));
+ }
logger.debug("--> url: {}, filePath: {}", source.get("url"), source.get("filePath"));
result.put((String) source.get("url"), (String) source.get("filePath"));
}
return result;
}
-}
\ No newline at end of file
+}
diff --git a/src/main/resources/instructions/imageName.properties b/src/main/resources/instructions/imageName.properties
index f1f30beded0e4f8ca65a586a33095d669a061cec..290853573d5006cddc1548dd59ad2f25f5c08577 100644
--- a/src/main/resources/instructions/imageName.properties
+++ b/src/main/resources/instructions/imageName.properties
@@ -33,4 +33,12 @@ install_instr_swipeForOk=TWRP_toEXT3_swipe.png
install_instr_backX2=TWRP_tapback.png
install_instr_resizeFs=TWRP_resizeFS.png
#install_instr_tapRebootSystem
-install_instr_doNotInstall=TWRP_doNotInstall.png
\ No newline at end of file
+install_instr_doNotInstall=TWRP_doNotInstall.png
+install_instr_startRec_pressPowerBixbyVolUp_e_reco=galaxyS9_Recovery_mode_400px.png
+install_instr_e_recovery_factory_reset=install_instr_e_recovery_factory_reset.png
+install_instr_e_recovery_factory_reset_format_data=install_instr_e_recovery_factory_reset_format_data.png
+install_instr_e_recovery_factory_reset_format_data_validate=install_instr_e_recovery_factory_reset_format_data_validate.png
+install_instr_e_recovery_back=install_instr_e_recovery_back.png
+install_instr_e_recovery_apply_update=install_instr_e_recovery_apply_update.png
+install_instr_e_recovery_apply_update_from_adb=install_instr_e_recovery_apply_update_from_adb.png
+install_instr_e_recovery_reboot=install_instr_e_recovery_reboot.png
\ No newline at end of file
diff --git a/src/main/resources/lang/translation.properties b/src/main/resources/lang/translation.properties
index bef4c3ad0589ffe0ad9e3740d3d376421a06e8a8..6c3e36d878fee18212ebd5101f8f80834c4a95b0 100644
--- a/src/main/resources/lang/translation.properties
+++ b/src/main/resources/lang/translation.properties
@@ -53,8 +53,10 @@ connect_lbl_2=We will automatically detect your phone to install /e/OS. Automati
connect_lbl_3=In the next stages, we will help you activate 'Developer mode' if you haven't done it so far.
#devMode & debugADB
+devMode_mTitle_main=Enable the Developer mode
devMode_mTitle=Enable the Developer mode (Part 1)
devMode_lbl=Please follow these steps:
+devMode_main= Your phone has just been unlocked, it has restarted
devMode_instr_settings=Open the 'Settings' menu
devMode_instr_build=Type 'Build' in the search bar
devMode_instr_tap7=Tap 7 times on 'Build number'
@@ -121,6 +123,7 @@ install_instr_readAllWarning=Read all instructions before to start
install_instr_followOfficialGuidanceAt=Follow official guidance at
install_instr_selectUnlockBootloader=Select "UNLOCK BOOTLOADER" with "Volume" button
install_instr_unlockBootloader=Confirm with "Power" button. After that the phone will reboot automatically
+install_instr_unlockBootloader_already=If your phone is already unlocked, you don't have to do anything. The phone will then restart automatically
install_instr_selectLockBootloader=Select "LOCK BOOTLOADER" with "Volume" button
install_instr_lockBootloader=Confirm with "Power" button. After that the phone will reboot automatically
install_instr_bootWarning= On the boot warning screen, you have 5 seconds to press "Volume Down", to enter options menu.
@@ -170,6 +173,7 @@ install_instr_enableOEMUnlock=enable 'OEM unlock'
install_instr_acceptFactoryReset= You'll have to keep pressing "Power" & "Bixby" & "Volume Down" until you reach "Download mode" once your device is off. When you're ready, accept Factory Reset.
install_instr_startDl_pressPowerBixbyVolDown= Keep pressing simultaneously "Power" & "Bixby" & "Volume Down" until a blue screen appear to access Download Mode
install_instr_startRec_pressPowerBixbyVolUp= Keep pressing simultaneously "Power" & "Bixby" & "Volume Up" until 'teamwin' screen appears
+install_instr_startRec_pressPowerBixbyVolUp_e_reco= Keep pressing simultaneously "Power" & "Bixby" & "Volume Up" until 'E Revovery' screen appears
install_instr_leaveDl_pressPowerBixbyVolDown= Keep pressing simultaneously "Power" & "Bixby" & "Volume Down" until device turns off
install_instr_update_stockrom= Update your device to the latest version
install_instr_connectTowifi= Connect your device to Wi-fi
@@ -184,8 +188,26 @@ install_instr_waitInstallStartAuto = Please wait, installation will start automa
install_instr_onceDeviceRebootThenContinue = Your device will reboot automatically. Once it's done, you can click on continue
install_instr_rebootingOnBootloader=Your device will reboot automatically on bootloader mode
install_instr_pressVolUpToAcceptOEMUnlocking = Press "Volume up" to accept OEM unlocking
+install_instr_pressVolDownToAcceptOEMUnlocking = Press "Volume down" to accept OEM unlocking
+install_instr_selectOEMUnlockingMenu = Accept OEM unlocking by using the phone keys (refer to the instructions on the screen of the phone)
+
install_instr_unlockingOem= Easy-installer is unlocking OEM
install_instr_waitFastbootmodeDetected = The next step will start automatically once your device in fastboot mode will be detected. If it takes longer than 30 seconds, please check our FAQ by clicking on the "Need help" button
+install_instr_choose_e_recovery_select= On the device by using Up or Down volume keys, select "Recovery Mode" option.
+install_instr_choose_e_recovery_select_details= The selection is made by using the volume keys of the phone.
+install_instr_choose_e_recovery_validate= Validate with Power
+install_instr_choose_e_recovery_validate_wait_for_result= After a while the device will reboot in recovery mode.
+install_instr_e_recovery_apply_update= Select "Apply update"
+install_instr_e_recovery_apply_update_from_adb= Select "Apply update from ADB"
+install_instr_e_recovery_apply_update_from_adb_wait_for_result= The installation is in progress, be patient
+install_instr_e_recovery_factory_reset= Select "Factory reset"
+install_instr_e_recovery_factory_reset_format_data= Select "Format data/factory reset"
+install_instr_e_recovery_factory_reset_cache= Select "Format cache partiton"
+install_instr_e_recovery_factory_reset_system= Select "Format system partiton"
+install_instr_e_recovery_factory_reset_format_data_validate= Accept the warning by selecting "Format data"
+install_instr_e_recovery_factory_reset_validate= Accept the warning by selecting "Yes"
+install_instr_e_recovery_back= Select "Back", on the top left corner
+install_instr_e_recovery_reboot= Select "Reboot system now"
install_instr_openSettingsThenDevOptions = Open "Settings" then "Developer options"
install_instr_disableAutoUpdateSystem= Disable "Auto update system"
@@ -209,6 +231,7 @@ script_error_installRecovery_101=Can't install TWRP
script_error_waitRecovery_1 = Can't mount the "system" folder
script_error_waitRecovery_101 = No device's serial number provided
script_error_waitRecovery_102 = Error while waiting for device to start in recovery
+script_error_waitSideload_101 = Error while waiting for device to start in sideload
script_error_installFromRecovery_1 = Can't process the installation
script_error_installFromRecovery_2 = Can't push the required file on the device
script_error_installFromRecovery_3 = An error happened during the installation
@@ -219,6 +242,7 @@ script_error_installFromFastboot_2 = Flashing of one partition failed
script_error_installFromFastboot_3 = Could not lock the bootloader
script_error_installFromFastboot_101 = No /e/ install archive provided
script_error_installFromFastboot_102 = Could not unpack /e/ install archive
+script_error_installFromSideload = Could not install /e/ from eRecovery
script_error_waitReboot_10 = No device's serial number provided
script_error_waitReboot_101 = Can't run instruction on the device
script_error_waitRebootFromFastboot_101 = Can't run instruction on the device
@@ -249,11 +273,25 @@ script_error_cantFlashVBmeta_vendor=Failed to flash vb Meta vendor partition
script_error_cantFlashSystem=Failed to flash system partition
script_error_cantFlashproduct=Failed to flash product partition
script_error_cantFlashVendor=Failed to flash vendor partition
+script_error_cantFlashGz_a=Failed to flash gz_a partition
+script_error_cantFlashLk_a=Failed to flash lk_a partition
+script_error_cantFlashScp_a=Failed to flash scp_a partiton
+script_error_cantFlashMd1img_a=Failed to flash md1img_a partition
+script_error_cantFlashSpmfw_a =Failed to flash spmfw_a partition
+script_error_cantFlashSspm_a =Failed to flash sspm_a partition
+script_error_cantFlashTee_a =Failed to flash tee_a partition
+script_error_cantFlashBoot_a =Failed to flash boot_a partition
+script_error_cantFlashDtbo_a =Failed to flash dtbo_a partition
+script_error_cantFlashVbmeta_a =Failed to flash vbmeta_a partition
+script_error_cantFlashSuper =Failed to flash super partition
script_error_cantrebootFromFasboot= Failed to reboot from fastboot
script_error_cantRebootToFastboot=Failed to reboot into fastboot mode
java_error_unknow= The installation encounter an internal error
flash_process_cancelled=The installation process has been cancelled
+#oneplus
+install_instr_e_recovery_oneplus_copy_partition= Partition installation
+
#eAccount
eAccount_mTitle=Create your e.email account
eAccount_lbl_incitation=Your e.email account is at the center of the /e/OS ecosystem.
@@ -327,3 +365,4 @@ stepTitle_enableOemUnlock= Enable OEM unlocking
stepTitle_beforeInstallation= Before installation
stepTitle_rebootDevice= Reboot device
stepTitle_rebootBootloader = Rebooting in bootloader mode
+stepTitle_installation = Factory reset and installation
diff --git a/src/main/resources/lang/translation_de.properties b/src/main/resources/lang/translation_de.properties
index a52faeaa58a97a4c31ed512783a3d226443b13f6..f9b52762240ebeb354a51481f9cf93ea91170dcf 100644
--- a/src/main/resources/lang/translation_de.properties
+++ b/src/main/resources/lang/translation_de.properties
@@ -249,7 +249,7 @@ stepTitle_beforeInstallation=Vor der Installation
stepTitle_enableOemUnlock="OEM-Entsperrung" aktivieren
stepTitle_installOS=/e/-Installation
stepTitle_resizeDataPartition=Größe der Datenpartition ändern
-all_lbl_tryAgain=Nochmal versuchen
+all_lbl_tryAgain=Versuche es nochmals
# new translation
askAccount_string={{mustardpepper}}
detect_lbl_redisplayAllowUsbDebugingMsg=Wenn du keine solche Nachricht siehst: stecke dein Gerät aus und wieder ein\nDie Nachricht wird wieder erscheinen
@@ -296,15 +296,3 @@ script_error_cantFlashBoot=Fehler beim Flashen der Boot-Partition
script_error_cantWipeData=Fehler beim Löschen der Daten
script_error_cantUnpackSources=Fehler beim Entpacker der /e/-Quellen
script_error_cantRebootBootloader=Fehler beim Starten (booten) in den Bootloader
-script_error_cantFlashLogo=Das Flashen der Logo-Partition ist fehlgeschlagen
-script_error_cantFlashMd1img=Das Flashen der md1img-Partition ist fehlgeschlagen
-script_error_cantFlashSpmfw=Das Flashen der spmfw-Partition ist fehlgeschlagen
-script_error_cantFlashLk=Das Flashen der lk-Partition ist fehlgeschlagen
-script_error_cantFlashLk2=Das Flashen der lk2-Partition ist fehlgeschlagen
-script_error_cantFlashSspm_2=Das Flashen der sspm_2-Partition ist fehlgeschlagen
-script_error_cantFlashTee1=Das Flashen der tee1-Partition ist fehlgeschlagen
-script_error_cantFlashTee2=Das Flashen der tee2-Partition ist fehlgeschlagen
-script_error_cantFlashDtbo=Das Flashen der dtbo-Partition ist fehlgeschlagen
-script_error_cantFlashMd1dsp=Das Flashen der md1dsp-Partition ist fehlgeschlagen
-script_error_cantFlashSspm_1=Das Flashen der sspm_1-Partition ist fehlgeschlagen
-script_error_cantFlashPreloader=Das Flashen der Preloader-Partition ist fehlgeschlagen
diff --git a/src/main/resources/lang/translation_fr_FR.properties b/src/main/resources/lang/translation_fr_FR.properties
index e6285bc0fd599c5db21aa0c33d45da636b24e23a..59d2ed34f19ae8a0aecf260d30cd0b9afa6578aa 100644
--- a/src/main/resources/lang/translation_fr_FR.properties
+++ b/src/main/resources/lang/translation_fr_FR.properties
@@ -281,6 +281,9 @@ script_error_fastboot_flashingUnlock_failed=Impossible de déverouiller le flash
script_error_fastboot_path_missing=Aucun chemin vers l'outil fastboot n'a été fourni
script_error_serialNumber_missing=Aucun numéro de série fourni
install_instr_pressVolUpToAcceptOEMUnlocking=Appuyez sur "volume +" pour accepter le dévérouillage OEM
+install_instr_pressVolDownToAcceptOEMUnlocking=Appuyez sur "volume -" pour accepter le dévérouillage OEM
+install_instr_selectOEMUnlockingMenu = Acceptter le dévérouillage OEM en utilisant les touches du téléphone (se référer aux instructions sur l'écran du téléphone)
+
install_instr_rebootingOnBootloader=Votre téléphone va redémarrer automatiquement sur le mode bootloader
install_instr_onceDeviceRebootThenContinue=Votre téléphone va redémarrer automatiquement. Une fois que c'est fait, vous pouvez cliquer sur continuer
install_instr_waitInstallStartAuto=Veuillez patienter, l'installation va démarrer automatiquement
diff --git a/src/main/resources/yaml/OnePlus7T_flash.yml b/src/main/resources/yaml/OnePlus7T_flash.yml
new file mode 100644
index 0000000000000000000000000000000000000000..4ac402a3066edbd0175c6d6aa0ca6713f828e004
--- /dev/null
+++ b/src/main/resources/yaml/OnePlus7T_flash.yml
@@ -0,0 +1,218 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+stepsCount: 12
+steps:
+ f0:
+ type: custom
+ stepNumber: 1
+ nextStepKey: f1
+ titleKey: stepTitle_enableOemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_openSettings
+ - install_instr_searchOEM
+ - install_instr_enableOEMUnlocking
+ - install_instr_acceptOEMUnlockWarning
+ - install_instr_onceDoneThenContinue
+ f1:
+ type: load
+ stepNumber: 2
+ nextStepKey: f2
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 10
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f2:
+ type: custom-executable
+ stepNumber: 3
+ nextStepKey: f3
+ titleKey: stepTitle_oemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_unlockingOem
+ - install_instr_selectUnlockBootloader
+ - install_instr_unlockBootloader
+ - install_instr_unlockBootloader_already
+ script: oneplus-flashingUnlock
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 2: script_error_fastboot_flashingUnlock_failed
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f3:
+ type: custom
+ stepNumber: 4
+ nextStepKey: f4
+ titleKey: devMode_mTitle_main
+ titleIconName: icon-download.png
+ instructions:
+ - devMode_main
+ - devMode_lbl
+ - devMode_instr_settings
+ - devMode_instr_build
+ - devMode_instr_tap7
+ - debugADB_instr_settings
+ - debugADB_instr_search
+ - debugADB_instr_androidDebug
+ - debugADB_instr_debugOn
+ - debugADB_instr_tapeOK
+ - debugADB_instr_acceptCertificate
+ f4:
+ type: load
+ stepNumber: 5
+ nextStepKey: f5
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 8
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f5:
+ type: load
+ stepNumber: 6
+ nextStepKey: f6
+ titleKey: stepTitle4On7
+ instructions:
+ - install_instr_recoveryInstall
+ averageTime: 3
+ script: install-e-recovery
+ parameters:
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ twrp_image_path: ${TWRP_IMAGE_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 101: script_error_installRecovery_101
+ f6:
+ type: custom-executable
+ stepNumber: 7
+ nextStepKey: f7
+ titleKey: stepTitle5On7
+ instructions:
+ - install_instr_choose_e_recovery_select
+ - install_instr_choose_e_recovery_select_details
+ - install_instr_choose_e_recovery_validate
+ - install_instr_choose_e_recovery_validate_wait_for_result
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
+ - install_instr_e_recovery_apply_update_from_adb_wait_for_result
+ titleKeyIconName: icon-download.png
+ script: wait-e-recovery-sideload
+ parameters:
+ device_id: ${DEVICE_ID}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 101: script_error_waitSideload_101
+ f7:
+ type: load
+ stepNumber: 8
+ nextStepKey: f8
+ titleKey: install_instr_eosInstall
+ instructions:
+ - install_instr_e_recovery_oneplus_select_recovery
+ averageTime: 150
+ script: install-from-e-recovery
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${PATCH_PATH}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_installFromSideload
+ f8:
+ type: custom-executable
+ stepNumber: 9
+ nextStepKey: f9
+ titleKey: stepTitle_installation
+ instructions:
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_factory_reset
+ - install_instr_e_recovery_factory_reset_format_data
+ - install_instr_e_recovery_factory_reset_format_data_validate
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
+ - install_instr_e_recovery_apply_update_from_adb_wait_for_result
+ titleKeyIconName: icon-download.png
+ script: wait-e-recovery-sideload
+ parameters:
+ device_id: ${DEVICE_ID}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 101: script_error_waitSideload_101
+ f9:
+ type: load
+ stepNumber: 10
+ nextStepKey: f10
+ titleKey: install_instr_eosInstall
+ instructions:
+ - install_instr_e_recovery_oneplus_select_recovery
+ averageTime: 150
+ script: install-from-e-recovery
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_installFromSideload
+ f10:
+ type: askAccount
+ stepNumber: 11
+ nextStepKey: f11
+ f11:
+ type: custom
+ stepNumber: 12
+ nextStepKey: end
+ titleKey: stepTitle_rebootDevice
+ instructions:
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_reboot
+ - eAccount_lbl_alreadyAccount
+ titleKeyIconName: icon-download.png
diff --git a/src/main/resources/yaml/OnePlus7T_fs.yml b/src/main/resources/yaml/OnePlus7T_fs.yml
new file mode 100644
index 0000000000000000000000000000000000000000..b8f827e1cb71c611c73a672b8683fbc7017b4511
--- /dev/null
+++ b/src/main/resources/yaml/OnePlus7T_fs.yml
@@ -0,0 +1,26 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+sources:
+ rom:
+ url: https://images.ecloud.global/dev/hotdogb/e-0.23-r-20220405175826-dev-hotdogb.zip
+ filePath: e-0.23-r-20220405175826-dev-hotdogb.zip
+ twrp:
+ url: https://images.ecloud.global/dev/hotdogb/recovery-e-0.23-r-20220405175826-dev-hotdogb.img
+ filePath: recovery-e-0.23-r-20220405175826-dev-hotdogb.img
+ patch:
+ url: https://images.ecloud.global/dev/hotdogb/e-0.23-r-20220405175826-dev-hotdogb.zip
+ filePath: e-0.23-r-20220405175826-dev-hotdogb.zip
diff --git a/src/main/resources/yaml/OnePlus8_flash.yml b/src/main/resources/yaml/OnePlus8_flash.yml
new file mode 100644
index 0000000000000000000000000000000000000000..4ac402a3066edbd0175c6d6aa0ca6713f828e004
--- /dev/null
+++ b/src/main/resources/yaml/OnePlus8_flash.yml
@@ -0,0 +1,218 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+stepsCount: 12
+steps:
+ f0:
+ type: custom
+ stepNumber: 1
+ nextStepKey: f1
+ titleKey: stepTitle_enableOemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_openSettings
+ - install_instr_searchOEM
+ - install_instr_enableOEMUnlocking
+ - install_instr_acceptOEMUnlockWarning
+ - install_instr_onceDoneThenContinue
+ f1:
+ type: load
+ stepNumber: 2
+ nextStepKey: f2
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 10
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f2:
+ type: custom-executable
+ stepNumber: 3
+ nextStepKey: f3
+ titleKey: stepTitle_oemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_unlockingOem
+ - install_instr_selectUnlockBootloader
+ - install_instr_unlockBootloader
+ - install_instr_unlockBootloader_already
+ script: oneplus-flashingUnlock
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 2: script_error_fastboot_flashingUnlock_failed
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f3:
+ type: custom
+ stepNumber: 4
+ nextStepKey: f4
+ titleKey: devMode_mTitle_main
+ titleIconName: icon-download.png
+ instructions:
+ - devMode_main
+ - devMode_lbl
+ - devMode_instr_settings
+ - devMode_instr_build
+ - devMode_instr_tap7
+ - debugADB_instr_settings
+ - debugADB_instr_search
+ - debugADB_instr_androidDebug
+ - debugADB_instr_debugOn
+ - debugADB_instr_tapeOK
+ - debugADB_instr_acceptCertificate
+ f4:
+ type: load
+ stepNumber: 5
+ nextStepKey: f5
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 8
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f5:
+ type: load
+ stepNumber: 6
+ nextStepKey: f6
+ titleKey: stepTitle4On7
+ instructions:
+ - install_instr_recoveryInstall
+ averageTime: 3
+ script: install-e-recovery
+ parameters:
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ twrp_image_path: ${TWRP_IMAGE_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 101: script_error_installRecovery_101
+ f6:
+ type: custom-executable
+ stepNumber: 7
+ nextStepKey: f7
+ titleKey: stepTitle5On7
+ instructions:
+ - install_instr_choose_e_recovery_select
+ - install_instr_choose_e_recovery_select_details
+ - install_instr_choose_e_recovery_validate
+ - install_instr_choose_e_recovery_validate_wait_for_result
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
+ - install_instr_e_recovery_apply_update_from_adb_wait_for_result
+ titleKeyIconName: icon-download.png
+ script: wait-e-recovery-sideload
+ parameters:
+ device_id: ${DEVICE_ID}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 101: script_error_waitSideload_101
+ f7:
+ type: load
+ stepNumber: 8
+ nextStepKey: f8
+ titleKey: install_instr_eosInstall
+ instructions:
+ - install_instr_e_recovery_oneplus_select_recovery
+ averageTime: 150
+ script: install-from-e-recovery
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${PATCH_PATH}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_installFromSideload
+ f8:
+ type: custom-executable
+ stepNumber: 9
+ nextStepKey: f9
+ titleKey: stepTitle_installation
+ instructions:
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_factory_reset
+ - install_instr_e_recovery_factory_reset_format_data
+ - install_instr_e_recovery_factory_reset_format_data_validate
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
+ - install_instr_e_recovery_apply_update_from_adb_wait_for_result
+ titleKeyIconName: icon-download.png
+ script: wait-e-recovery-sideload
+ parameters:
+ device_id: ${DEVICE_ID}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 101: script_error_waitSideload_101
+ f9:
+ type: load
+ stepNumber: 10
+ nextStepKey: f10
+ titleKey: install_instr_eosInstall
+ instructions:
+ - install_instr_e_recovery_oneplus_select_recovery
+ averageTime: 150
+ script: install-from-e-recovery
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_installFromSideload
+ f10:
+ type: askAccount
+ stepNumber: 11
+ nextStepKey: f11
+ f11:
+ type: custom
+ stepNumber: 12
+ nextStepKey: end
+ titleKey: stepTitle_rebootDevice
+ instructions:
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_reboot
+ - eAccount_lbl_alreadyAccount
+ titleKeyIconName: icon-download.png
diff --git a/src/main/resources/yaml/OnePlus8_fs.yml b/src/main/resources/yaml/OnePlus8_fs.yml
new file mode 100644
index 0000000000000000000000000000000000000000..007c6082ff97cb87367b7cc3a6f4b95032b46949
--- /dev/null
+++ b/src/main/resources/yaml/OnePlus8_fs.yml
@@ -0,0 +1,26 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+sources:
+ rom:
+ url: https://images.ecloud.global/dev/instantnoodle/e-0.23-r-20220405175826-dev-instantnoodle.zip
+ filePath: e-0.23-r-20220405175826-dev-instantnoodle.zip
+ twrp:
+ url: https://images.ecloud.global/dev/instantnoodle/recovery-e-0.23-r-20220405175826-dev-instantnoodle.img
+ filePath: recovery-e-0.23-r-20220405175826-dev-instantnoodle.img
+ patch:
+ url: https://images.ecloud.global/dev/instantnoodle/e-0.23-r-20220405175826-dev-instantnoodle.zip
+ filePath: e-0.23-r-20220405175826-dev-instantnoodle.zip
diff --git a/src/main/resources/yaml/emerald_flash.yml b/src/main/resources/yaml/emerald_flash.yml
new file mode 100644
index 0000000000000000000000000000000000000000..0bd8e25e46a348aa9648d92a53337370157c8e33
--- /dev/null
+++ b/src/main/resources/yaml/emerald_flash.yml
@@ -0,0 +1,127 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+stepsCount: 6
+steps:
+ f0:
+ type: custom
+ stepNumber: 1
+ nextStepKey: f1
+ titleKey: stepTitle_enableOemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_openSettings
+ - install_instr_searchOEM
+ - install_instr_enableOEMUnlocking
+ - install_instr_acceptOEMUnlockWarning
+ - install_instr_onceDoneThenContinue
+ f1:
+ type: load
+ stepNumber: 2
+ nextStepKey: f2
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 12
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f2:
+ type: custom-executable
+ stepNumber: 3
+ nextStepKey: f3
+ titleKey: stepTitle_oemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_selectOEMUnlockingMenu
+ - install_instr_unlockingOem
+ - install_instr_waitInstallStartAuto
+ script: emerald-flashingUnlock
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 2: script_error_fastboot_flashingUnlock_failed
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+
+ f3:
+ type: load
+ stepNumber: 4
+ nextStepKey: f4
+ titleKey: stepTitle_installOS
+ instructions:
+ - install_instr_eosInstall
+ averageTime: 200
+ script: emerald-install-from-bootloader
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ java_folder_path: ${JAVA_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantUnpackSources
+ 11: script_error_cantWipeData
+ 12: script_error_cantWipeData
+ 20: script_error_cantFlashGz_a
+ 21: script_error_cantFlashLk_a
+ 22: script_error_cantFlashMd1img_a
+ 23: script_error_cantFlashScp_a
+ 24: script_error_cantFlashSpmfw_a
+ 25: script_error_cantFlashSspm_a
+ 26: script_error_cantFlashTee_a
+ 27: script_error_cantFlashBoot_a
+ 28: script_error_cantFlashDtbo_a
+ 29: script_error_cantFlashVbmeta_a
+ 30: script_error_cantFlashSuper
+ 101: script_error_serialNumber_missing
+ 102: script_error_installFromFastboot_102
+ 103: script_error_fastboot_path_missing
+ f4:
+ type: askAccount
+ stepNumber: 5
+ nextStepKey: f5
+ f5:
+ type: custom-executable
+ stepNumber: 6
+ nextStepKey: end
+ titleKey: stepTitle_rebootDevice
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_onceDeviceRebootThenContinue
+ script: emerald-wait-reboot-from-fastboot
+ parameters:
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantrebootFromFasboot
+ 101: script_error_noDeviceFoundInFastboot
diff --git a/src/main/resources/yaml/emerald_fs.yml b/src/main/resources/yaml/emerald_fs.yml
new file mode 100644
index 0000000000000000000000000000000000000000..b1c12e0679d7a0403656eb2fa60305b81017e449
--- /dev/null
+++ b/src/main/resources/yaml/emerald_fs.yml
@@ -0,0 +1,20 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+sources:
+ rom:
+ url: https://images.ecloud.global/stable/emerald/IMG-e-latest-emerald.zip
+ filePath: IMG-e-latest-emerald.zip
diff --git a/src/main/resources/yaml/star2lte_flash.yml b/src/main/resources/yaml/star2lte_flash.yml
index 585e873cd7670c8b9ff75d0c597f4dc6dbec702d..605c739b9781c9d80e8721fe85c98df101335fc7 100644
--- a/src/main/resources/yaml/star2lte_flash.yml
+++ b/src/main/resources/yaml/star2lte_flash.yml
@@ -1,4 +1,4 @@
-## Copyright 2021 - ECORP SAS
+## Copyright 202-2022 - ECORP SAS
## This program is free software: you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -12,9 +12,9 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see .
-## Author: Vincent Bourgmayer
+## Author: Vincent Bourgmayer, Frank Preel
---
-stepsCount: 11
+stepsCount: 7
steps:
f0:
type: custom
@@ -73,151 +73,50 @@ steps:
titleKey: stepTitle5On7
instructions:
- install_instr_leaveDl_pressPowerBixbyVolDown
- - install_instr_startRec_pressPowerBixbyVolUp
- - install_instr_keepReadOnly
+ - install_instr_startRec_pressPowerBixbyVolUp_e_reco
+ - install_instr_e_recovery_factory_reset
+ - install_instr_e_recovery_factory_reset_format_data
+ - install_instr_e_recovery_factory_reset_format_data_validate
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
titleKeyIconName: icon-download.png
- script: wait-recovery
+ script: wait-e-recovery-sideload
parameters:
device_id: ${DEVICE_ID}
adb_folder_path: ${ADB_FOLDER_PATH}
okCodes:
0: ~
koCodes:
- 1: script_error_waitRecovery_1
- 101: script_error_waitRecovery_101
- 102: script_error_waitRecovery_102
+ 101: script_error_waitSideload_101
f4:
- type: custom-executable
+ type: load
stepNumber: 5
nextStepKey: f5
- titleKey: stepTitle5On7
+ titleKey: install_instr_eosInstall
instructions:
- - install_instr_tapWipe
- - install_instr_tapFormatData
- - install_instr_writeYes
- - install_instr_validate
- - install_instr_backX3
- - install_instr_tapReboot
- - install_instr_tapRebootRecovery
- - install_instr_doNotInstall
- titleKeyIconName: icon-download.png
- script: wait-reboot
+ - install_instr_eosInstall
+ averageTime: 150
+ script: install-from-e-recovery
parameters:
device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
adb_folder_path: ${ADB_FOLDER_PATH}
okCodes:
0: ~
koCodes:
- 1: script_error_unknown
- 10: script_error_waitReboot_10
- 101: script_error_waitReboot_101
+ 1: script_error_installFromSideload
f5:
- type: custom-executable
+ type: askAccount
stepNumber: 6
nextStepKey: f6
- titleKey: stepTitle5On7
- instructions:
- - install_instr_swipeTwrp
- titleKeyIconName: icon-download.png
- script: wait-recovery
- parameters:
- device_id: ${DEVICE_ID}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_waitRecovery_1
- 101: script_error_waitRecovery_101
- 102: script_error_waitRecovery_102
f6:
- type: load
+ type: custom
stepNumber: 7
- nextStepKey: f7
- titleKey: install_instr_patchInstall
- instructions:
- - install_instr_patchInstall
- averageTime: 55
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${SOURCES_PATH}no-verity-opt-encrypt-samsung-1.0.zip
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f7:
- type: load
- stepNumber: 8
- nextStepKey: f8
- titleKey: install_instr_vendorInstall
- instructions:
- - install_instr_vendorInstall
- averageTime: 65
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${SOURCES_PATH}VENDOR-27_ARI9.zip
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f8:
- type: load
- stepNumber: 9
- nextStepKey: f9
- titleKey: install_instr_eosInstall
- instructions:
- - install_instr_eosInstall
- averageTime: 440
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${ARCHIVE_PATH}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f9:
- type: askAccount
- stepNumber: 10
- nextStepKey: f10
- f10:
- type: custom-executable
- stepNumber: 11
nextStepKey: end
titleKey: stepTitle7On7
instructions:
- - install_instr_tapWipe
- - install_instr_tapAdvancedWipe
- - install_instr_tickData
- - install_instr_tapRepairChangeFs
- - install_instr_resizeFs
- - install_instr_swipeForOk
- - install_instr_tapRebootSystem
- - install_instr_doNotInstall
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_reboot
+ - eAccount_lbl_alreadyAccount
titleKeyIconName: icon-download.png
- script: wait-reboot
- parameters:
- device_id: ${DEVICE_ID}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_unknown
- 10: script_error_waitReboot_10
- 101: script_error_waitReboot_101
diff --git a/src/main/resources/yaml/star2lte_fs.yml b/src/main/resources/yaml/star2lte_fs.yml
index e036cd171e058dc4b754f10ccdcf9d8c439a7f6e..108074e354ac3d21f144bcf6a09d8a08af861930 100644
--- a/src/main/resources/yaml/star2lte_fs.yml
+++ b/src/main/resources/yaml/star2lte_fs.yml
@@ -1,4 +1,4 @@
-## Copyright 2019-2021 - ECORP SAS
+## Copyright 2019-2022 - ECORP SAS
## This program is free software: you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -12,18 +12,12 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see .
-## Author: Vincent Bourgmayer
+## Authors: Vincent Bourgmayer, Frank Preel
---
sources:
rom:
- url: https://images.ecloud.global/stable/star2lte/e-latest-star2lte.zip
- filePath: e-latest-star2lte.zip
+ url: https://images.ecloud.global/stable/star2lte/e-latest-q-star2lte.zip
+ filePath: e-latest-q-star2lte.zip
twrp:
- url: https://images.ecloud.global/stable/twrp/star2lte/twrp-3.2.3-0-star2lte.img
- filePath: twrp-3.2.3-0-star2lte.img
- f2:
- url: https://images.ecloud.global/stable/vendors/VENDOR-27_ARI9.zip
- filePath: VENDOR-27_ARI9.zip
- f3:
- url: https://images.ecloud.global/stable/patch/no-verity-opt-encrypt-samsung-1.0.zip
- filePath: no-verity-opt-encrypt-samsung-1.0.zip
\ No newline at end of file
+ url: https://images.ecloud.global/stable/star2lte/recovery-e-latest-q-star2lte.img
+ filePath: recovery-e-latest-q-star2lte.img
diff --git a/src/main/resources/yaml/starlte_flash.yml b/src/main/resources/yaml/starlte_flash.yml
index 585e873cd7670c8b9ff75d0c597f4dc6dbec702d..97c30be1ae23ca2b7c43be7761743d8eda7fa627 100644
--- a/src/main/resources/yaml/starlte_flash.yml
+++ b/src/main/resources/yaml/starlte_flash.yml
@@ -1,4 +1,4 @@
-## Copyright 2021 - ECORP SAS
+## Copyright 202-2022 - ECORP SAS
## This program is free software: you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -12,9 +12,9 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see .
-## Author: Vincent Bourgmayer
+## Author: Vincent Bourgmayer, Frank Preel
---
-stepsCount: 11
+stepsCount: 7
steps:
f0:
type: custom
@@ -73,151 +73,50 @@ steps:
titleKey: stepTitle5On7
instructions:
- install_instr_leaveDl_pressPowerBixbyVolDown
- - install_instr_startRec_pressPowerBixbyVolUp
- - install_instr_keepReadOnly
+ - install_instr_startRec_pressPowerBixbyVolUp_e_reco
+ - install_instr_e_recovery_factory_reset
+ - install_instr_e_recovery_factory_reset_format_data
+ - install_instr_e_recovery_factory_reset_format_data_validate
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
titleKeyIconName: icon-download.png
- script: wait-recovery
+ script: wait-e-recovery-sideload
parameters:
device_id: ${DEVICE_ID}
adb_folder_path: ${ADB_FOLDER_PATH}
okCodes:
0: ~
koCodes:
- 1: script_error_waitRecovery_1
- 101: script_error_waitRecovery_101
- 102: script_error_waitRecovery_102
+ 101: script_error_waitSideload_101
f4:
- type: custom-executable
+ type: load
stepNumber: 5
nextStepKey: f5
- titleKey: stepTitle5On7
+ titleKey: install_instr_eosInstall
instructions:
- - install_instr_tapWipe
- - install_instr_tapFormatData
- - install_instr_writeYes
- - install_instr_validate
- - install_instr_backX3
- - install_instr_tapReboot
- - install_instr_tapRebootRecovery
- - install_instr_doNotInstall
- titleKeyIconName: icon-download.png
- script: wait-reboot
+ - install_instr_eosInstall
+ averageTime: 150
+ script: install-from-e-recovery
parameters:
device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
adb_folder_path: ${ADB_FOLDER_PATH}
okCodes:
0: ~
koCodes:
- 1: script_error_unknown
- 10: script_error_waitReboot_10
- 101: script_error_waitReboot_101
+ 1: script_error_installFromSideload
f5:
- type: custom-executable
+ type: askAccount
stepNumber: 6
nextStepKey: f6
- titleKey: stepTitle5On7
- instructions:
- - install_instr_swipeTwrp
- titleKeyIconName: icon-download.png
- script: wait-recovery
- parameters:
- device_id: ${DEVICE_ID}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_waitRecovery_1
- 101: script_error_waitRecovery_101
- 102: script_error_waitRecovery_102
f6:
- type: load
+ type: custom
stepNumber: 7
- nextStepKey: f7
- titleKey: install_instr_patchInstall
- instructions:
- - install_instr_patchInstall
- averageTime: 55
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${SOURCES_PATH}no-verity-opt-encrypt-samsung-1.0.zip
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f7:
- type: load
- stepNumber: 8
- nextStepKey: f8
- titleKey: install_instr_vendorInstall
- instructions:
- - install_instr_vendorInstall
- averageTime: 65
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${SOURCES_PATH}VENDOR-27_ARI9.zip
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f8:
- type: load
- stepNumber: 9
- nextStepKey: f9
- titleKey: install_instr_eosInstall
- instructions:
- - install_instr_eosInstall
- averageTime: 440
- script: install-from-recovery
- parameters:
- device_id: ${DEVICE_ID}
- archive_path: ${ARCHIVE_PATH}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_installFromRecovery_1
- 2: script_error_installFromRecovery_2
- 3: script_error_installFromRecovery_3
- 101: script_error_installFromRecovery_101
- 102: script_error_installFromRecovery_102
- f9:
- type: askAccount
- stepNumber: 10
- nextStepKey: f10
- f10:
- type: custom-executable
- stepNumber: 11
nextStepKey: end
titleKey: stepTitle7On7
instructions:
- - install_instr_tapWipe
- - install_instr_tapAdvancedWipe
- - install_instr_tickData
- - install_instr_tapRepairChangeFs
- - install_instr_resizeFs
- - install_instr_swipeForOk
- - install_instr_tapRebootSystem
- - install_instr_doNotInstall
- titleKeyIconName: icon-download.png
- script: wait-reboot
- parameters:
- device_id: ${DEVICE_ID}
- adb_folder_path: ${ADB_FOLDER_PATH}
- okCodes:
- 0: ~
- koCodes:
- 1: script_error_unknown
- 10: script_error_waitReboot_10
- 101: script_error_waitReboot_101
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_reboot
+ - eAccount_lbl_alreadyAccount
+ titleKeyIconName: icon-download.png
\ No newline at end of file
diff --git a/src/main/resources/yaml/starlte_fs.yml b/src/main/resources/yaml/starlte_fs.yml
index d9a906d955cbe48b1535d840a38ab926a9d993b6..c31c7eb2ef65bae3ad16a378ac3c588c55a31bbd 100644
--- a/src/main/resources/yaml/starlte_fs.yml
+++ b/src/main/resources/yaml/starlte_fs.yml
@@ -1,4 +1,4 @@
-## Copyright 2019-2021 - ECORP SAS
+## Copyright 2019-2022 - ECORP SAS
## This program is free software: you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -12,18 +12,12 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see .
-## Author: Vincent Bourgmayer
+## Authors: Vincent Bourgmayer, Frank Preel
---
sources:
rom:
- url: https://images.ecloud.global/stable/starlte/e-latest-starlte.zip
- filePath: e-latest-starlte.zip
+ url: https://images.ecloud.global/stable/starlte/e-latest-q-starlte.zip
+ filePath: e-latest-q-starlte.zip
twrp:
- url: https://images.ecloud.global/stable/twrp/starlte/twrp-3.2.3-0-starlte.img
- filePath: twrp-3.2.3-0-starlte.img
- f2:
- url: https://images.ecloud.global/stable/vendors/VENDOR-27_ARI9.zip
- filePath: VENDOR-27_ARI9.zip
- f3:
- url: https://images.ecloud.global/stable/patch/no-verity-opt-encrypt-samsung-1.0.zip
- filePath: no-verity-opt-encrypt-samsung-1.0.zip
+ url: https://images.ecloud.global/stable/starlte/recovery-e-latest-q-starlte.img
+ filePath: recovery-e-latest-q-starlte.img
diff --git a/src/main/resources/yaml/sunfish_flash.yml b/src/main/resources/yaml/sunfish_flash.yml
new file mode 100644
index 0000000000000000000000000000000000000000..b8cba20fd99f0ea0e71b0fe94639145087ddd9ff
--- /dev/null
+++ b/src/main/resources/yaml/sunfish_flash.yml
@@ -0,0 +1,144 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+stepsCount: 8
+steps:
+ f0:
+ type: custom
+ stepNumber: 1
+ nextStepKey: f1
+ titleKey: stepTitle_enableOemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_openSettings
+ - install_instr_searchOEM
+ - install_instr_enableOEMUnlocking
+ - install_instr_acceptOEMUnlockWarning
+ - install_instr_onceDoneThenContinue
+ f1:
+ type: load
+ stepNumber: 2
+ nextStepKey: f2
+ titleKey: stepTitle_rebootBootloader
+ instructions:
+ - install_instr_rebootingOnBootloader
+ averageTime: 10
+ script: reboot-fastboot
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 10: script_error_cantRebootBootloader
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f2:
+ type: custom-executable
+ stepNumber: 3
+ nextStepKey: f3
+ titleKey: stepTitle_oemUnlock
+ titleIconName: icon-download.png
+ instructions:
+ - install_instr_unlockingOem
+ - install_instr_selectUnlockBootloader
+ - install_instr_unlockBootloader
+ script: pixel-flashingUnlock
+ parameters:
+ device_id: ${DEVICE_ID}
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 2: script_error_fastboot_flashingUnlock_failed
+ 101: script_error_serialNumber_missing
+ 102: script_error_fastboot_path_missing
+ f3:
+ type: load
+ stepNumber: 4
+ nextStepKey: f4
+ titleKey: stepTitle4On7
+ instructions:
+ - install_instr_recoveryInstall
+ averageTime: 3
+ script: install-e-recovery-boot
+ parameters:
+ fastboot_folder_path: ${ADB_FOLDER_PATH}
+ twrp_image_path: ${TWRP_IMAGE_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_unknown
+ 101: script_error_installRecovery_101
+ f4:
+ type: custom-executable
+ stepNumber: 5
+ nextStepKey: f5
+ titleKey: stepTitle5On7
+ instructions:
+ - install_instr_choose_e_recovery_select
+ - install_instr_choose_e_recovery_select_details
+ - install_instr_choose_e_recovery_validate
+ - install_instr_choose_e_recovery_validate_wait_for_result
+ - install_instr_e_recovery_factory_reset
+ - install_instr_e_recovery_factory_reset_format_data
+ - install_instr_e_recovery_factory_reset_format_data_validate
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_apply_update
+ - install_instr_e_recovery_apply_update_from_adb
+ - install_instr_e_recovery_apply_update_from_adb_wait_for_result
+ titleKeyIconName: icon-download.png
+ script: wait-e-recovery-sideload
+ parameters:
+ device_id: ${DEVICE_ID}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 101: script_error_waitSideload_101
+ f5:
+ type: load
+ stepNumber: 6
+ nextStepKey: f6
+ titleKey: install_instr_eosInstall
+ instructions:
+ - install_instr_eosInstall
+ averageTime: 150
+ script: install-from-e-recovery
+ parameters:
+ device_id: ${DEVICE_ID}
+ archive_path: ${ARCHIVE_PATH}
+ adb_folder_path: ${ADB_FOLDER_PATH}
+ okCodes:
+ 0: ~
+ koCodes:
+ 1: script_error_installFromSideload
+ f6:
+ type: askAccount
+ stepNumber: 7
+ nextStepKey: f7
+ f7:
+ type: custom
+ stepNumber: 8
+ nextStepKey: end
+ titleKey: stepTitle_rebootDevice
+ instructions:
+ - install_instr_e_recovery_back
+ - install_instr_e_recovery_reboot
+ - eAccount_lbl_alreadyAccount
+ titleKeyIconName: icon-download.png
diff --git a/src/main/resources/yaml/sunfish_fs.yml b/src/main/resources/yaml/sunfish_fs.yml
new file mode 100644
index 0000000000000000000000000000000000000000..3cf0671ce75932ef4dc587001a7371712c2239c5
--- /dev/null
+++ b/src/main/resources/yaml/sunfish_fs.yml
@@ -0,0 +1,23 @@
+## Copyright 2022 - ECORP SAS
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see .
+## Author: Frank Preel
+---
+sources:
+ rom:
+ url: https://images.ecloud.global/dev/sunfish/e-0.23-r-20220405175826-dev-sunfish.zip
+ filePath: e-0.23-r-20220405175826-dev-sunfish.zip
+ twrp:
+ url: https://images.ecloud.global/dev/sunfish/recovery-e-0.23-r-20220405175826-dev-sunfish.img
+ filePath: recovery-e-0.23-r-20220405175826-dev-sunfish.img
diff --git a/windows-installer-mui.nsi b/windows-installer-mui.nsi
index dcf50a790a29d6446011e39615c5043dc9a87e1f..2a2aa8075321371b3374612fe99f93cae4715e93 100644
--- a/windows-installer-mui.nsi
+++ b/windows-installer-mui.nsi
@@ -9,7 +9,7 @@
#--------------------------------
RequestExecutionLevel admin #if 'user' then it can't install in C:\Program files
!define MUI_ICON "buildSrc/windows/easy-installer.ico"
-!define appVersion "v0.13.4-beta"
+!define appVersion "v0.14.0"
Name "Easy-installer ${appVersion}"
# define installation directory
InstallDir "$PROGRAMFILES64\easy-installer"