forked from TheGammaSqueeze/GammaOS
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRG405M-FlashPartitions.sh
64 lines (45 loc) · 2.24 KB
/
RG405M-FlashPartitions.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/bin/bash
set -e
echo ---------------------------------------
echo "GammaOS Lite v1.3.1 - Anbernic RG405M"
echo ---------------------------------------
if ! [ -x "$(command -v fastboot)" ]; then
echo "ERROR: fastboot seems not installed, please install it!"
fi
echo "fastboot devices"
fastboot devices
fastboot devices >> log.txt 2>&1
echo "fastboot flash vbmeta_a flash/vbmeta_custom.img"
fastboot flash vbmeta_a flash/vbmeta_custom.img >>log.txt 2>&1
echo "fastboot flash vbmeta_b flash/vbmeta_custom.img"
fastboot flash vbmeta_b flash/vbmeta_custom.img >>log.txt 2>&1
echo "fastboot flash boot_a flash/boot_custom_405.img"
fastboot flash boot_a flash/boot_custom_405.img >>log.txt 2>&1
echo "fastboot flash boot_b flash/boot_custom_405.img"
fastboot flash boot_b flash/boot_custom_405.img >>log.txt 2>&1
echo "fastboot flash dtbo_a flash/dtbo_custom_405.img"
fastboot flash dtbo_a flash/dtbo_custom_405.img >>log.txt 2>&1
echo "fastboot flash dtbo_b flash/dtbo_custom_405.img"
fastboot flash dtbo_b flash/dtbo_custom_405.img >>log.txt 2>&1
echo "fastboot flash vendor_boot_a flash/vendor_boot_custom_405.img"
fastboot flash vendor_boot_a flash/vendor_boot_custom_405.img >>log.txt 2>&1
echo "fastboot flash vendor_boot_b flash/vendor_boot_custom_405.img"
fastboot flash vendor_boot_b flash/vendor_boot_custom_405.img >>log.txt 2>&1
echo "fastboot delete-logical-partition vendor_a-cow"
fastboot delete-logical-partition vendor_a-cow >>log.txt 2>&1
echo "fastboot delete-logical-partition vendor_b-cow"
fastboot delete-logical-partition vendor_b-cow >>log.txt 2>&1
echo "fastboot flash vendor flash/vendor_custom_rp3_driver_405.img"
echo "This will take some time, please wait..."
fastboot flash vendor flash/vendor_custom_rp3_driver_405.img >>log.txt 2>&1
echo "fastboot delete-logical-partition system_a-cow"
fastboot delete-logical-partition system_a-cow >>log.txt 2>&1
echo "fastboot delete-logical-partition system_b-cow"
fastboot delete-logical-partition system_b-cow >>log.txt 2>&1
echo "fastboot flash system flash/system_custom.img"
echo This will take some time, up to 5 minutes, please wait...
fastboot flash system flash/system_custom.img >>log.txt 2>&1
echo "Flashing complete."
echo "Closing this windows in 60 secondes"
sleep 60
exit