Lg d3 d850 autoboot - AT&T LG G3

I spent some time trying to figure out how to make my old G3 autoboot on charger so I could use it like a navigator in a car.
So here you go:
Patient: LG G3 D850 MM 6.0 30A
Requirements: rooted device.
in a nutshell - add following bold lines into the section [INIT|_CHARGING] of the /system/vendor/etc/chargerimages/chargerlogo.ini
[INIT_CHARGING]
POWER_OFF = NOT_CONNECTED_BL_LOW
REBOOT = NOT_CONNECTED_BL_NOT_LOW
NOT_BOOT_CHARGING = CHARGING_BL_LOW
NOT_BOOT_CHARGING = NOT_CHARGING_BL_LOW
NORMAL_CHARGING = CHARGING_BL_MID
NORMAL_CHARGING = NOT_CHARGING_BL_MID
FULL_CHARGING = CHARGING_BL_MAX
FULL_CHARGING = CHARGING_FULL
FULL_CHARGING = NOT_CHARGING_BL_MAX
WARNING_TEMPERATURE_BL_LOW = COLD_OVERHEAT_BL_LOW
WARNING_TEMPERATURE_BL_NOT_LOW = COLD_OVERHEAT_BL_NOT_LOW
INSERT_BATTERY = NOT_EXIST_BATTERY
WIRELESS_NOT_BOOT_CHARGING = CHARGING_WIRELESS_BL_LOW
REBOOT = CHARGING_WIRELESS_BL_NOT_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_NOT_LOW
DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
REBOOT = AUTOBOOT
More detailed steps:
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini /system/vendor/etc/chargerimages/chargerlogo.ini
reboot
btw, if you are not familiar with all that stuff, you can just simulate event 'NOT_CONNECTED_BL_NOT_LOW' to power it up without touching power button:
- power on the car.
- wait 2-3 sec for static battery logo appeared.
- power off the car for 2-3 secs and you can power on/start engine right after that.
- LG will start in a few seconds.

Corund said:
I spent some time trying to figure out how to make my old G3 autoboot on charger so I could use it like a navigator in a car.
So here you go:
Patient: LG G3 D850 MM 6.0 30A
Requirements: rooted device.
in a nutshell - add following bold lines into the section [INIT|_CHARGING] of the /system/vendor/etc/chargerimages/chargerlogo.ini
[INIT_CHARGING]
POWER_OFF = NOT_CONNECTED_BL_LOW
REBOOT = NOT_CONNECTED_BL_NOT_LOW
NOT_BOOT_CHARGING = CHARGING_BL_LOW
NOT_BOOT_CHARGING = NOT_CHARGING_BL_LOW
NORMAL_CHARGING = CHARGING_BL_MID
NORMAL_CHARGING = NOT_CHARGING_BL_MID
FULL_CHARGING = CHARGING_BL_MAX
FULL_CHARGING = CHARGING_FULL
FULL_CHARGING = NOT_CHARGING_BL_MAX
WARNING_TEMPERATURE_BL_LOW = COLD_OVERHEAT_BL_LOW
WARNING_TEMPERATURE_BL_NOT_LOW = COLD_OVERHEAT_BL_NOT_LOW
INSERT_BATTERY = NOT_EXIST_BATTERY
WIRELESS_NOT_BOOT_CHARGING = CHARGING_WIRELESS_BL_LOW
REBOOT = CHARGING_WIRELESS_BL_NOT_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_NOT_LOW
DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
REBOOT = AUTOBOOT
More detailed steps:
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini ./chargerlogo.ini
reboot
btw, if you are not familiar with all that stuff, you can just simulate event 'NOT_CONNECTED_BL_NOT_LOW' to power it up without touching power button:
- power on the car.
- wait 2-3 sec for static battery logo appeared.
- power off the car for 2-3 secs and you can power on/start engine right after that.
- LG will start in a few seconds.
Click to expand...
Click to collapse
Nice....
I have had to do similar to my tablets I run in my cars dash

was looking for this, could only find nexus and Samsung devices. Thanks a million

Corund said:
I spent some time trying to figure out how to make my old G3 autoboot on charger so I could use it like a navigator in a car.
So here you go:
Patient: LG G3 D850 MM 6.0 30A
Requirements: rooted device.
in a nutshell - add following bold lines into the section [INIT|_CHARGING] of the /system/vendor/etc/chargerimages/chargerlogo.ini
[INIT_CHARGING]
POWER_OFF = NOT_CONNECTED_BL_LOW
REBOOT = NOT_CONNECTED_BL_NOT_LOW
NOT_BOOT_CHARGING = CHARGING_BL_LOW
NOT_BOOT_CHARGING = NOT_CHARGING_BL_LOW
NORMAL_CHARGING = CHARGING_BL_MID
NORMAL_CHARGING = NOT_CHARGING_BL_MID
FULL_CHARGING = CHARGING_BL_MAX
FULL_CHARGING = CHARGING_FULL
FULL_CHARGING = NOT_CHARGING_BL_MAX
WARNING_TEMPERATURE_BL_LOW = COLD_OVERHEAT_BL_LOW
WARNING_TEMPERATURE_BL_NOT_LOW = COLD_OVERHEAT_BL_NOT_LOW
INSERT_BATTERY = NOT_EXIST_BATTERY
WIRELESS_NOT_BOOT_CHARGING = CHARGING_WIRELESS_BL_LOW
REBOOT = CHARGING_WIRELESS_BL_NOT_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_NOT_LOW
DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
REBOOT = AUTOBOOT
More detailed steps:
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini /system/vendor/etc/chargerimages/chargerlogo.ini
reboot
btw, if you are not familiar with all that stuff, you can just simulate event 'NOT_CONNECTED_BL_NOT_LOW' to power it up without touching power button:
- power on the car.
- wait 2-3 sec for static battery logo appeared.
- power off the car for 2-3 secs and you can power on/start engine right after that.
- LG will start in a few seconds.
Click to expand...
Click to collapse
When i try to copy i always get an error saying "tmp-mksh: /sdcard/chargerlogo.ini: not found" even though when i do a ls i see the file sitting there
127|[email protected]:/ $ ls -l /sdcard/
ls -l /sdcard/
drwxrwx--- root sdcard_r 2014-12-31 19:08 Alarms
drwxrwx--x root sdcard_r 2017-12-10 20:12 Android
drwxrwx--- root sdcard_r 2018-12-11 08:46 AutoGuard
drwxrwx--- root sdcard_r 2014-12-31 19:08 DCIM
drwxrwx--- root sdcard_r 2018-12-30 03:02 Download
drwxrwx--- root sdcard_r 2014-12-31 19:08 LGBackup
drwxrwx--- root sdcard_r 2014-12-31 19:08 Movies
drwxrwx--- root sdcard_r 2014-12-31 19:08 Music
drwxrwx--- root sdcard_r 2014-12-31 19:08 Notifications
drwxrwx--- root sdcard_r 2017-12-25 08:32 Pictures
drwxrwx--- root sdcard_r 2014-12-31 19:08 Podcasts
drwxrwx--- root sdcard_r 2014-12-31 19:09 Ringtones
drwxrwx--- root sdcard_r 2017-12-21 01:16 Tasker
drwxrwx--- root sdcard_r 2018-11-16 02:00 WhatsApp
drwxrwx--- root sdcard_r 2017-12-23 01:55 backups
-rwxrwx--- root sdcard_r 2925 2018-12-30 09:37 chargerlogo.ini
drwxrwx--- root sdcard_r 2017-12-10 07:13 media
drwxrwx--- root sdcard_r 2017-12-10 07:13 smartconfig

Corund said:
I spent some time trying to figure out how to make my old G3 autoboot on charger so I could use it like a navigator in a car.
So here you go:
Patient: LG G3 D850 MM 6.0 30A
Requirements: rooted device.
in a nutshell - add following bold lines into the section [INIT|_CHARGING] of the /system/vendor/etc/chargerimages/chargerlogo.ini
[INIT_CHARGING]
POWER_OFF = NOT_CONNECTED_BL_LOW
REBOOT = NOT_CONNECTED_BL_NOT_LOW
NOT_BOOT_CHARGING = CHARGING_BL_LOW
NOT_BOOT_CHARGING = NOT_CHARGING_BL_LOW
NORMAL_CHARGING = CHARGING_BL_MID
NORMAL_CHARGING = NOT_CHARGING_BL_MID
FULL_CHARGING = CHARGING_BL_MAX
FULL_CHARGING = CHARGING_FULL
FULL_CHARGING = NOT_CHARGING_BL_MAX
WARNING_TEMPERATURE_BL_LOW = COLD_OVERHEAT_BL_LOW
WARNING_TEMPERATURE_BL_NOT_LOW = COLD_OVERHEAT_BL_NOT_LOW
INSERT_BATTERY = NOT_EXIST_BATTERY
WIRELESS_NOT_BOOT_CHARGING = CHARGING_WIRELESS_BL_LOW
REBOOT = CHARGING_WIRELESS_BL_NOT_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_NOT_LOW
DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
REBOOT = AUTOBOOT
More detailed steps:
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini /system/vendor/etc/chargerimages/chargerlogo.ini
reboot
btw, if you are not familiar with all that stuff, you can just simulate event 'NOT_CONNECTED_BL_NOT_LOW' to power it up without touching power button:
- power on the car.
- wait 2-3 sec for static battery logo appeared.
- power off the car for 2-3 secs and you can power on/start engine right after that.
- LG will start in a few seconds.
Click to expand...
Click to collapse
Could you please upload the "chargerimages" folder? After having flashed a ROM I do not have it :/

Folder location
Hi, I cant find this folder. My current ROM is Lingeage OS 16 android 9. Are you Know where to look tis folder? Many thanks

Thanks for sollution.
My LG G2 Mini now AutoBoot after plug charger
I use ES File Explorer to edit "chargerlogo.ini" and after save it's work perfect.

Hi. I have modified the chargerlogo.ini. Works well after battery charge is less than 100%
When the battery is at 100% the autoboot does not work.
Could someone help me to solve this problem?
Thank you
Alexander

Corund said:
I spent some time trying to figure out how to make my old G3 autoboot on charger so I could use it like a navigator in a car.
So here you go:
Patient: LG G3 D850 MM 6.0 30A
Requirements: rooted device.
in a nutshell - add following bold lines into the section [INIT|_CHARGING] of the /system/vendor/etc/chargerimages/chargerlogo.ini
[INIT_CHARGING]
POWER_OFF = NOT_CONNECTED_BL_LOW
REBOOT = NOT_CONNECTED_BL_NOT_LOW
NOT_BOOT_CHARGING = CHARGING_BL_LOW
NOT_BOOT_CHARGING = NOT_CHARGING_BL_LOW
NORMAL_CHARGING = CHARGING_BL_MID
NORMAL_CHARGING = NOT_CHARGING_BL_MID
FULL_CHARGING = CHARGING_BL_MAX
FULL_CHARGING = CHARGING_FULL
FULL_CHARGING = NOT_CHARGING_BL_MAX
WARNING_TEMPERATURE_BL_LOW = COLD_OVERHEAT_BL_LOW
WARNING_TEMPERATURE_BL_NOT_LOW = COLD_OVERHEAT_BL_NOT_LOW
INSERT_BATTERY = NOT_EXIST_BATTERY
WIRELESS_NOT_BOOT_CHARGING = CHARGING_WIRELESS_BL_LOW
REBOOT = CHARGING_WIRELESS_BL_NOT_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_LOW
INVALID_BATTERY = INVAILD_BATTERY_BL_NOT_LOW
DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
REBOOT = AUTOBOOT
More detailed steps:
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini /system/vendor/etc/chargerimages/chargerlogo.ini
reboot
btw, if you are not familiar with all that stuff, you can just simulate event 'NOT_CONNECTED_BL_NOT_LOW' to power it up without touching power button:
- power on the car.
- wait 2-3 sec for static battery logo appeared.
- power off the car for 2-3 secs and you can power on/start engine right after that.
- LG will start in a few seconds.
Click to expand...
Click to collapse
Hello,
I reopen the post because I try to autoboot my Lg g2 mini on charger. I have add:
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
after "DUMMY_BATTERY = DUMMY_BATTERY_BL_NONE" but smartphone doesn't autoboot when charger is plug.
My question is: I just need to insert
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
in the file chargerlogo.ini, or I need to do something else?
This steps how and where can i use it? Otherwise: what they are for and where I need to use them?
adb pull /system/vendor/etc/chargerimages/chargerlogo.ini ./chargerlogo.ini
add the lines into chargerlogo.ini
adb push ./chargerlogo.ini /sdcard/chargerlogo.ini
adb shell
adb su
mount -o rw,remount,rw /system
cp /sdcard/chargerlogo.ini /system/vendor/etc/chargerimages/chargerlogo.ini
reboot
Thanks

Pumpkin_PL said:
Thanks for sollution.
My LG G2 Mini now AutoBoot after plug charger
I use ES File Explorer to edit "chargerlogo.ini" and after save it's work perfect.
Click to expand...
Click to collapse
Hi, you added just this'?
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
because my lg g2 mini doesn't boot automatically after charger. Any suggestion? Thanks

marco0608 said:
Hi, you added just this'?
REBOOT = CHARGING_BL_LOW
REBOOT = CHARGING_BL_MID
REBOOT = CHARGING_BL_MAX
REBOOT = CHARGING_FULL
because my lg g2 mini doesn't boot automatically after charger. Any suggestion? Thanks
Click to expand...
Click to collapse
Yes, work now. I don't know because I didn't try yet, but I think that you can try to stop charge at 99%.

Related

[Q]

i buy this chines gps from ebay..its running win ce 6.0 ... i use a modified script to acces all my navcore that i instaled. the problem is i don`t know the command for exit...this script was for mio but it works on my gps but the exit button doesent work...the script look like this:
ICONXPBUTTON
x = -8
y = -16
Command = "\Storage Card\MioAutoRun\Programs\Utils\mspower.exe"
SizeNormal = 80
SizePushed = 70
ScaleAlpha = 100
IconNormal = ..\Icons\ff.ico
ScaleAlpha = 100
IconPushed = ..\Icons\ff_.ico
i change the path...still not working....i need the command to exit from a window
i want to be able to exit my script once i hit the exit button

[DEV] Dumping out the kernel, ROM, etc.

Let's discuss how we could dump out the kernel, ROMS, etc. from Galaxy R:
The following command would help to dump the kernel out (need su)
Code:
cat /dev/block/mmcblk0p9 > /sdcard/boot-i9103.img
The following command should help to dump the /system/ out (need su)
Code:
cat /dev/block/mmcblk0p2 > /sdcard/system-i9103.img
legion1911 said:
If you dump with su you have su in the dump, no?
How about a temporary root solution?
Click to expand...
Click to collapse
Yes, dumping out the /system/ will contain su
But what it means is just dumping the /bin/su and /system/app/Superuser.apk inclusively.
After dumping out, one can remove the su & superuser.apk to make a 'non-rooted' ROM, if necessary.
ardatdat said:
After dumping out, one can remove the su & superuser.apk to make a 'non-rooted' ROM, if necessary.
Click to expand...
Click to collapse
Please explain how to do it on Windows 7.
Sense this device is tegra we can use nvflash to dump almost any kind of stuff from device, but my problem is that when i try to read or read raw from device nvflash hangs, on this weekend i will try and see what i can debug from usbmon and maybe then i will have some clue, until the only good way is to raw copy of block partitions like you mentioned
by the way if this helps this is what i get in my bct file (dumped with bct_dump for chromeos but worked for me)
Code:
Version = 0x00020001;
BlockSize = 0x00004000;
PageSize = 0x00000200;
PartitionSize = 0x01000000;
# Bootloader used = 1;
# Bootloaders max = 4;
# BCT size = 4080;
# Hash size = 16;
# Crypto offset = 16;
# Crypto length = 4064;
# Max BCT search blocks = 64;
#
# These values are set by cbootimage using the
# bootloader provided by the Bootloader=...
# configuration option.
#
# Bootloader[0].Version = 0x00000001;
# Bootloader[0].Start block = 224;
# Bootloader[0].Start page = 0;
# Bootloader[0].Length = 1345716;
# Bootloader[0].Load address = 0x00108000;
# Bootloader[0].Entry point = 0x00108000;
# Bootloader[0].Attributes = 0x00000004;
SDRAM[0].MemoryType = NvBootMemoryType_LpDdr2;
SDRAM[0].PllMChargePumpSetupControl = 0x00000008;
SDRAM[0].PllMLoopFilterSetupControl = 0x00000000;
SDRAM[0].PllMInputDivider = 0x0000001a;
SDRAM[0].PllMFeedbackDivider = 0x00000258;
SDRAM[0].PllMPostDivider = 0x00000000;
SDRAM[0].PllMStableTime = 0x0000012c;
SDRAM[0].EmcClockDivider = 0x00000001;
SDRAM[0].EmcAutoCalInterval = 0x00000000;
SDRAM[0].EmcAutoCalConfig = 0xe0a61111;
SDRAM[0].EmcAutoCalWait = 0x00000000;
SDRAM[0].EmcPinProgramWait = 0x00000000;
SDRAM[0].EmcRc = 0x00000012;
SDRAM[0].EmcRfc = 0x00000027;
SDRAM[0].EmcRas = 0x0000000d;
SDRAM[0].EmcRp = 0x00000006;
SDRAM[0].EmcR2w = 0x00000007;
SDRAM[0].EmcW2r = 0x00000005;
SDRAM[0].EmcR2p = 0x00000003;
SDRAM[0].EmcW2p = 0x0000000b;
SDRAM[0].EmcRrd = 0x00000003;
SDRAM[0].EmcRdRcd = 0x00000006;
SDRAM[0].EmcWrRcd = 0x00000006;
SDRAM[0].EmcRext = 0x00000003;
SDRAM[0].EmcWdv = 0x00000003;
SDRAM[0].EmcQUseExtra = 0x00000006;
SDRAM[0].EmcQUse = 0x00000007;
SDRAM[0].EmcQRst = 0x00000004;
SDRAM[0].EmcQSafe = 0x00000009;
SDRAM[0].EmcRdv = 0x0000000d;
SDRAM[0].EmcRefresh = 0x0000045f;
SDRAM[0].EmcBurstRefreshNum = 0x00000000;
SDRAM[0].EmcPdEx2Wr = 0x00000004;
SDRAM[0].EmcPdEx2Rd = 0x00000004;
SDRAM[0].EmcPChg2Pden = 0x00000006;
SDRAM[0].EmcAct2Pden = 0x00000008;
SDRAM[0].EmcAr2Pden = 0x00000001;
SDRAM[0].EmcRw2Pden = 0x0000000f;
SDRAM[0].EmcTxsr = 0x0000002a;
SDRAM[0].EmcTcke = 0x00000003;
SDRAM[0].EmcTfaw = 0x0000000f;
SDRAM[0].EmcTrpab = 0x00000007;
SDRAM[0].EmcTClkStable = 0x00000007;
SDRAM[0].EmcTClkStop = 0x00000002;
SDRAM[0].EmcTRefBw = 0x000004e1;
SDRAM[0].EmcFbioCfg1 = 0x00000000;
SDRAM[0].EmcFbioDqsibDlyMsb = 0x00000000;
SDRAM[0].EmcFbioDqsibDly = 0x2f2f2f2f;
SDRAM[0].EmcFbioQuseDlyMsb = 0x00000000;
SDRAM[0].EmcFbioQuseDly = 0x2f2f2f2f;
SDRAM[0].EmcFbioCfg5 = 0x00000282;
SDRAM[0].EmcFbioCfg6 = 0x00000002;
SDRAM[0].EmcFbioSpare = 0x00000000;
SDRAM[0].EmcMrsResetDllWait = 0x00000000;
SDRAM[0].EmcMrsResetDll = 0x00000000;
SDRAM[0].EmcMrsDdr2DllReset = 0x00000000;
SDRAM[0].EmcMrs = 0x00000000;
SDRAM[0].EmcEmrsEmr2 = 0x00000000;
SDRAM[0].EmcEmrsEmr3 = 0x00000000;
SDRAM[0].EmcEmrsDdr2DllEnable = 0x00000000;
SDRAM[0].EmcEmrsDdr2OcdCalib = 0x00000000;
SDRAM[0].EmcEmrs = 0x00000000;
SDRAM[0].EmcMrw1 = 0x0001008a;
SDRAM[0].EmcMrw2 = 0x00020004;
SDRAM[0].EmcMrw3 = 0x00030002;
SDRAM[0].EmcMrwResetCommand = 0x003f0000;
SDRAM[0].EmcMrwResetNInitWait = 0x0000000a;
SDRAM[0].EmcAdrCfg1 = 0x00070303;
SDRAM[0].EmcAdrCfg = 0x01070303;
SDRAM[0].McEmemCfg = 0x00100000;
SDRAM[0].McLowLatencyConfig = 0x80000003;
SDRAM[0].EmcCfg2 = 0x00000403;
SDRAM[0].EmcCfgDigDll = 0xe0000413;
SDRAM[0].EmcCfgClktrim0 = 0x00000000;
SDRAM[0].EmcCfgClktrim1 = 0x00000000;
SDRAM[0].EmcCfgClktrim2 = 0x00000000;
SDRAM[0].EmcCfg = 0x0001ff00;
SDRAM[0].EmcDbg = 0x01000020;
SDRAM[0].AhbArbitrationXbarCtrl = 0x00010000;
SDRAM[0].EmcDllXformDqs = 0x00000010;
SDRAM[0].EmcDllXformQUse = 0x00000008;
SDRAM[0].WarmBootWait = 0x00000001;
SDRAM[0].EmcCttTermCtrl = 0x00000802;
SDRAM[0].EmcOdtWrite = 0x00000000;
SDRAM[0].EmcOdtRead = 0x00000000;
SDRAM[0].EmcZcalRefCnt = 0x00000000;
SDRAM[0].EmcZcalWaitCnt = 0x0000001b;
SDRAM[0].EmcZcalMrwCmd = 0x000a0056;
SDRAM[0].EmcMrwZqInitDev0 = 0x800a00ff;
SDRAM[0].EmcMrwZqInitDev1 = 0x400a00ff;
SDRAM[0].EmcMrwZqInitWait = 0x00000001;
SDRAM[0].EmcDdr2Wait = 0x00000000;
SDRAM[0].PmcDdrPwr = 0x00000000;
SDRAM[0].ApbMiscGpXm2CfgAPadCtrl = 0x77ffc000;
SDRAM[0].ApbMiscGpXm2CfgCPadCtrl2 = 0x08080040;
SDRAM[0].ApbMiscGpXm2CfgCPadCtrl = 0x77fffff8;
SDRAM[0].ApbMiscGpXm2CfgDPadCtrl2 = 0x00000000;
SDRAM[0].ApbMiscGpXm2CfgDPadCtrl = 0x77fffff8;
SDRAM[0].ApbMiscGpXm2ClkCfgPadCtrl = 0x77ffc000;
SDRAM[0].ApbMiscGpXm2CompPadCtrl = 0x01f1f008;
SDRAM[0].ApbMiscGpXm2VttGenPadCtrl = 0x00005500;
---------- Post added at 02:13 AM ---------- Previous post was at 01:59 AM ----------
legion1911 said:
Please explain how.
Click to expand...
Click to collapse
I think by mounting this image like a loop device in linux and deleting unneeded files from what i know SGR uses ext4 file system
Welcome SPLESH!
1) Please give us a download link for the nvflash you use and let us know about your progress.
2) "I think by mounting this image like a loop device in linux and deleting unneeded files from what i know SGR uses ext4 file system"
I do not use linux. How I do it in windows?
---------- Post added at 04:40 AM ---------- Previous post was at 03:41 AM ----------
ardatdat said:
Let's discuss how we could dump out the kernel, ROMS, etc. from Galaxy R:
The following command would help to dump the kernel out (need su)
Code:
cat /dev/block/mmcblk0p9 > /sdcard/boot-i9103.img
The following command should help to dump the /system/ out (need su)
Code:
cat /dev/block/mmcblk0p2 > /sdcard/system-i9103.img
Click to expand...
Click to collapse
Nice. How I do that on Windows 7?
legion1911 said:
Please explain how to do it on Windows 7.
Click to expand...
Click to collapse
on Windows 7 How?
Hi
Ok I will look to find a way to extract and pack it back or at least modify image itself (I do not have Windows and I will have to install it in virtualBox)
Look in this thread about magiciso (rfs and maybe ext4):
http://forum.xda-developers.com/showthread.php?t=879569
And of cause Linux reader (I can not verify it with image but i used it for real PC disk partitions):
http://www.diskinternals.com/linux-reader/
About nvflash, this thread have much info about it (it is for G Tablet but work as well on SGR, or maybe not so well but i will research more on it):
http://forum.xda-developers.com/showthread.php?t=861950
---------- Post added at 10:27 AM ---------- Previous post was at 10:06 AM ----------
To put device into nvflash mod you need:
unplug USB cable
turn device off
remove battery
press VOL_UP and VOL_DOWN and hold them
insert USB cable
press HOME for 1-2 sec
press POWER
verify device (windows should detect new device, on linux run lsusb and see for Nvidia Inc device)
release POWER, HOME, and VOL keys
on Windows install APX driver from post, on Linux run lsusb and look for Nvidia Inc device remember ID XXXX:XXXX (first part is vendor and do not change) and create udev rule for it with this line: SUBSYSTEM=="usb", ATTR{idVendor}=="0955", ATTR{idProduct}=="7f20", MODE="0660", GROUP="plugdev"
now you can run nvflash --sync (with out bootloader) just to verify it can connect
SPLESH!
I am so glad you are in this forum.
Greetings to Crimea!
May be I need use nvflash with USB JIG to be able to operate it will make one and try to operate with it on this weekend and will share my results with you guys
Hi
Can some one who rooted device but did not changed stock kernel post output of after su:
adb shell cat /sys/firmware/fuse/odm_production_mode > odm_production_mode.txt
adb shell cat /sys/firmware/fuse/sec_boot_dev_cfg >
sec_boot_dev_cfg.txt
adb shell cat /sys/firmware/fuse/sec_boot_dev_sel > sec_boot_dev_sel.txt
and probably all content of /sys/firmware/fuse will be useful for my investigation
I understand that this may be different among devices but just for reference this info will be interesting to look at
Some thought about partitions layout
Code:
mmc0->cid=15010056414c30304d11593326177e00
mmc0->csd=d02701320f5903fff6dbffef8a404000
mmc0->name=VAL00M
mmc0->type=MMC
mmc0->oemid=0x0100
mmc0->serial=0x59332617
mmc0->manfid=0x000015
mmc0->preferred_erase_size=524288
mmc0->erase_size=524288
mmc0->date=07/2011
mmcblk0->dev=179:0
mmcblk0->range=8
mmcblk0->ext_range=255
mmcblk0->removable=0
mmcblk0->ro=0
mmcblk0->size=15104000
mmcblk0->alignment_offset=0
mmcblk0->discard_alignment=0
mmcblk0->capability=50
p0->size=??? /bct,/pt,/flags
p1->size=24576 /efs ~11Mb
p2->size=1228800 /system ~503Mb
p3->size=638976 /cache ~307Mb
p4->size=7865344 /sdcard ~3Gb
p5->size=4096 radio? ~2Mb
p6->size=4194304 /data ~1Gb
p7->size=32768 radio? ~15Mb
p8->size=10240 recavery ~5Mb
p9->size=16384 boot ~8Mb
p10->size=16384 hidden? ~8Mb
p11->size=1048576 factoryfs? ~500Mb
It is more than a month since I played with this, but if I remember correctly, p8 is recovery, p9 is boot.
These 2 partitions need special scripts to unzip. Check here:
Code:
http://android-dls.com/wiki/index.php?title=HOWTO:_Unpack%2C_Edit%2C_and_Re-Pack_Boot_Images
System partition is probably a standard Linux partition and is easy to mount on any Linux system.
I used dd to dump them, which essentially does the same thing as cat but with more options.
Yes you are correct and p5 and p7 are both radio related so the first 10 or so mb are for low level hboot/fastboot, partition table and etc
Sent from my GT-I9103 using XDA App
Sorry did not read the kernel code p5 is MISC partition
I lost ability to play with flash (some thing happend with VOL keys) it is good that i rooted it and instlled cwm just a day beffore (we had snow and ice no the road and I fail and paranty damedjed buttons) but I will continue to work on kernel until i will get it repared (new year, and etc)
SPLESH said:
I lost ability to play with flash (some thing happend with VOL keys) it is good that i rooted it and instlled cwm just a day beffore (we had snow and ice no the road and I fail and paranty damedjed buttons) but I will continue to work on kernel until i will get it repared (new year, and etc)
Click to expand...
Click to collapse
Did you open your device to check the electronics? Because I doubt you could damage the buttons permanently by software.
No i did it in more bad way also dameged side of device not so raw but this thin thing which they use for buttons is broken i did open it and removed broken pice of plastic and fexible pcb with buttons on it glad it at least work cause i was thinking it is it will have to replace this two parts
Sent from my GT-I9103 using XDA App
---------- Post added at 05:32 PM ---------- Previous post was at 05:11 PM ----------
This part "KEY FPCB-VOLUME KEY(GT-I9103) GH59-11005A" and plastic button part they should not cost much but it is little inconvenient for me now
SPLESH said:
Some thought about partitions layout
Code:
mmc0->cid=15010056414c30304d11593326177e00
mmc0->csd=d02701320f5903fff6dbffef8a404000
mmc0->name=VAL00M
mmc0->type=MMC
mmc0->oemid=0x0100
mmc0->serial=0x59332617
mmc0->manfid=0x000015
mmc0->preferred_erase_size=524288
mmc0->erase_size=524288
mmc0->date=07/2011
mmcblk0->dev=179:0
mmcblk0->range=8
mmcblk0->ext_range=255
mmcblk0->removable=0
mmcblk0->ro=0
mmcblk0->size=15104000
mmcblk0->alignment_offset=0
mmcblk0->discard_alignment=0
mmcblk0->capability=50
p0->size=??? /bct,/pt,/flags
p1->size=24576 /efs ~11Mb
p2->size=1228800 /system ~503Mb
p3->size=638976 /cache ~307Mb
p4->size=7865344 /sdcard ~3Gb
p5->size=4096 radio? ~2Mb
p6->size=4194304 /data ~1Gb
p7->size=32768 radio? ~15Mb
p8->size=10240 recavery ~5Mb
p9->size=16384 boot ~8Mb
p10->size=16384 hidden? ~8Mb
p11->size=1048576 factoryfs? ~500Mb
Click to expand...
Click to collapse
If I use this for BoardConfig.mk , how can I convert the sizes to hex values/bytes ?
EmoBoiix3 said:
If I use this for BoardConfig.mk , how can I convert the sizes to hex values/bytes ?
Click to expand...
Click to collapse
this values are taken from:
Code:
/sys/devices/platform/sdhci-tegra.3/mmc_host/mmc0/mmc0:0001/block/mmcblk0
Code:
adb shell cat /sys/devices/platform/sdhci-tegra.3/mmc_host/mmc0/mmc0:0001/block/mmcblk0/mmcblk0p*/size
And this sizes is in blocks, 2048 byte each.

[KERNEL] [DEV] MTK6573 kernel improvement effort

There are a number of chinese dual sim phones using the chipset MTK6573
Unfortunately the manufacturer has chosen to be very secretive about the kernel and
1) Has not published the source code
2) Has not included the kernel .config file in the compilation
3) Has not compiled ext2, ext3 or ext4 support in the kernel
In an effort to overcome some of those limitations I have gathered the exact same version of the android kernel used in current roms (2.6.35.7) and tried to come up with a configuraration that produces modules (.ko) that can be loaded and used from MTK6573 based devices.
Instructions for compiling the kernel:
Pre-requirements:
a) check with uname -a in your device that the kernel version is 2.6.35.7
b) Download this file with the kernel source and the arm toolchain:
http://www.ziddu.com/download/18628468/androidkernelANDtoolchain.rar.html
1) Unpack the .rar file and extract the toolchain to your home folder
2) Extract the kernel sources somewhere you like
3) Open a bash terminal and cd into the folder containing the kernel source
4 ) make -j8 ARCH=arm menuconfig
That should open a menu and you will be able to modify options, the chosen system is a qualcom MSM as this is the closest thing I could find to the MTK6573
5) Compile with:
make -j8 ARCH=arm CROSS_COMPILE=~/code/distro/kernel/arm-2011.03/bin/arm-none-eabi-
6) to test the ext2.ko module
adb push fs/ext2/ext2.ko /data/local/
adb shell
insmod /data/local/ext2/ko
7) Try to mount an ext2 partition
We are really trying to overcome this situation and all the help is appreciated.
So far all the ext2.ko modules built can be loaded without any error, but as soon as the mount command is issued the phone immediately reboots. I can't even log anything. Any ideas?
EDIT:
Code:
lsmod
pvrsrvkm 151229 29 mtklfb, Live 0xbf000000
mtklfb 11329 0 - Live 0xbf033000
mtk_drvb 8436 0 - Live 0xbf03c000 (P)
lca_core 2706 0 - Live 0xbf044000 (P)
mtk_stp_core 211207 5 mt6620_fm_drv,mtk_stp_bt,mtk_stp_gps,mtk_stp_wmt,mtk_stp_u
art, Live 0xbf04a000 (P)
mtk_stp_uart 20598 1 - Live 0xbf087000 (P)
mtk_hif_sdio 10961 2 wlan,mtk_stp_wmt, Live 0xbf092000
mtk_stp_wmt 88860 6 wlan,mtk_fm_priv,mt6620_fm_drv,mtk_stp_bt,mtk_stp_gps, Live
0xbf09b000 (P)
mtk_stp_gps 37165 0 - Live 0xbf0ba000
mtk_stp_bt 39581 1 - Live 0xbf0c9000
mt6620_fm_drv 99803 1 mtk_fm_priv, Live 0xbf0d8000
mtk_fm_priv 7205 0 - Live 0xbf0f9000 (P)
wlan 255235 2 - Live 0xbf100000 (P)
ext2 44907 0 [permanent], Live 0xbf154000
ccci 195306 18 sec,ccmni, Live 0xbf167000 (P)
ccmni 16270 0 - Live 0xbf1a4000 (P)
mt6573_m4u 62946 0 - Live 0xbf1ae000 (P)
mt6573_mfv_kernel_driver 341502 0 - Live 0xbf1c5000 (P)
sec 52226 0 - Live 0xbf21f000 (P)
xlog 89315 24 - Live 0xbf233000 (P)
As you can see, ext2 module is loaded and cat /proc/filesystems confirms:
Code:
cat /proc/filesystems
nodev sysfs
nodev rootfs
nodev bdev
nodev proc
nodev tmpfs
nodev sockfs
nodev pipefs
nodev anon_inodefs
nodev devpts
nodev ramfs
vfat
msdos
yaffs
yaffs2
nodev mqueue
nodev mtd_inodefs
ext2
/sd-ext is created and the mount command that I'm issuing is:
Code:
busybox mount -r -w -t ext2 /dev/block/mmcblk0p2 /sd-ext
I think the memory allocation is using something non-standard, perhaps the kernel for the mtk6516 is similar enough...
http://groups.google.com/group/mt6516-linux/browse_thread/thread/2b6896ce22570932
I tried this, but unsuccessful.
/data/local # insmod ext3.ko
insmod: can't insert 'ext3.ko': invalid module format
/data/local # insmod ext2.ko
insmod: can't insert 'ext2.ko': invalid module format
/data/local # insmod ext4.ko
insmod: can't insert 'ext4.ko': invalid module format
You could provide the modules compiled for us?
The kernel also does not support swap.
Thank you.
kindly post the output of (after trying insmod ext2.ko )
dmesg
and
uname -a
riystetyt said:
I tried this, but unsuccessful.
/data/local # insmod ext3.ko
insmod: can't insert 'ext3.ko': invalid module format
/data/local # insmod ext2.ko
insmod: can't insert 'ext2.ko': invalid module format
/data/local # insmod ext4.ko
insmod: can't insert 'ext4.ko': invalid module format
You could provide the modules compiled for us?
The kernel also does not support swap.
Thank you.
Click to expand...
Click to collapse
Hello, thanks for your quick answer!
Errors for ext2.ko in dmesg:
[30005.453739] ext2: Unknown symbol kmalloc_caches (err 0)
[30005.454575] [17976:insmod] sig 17 to [11249:sh]
uname -a:
/data/local # uname -a
Linux localhost 2.6.35.7 #1 PREEMPT Mon Jan 9 16:05:35 CST 2012 armv6l GNU/Linux
Thanks for your help!
Is this the ext2.ko module you are trying to load?
ls -l /system/lib/modules/ext2.ko
-rw-r--r-- root root 756026 2012-05-02 18:20 ext2.ko
Hello, I get the ext2.ko in your post on eten-users. Works like a charm! I had only about 8MB free and now with your module and Link2sd has 120MB. Thanks!
Glad it helps you.
In truth I don´t know what mediatek were thinking when they released an android kernel with so little nand storage space and no ext2 support.
Hex Freq Value MTK CPU
Code:
0x68t
0xdft
0x41t
0xd8t
0xeat
0xf8t
0x91t
0x7t
0x19t
0x27t
0x64t
0xf1t
0x93t
0xedt
0x21t
0x59t
0x6ft
0x1t
0x83t
0x39t
Could you please post the ext2.ko that works with the 2.6.35.7? The one that riystetyt points.
You can download it from one of my G11i Pro or HD7 ROMs (check my signature).
Great, checking now.
Did you try compiling zram for the mtk6573?
---------- Post added at 04:12 PM ---------- Previous post was at 03:24 PM ----------
By the way, how did you solve the "invalid module format" issue?
Thanks for your replies
build <drivers> error 2
Where i miss?
@casacristo
Any updates on the compressed swap? I can help testing
My phone has the 2.6.35.7 kernel mt6573
I tried to download the .rar from eten-users but the dropbox link is broken.
Thanks...
casacristo?
bump
Why don't you ask him via PM instead of doing bumps? Probably he's busy to look at this thread...
maybe its help?
http://www.pudn.com/downloads391/doc/comm/detail1673271.html
Thanks for the suggestion but tried sending a private sms to casacristo with no luck.
Sadly I also found that if the kernel does not support swap, swap can't be loaded as a module, so we can't compile a swap module.
The page provided has the datasheet which as far as I know has the technical specs of the mt6573 processor, not the kernel, but I hope there is something there that can be used to compile a custom kernel.
---------- Post added at 10:06 AM ---------- Previous post was at 10:01 AM ----------
Hey just found this: what does it mean? the guy who posted this has the source?
================================================================================================
drivers debug
-------------------------------------------------------------------------------------------------------------
board_init
-------------------------------------------------------------------------------------------------------------
/mediatek/platform/mt6573/kernel/core/mt6573_devs.c
所有的驱动名对应的设备名都可以在这里找到!
-------------------------------------------------------------------------------------------------------------
lcd
-------------------------------------------------------------------------------------------------------------
/mediatek/custom/common/uboot/lcm
/mediatek/custom/common/kernel/lcm
CUSTOM_UBOOT_LCM = ili9481_dpi
***********************************************************
LCM_WIDTH = 320
LCM_HEIGHT = 480
CUSTOM_UBOOT_LCM = ili9481_dpi
CUSTOM_KERNEL_LCM = ili9481_dpi
***********************************************************
-------------------------------------------------------------------------------------------------------------
camera
-------------------------------------------------------------------------------------------------------------
kernel
/mediatek/custom/common/kernel/imgsensor/src
kd_imgsensor.h
kd_sensorlist.h
hal
/mediatek/custom/common/hal/imgsensor/
sensorlist.cpp
MTKCameraHardware.cpp
***********************************************************
CUSTOM_HAL_CAMERA = camera
CUSTOM_HAL_IMGSENSOR = gc2015_yuv
CUSTOM_KERNEL_IMGSENSOR = gc2015_yuv
CUSTOM_HAL_MAIN_IMGSENSOR = gc2015_yuv
CUSTOM_KERNEL_MAIN_IMGSENSOR = gc2015_yuv
***********************************************************
-------------------------------------------------------------------------------------------------------------
TouchPanel
-------------------------------------------------------------------------------------------------------------
/mediatek/custom/common/kernel/touchpanel/src/mtk_tpd.c
tpd_driver_add(&tpd_device_driver);
platform_driver_unregister(&tpd_driver);
***********************************************************
CUSTOM_KERNEL_TOUCHPANEL = COMM
# default settings: generic
# candidate settings: generic;eeti_pcap7200
# select the panel used by certain project.
***********************************************************
-------------------------------------------------------------------------------------------------------------
flash
-------------------------------------------------------------------------------------------------------------
CUSTOM_MEMORY_HDR = mediatek/custom/$(PROJECT)/preloader/inc/custom_MemoryDevice.h
CUSTOM_NAND_HDR = mediatek/custom/$(PROJECT)/common/nand_device_list.h
MEMORY_DEVICE_XLS = mediatek/build/tools/emigen/$(MTK_PLATFORM)/MemoryDeviceList_$(MTK_PLATFORM).xls
-------------------------------------------------------------------------------------------------------------
GPIO_config
-------------------------------------------------------------------------------------------------------------
./mediatek/build/makemtk.mk +294
drvgen:
ifneq ($(PROJECT),generic)
$(hide) echo $(SHOWTIME) [email protected]
$(hide) echo -e \\t\\t\\t\\b\\b\\b\\bLOG: $(S_LOG)[email protected]
$(hide) mediatek/source/dct/DrvGen mediatek/custom/$(PROJECT)/kernel/dct/dct/codegen.dws $(DEAL_STDOUT_DRVGEN) && \
$(SHOWRSLT) $$? $(LOG)[email protected] || \
$(SHOWRSLT) $$? $(LOG)[email protected]
endif
*********************************************
mediatek/source/dct/DrvGen
mediatek/custom/$(PROJECT)/kernel/dct/dct/codegen.dws
*********************************************
-------------------------------------------------------------------------------------------------------------
G-sensor
-------------------------------------------------------------------------------------------------------------
int hwmsen_gsensor_add(struct sensor_init_info* obj)
/mediatek/custom/common/kernel/accelerometer/auto/
/mediatek/config/mtk/ProjectConfig.mk:188:MTK_SENSOR_SUPPORT = yes
# Android sensor device
MTK_SENSOR_SUPPORT = yes
CUSTOM_KERNEL_MAGNETOMETER =
#akm8962
#akm8975
#auto for detcet by lilingyun
CUSTOM_KERNEL_ACCELEROMETER = auto
CUSTOM_KERNEL_ALSPS = tmd2771
CUSTOM_KERNEL_BAROMETER =
CUSTOM_KERNEL_GYROSCOPE =
#l3g4200d
#if defined(MTK_AUTO_DETECT_ACCELEROMETER)
/mediatek/source/kernel/drivers/hwmon/hwmsen/Hwmsen_dev.c
********************************************
#auto for detcet by lilingyun
CUSTOM_KERNEL_ACCELEROMETER = auto
*******************************************
-------------------------------------------------------------------------------------------------------------
compass
-------------------------------------------------------------------------------------------------------------
mediatek/custom/common/kernel/magnetometer/akm8962/akm8962.c
mediatek/custom/tm100/kernel/magnetometer/akm8962/cust_mag.c
*********************************************
CUSTOM_KERNEL_MAGNETOMETER =
#akm8962
#akm8975
********************************************
-------------------------------------------------------------------------------------------------------------
ALS/PS 光感 接近传感器
-------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_ALSPS = tmd2771
*********************************************
mediatek/custom/common/kernel/alsps/tmd2771/tmd2771.c
mediatek/custom/common/kernel/alsps/tmd2771/tmd2771.h
mediatek/custom/tm100/kernel/alsps/tmd2771/cust_alsps.c
-------------------------------------------------------------------------------------------------------------
GYRO-sensor motion sensor 陀螺仪
-------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_GYROSCOPE =
#l3g4200d
*********************************************
mediatek/custom/common/kernel/gyroscope/l3g4200d/l3g4200d.c
mediatek/custom/tm100/kernel/gyroscope/l3g4200d/cust_gyro.c
-------------------------------------------------------------------------------------------------------------
BAROMETER-sensor 气压计
-------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_BAROMETER =
#ms5607
*********************************************
mediatek/custom/tm100/kernel/barometer/ms5607/cust_baro.c
mediatek/custom/common/kernel/barometer/ms5607/ms5607.c
------------------------------------------------------------------------------------------------------------
flashlight
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_HAL_FLASHLIGHT = dummy_flashlight
CUSTOM_KERNEL_FLASHLIGHT = dummy_flashlight
*********************************************
mediatek/custom/common/kernel/flashlight/dummy_flashlight/dummy_flashlight.c
mediatek/custom/common/kernel/flashlight/src/kd_flashlightlist.c
------------------------------------------------------------------------------------------------------------
jogball
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_JOGBALL =
*********************************************
mediatek/custom/common/kernel/jogball/
------------------------------------------------------------------------------------------------------------
leds
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_LEDS = mt65xx
*********************************************
mediatek/custom/common/kernel/leds
------------------------------------------------------------------------------------------------------------
matv
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_HAL_MATV =
CUSTOM_KERNEL_MATV =
HAVE_MATV_FEATURE = no
*********************************************
mediatek/custom/common/kernel/matv/mt5193/matv.c
------------------------------------------------------------------------------------------------------------
sound
------------------------------------------------------------------------------------------------------------
*********************************************
MTK_SOUNDRECORDER_APP = yes
CUSTOM_KERNEL_SOUND = speaker
*********************************************
mediatek/custom/common/kernel/sound/inc/yusu_android_speaker.h
mediatek/custom/tm100/kernel/sound/speaker/yusu_android_speaker.c
------------------------------------------------------------------------------------------------------------
USB
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_USB = mt6573
*********************************************
mediatek/custom/common/kernel/usb/src/Makefile
mediatek/custom/mt6573/kernel/usb/src/mtk_usb_custom.c
mediatek/custom/mt6573/kernel/usb/src/mtk_usb_custom.h
mediatek/custom/mt6573/uboot/inc/cust_sdc.h
mediatek/platform/mt6573/kernel/drivers/usb-gadget/
mediatek/platform/mt6573/kernel/drivers/power/
------------------------------------------------------------------------------------------------------------
BT
------------------------------------------------------------------------------------------------------------
*********************************************
MTK_WLAN_CHIP = MT6620
# candidate settings: MT6620
MTK_BT_CHIP = MTK_MT6620
# candidate settings: MTK_MT6611/MTK_MT6612/MTK_MT6616/MTK_MT6620
MTK_WLAN_SUPPORT = yes
MTK_BT_SUPPORT = yes
MTK_WLAN_SUPPORT = yes
MTK_WLANBT_SINGLEANT = no
MTK_BT_30_HS_SUPPORT = yes
####config BT feature###########
# please do not modify these options
MTK_BT_21_SUPPORT = yes
MTK_BT_30_SUPPORT = yes
MTK_BT_40_SUPPORT = yes
MTK_BT_FM_OVER_BT_VIA_CONTROLLER = yes
MTK_BT_PROFILE_OPP = yes
MTK_BT_PROFILE_SIMAP = yes
MTK_BT_PROFILE_PRXM = yes
MTK_BT_PROFILE_PRXR = yes
MTK_BT_PROFILE_HIDH = yes
MTK_BT_PROFILE_FTP = yes
MTK_BT_PROFILE_PBAP = yes
MTK_BT_PROFILE_MANAGER = yes
MTK_BT_PROFILE_BPP = yes
MTK_BT_PROFILE_BIP = yes
MTK_BT_PROFILE_DUN = yes
MTK_BT_PROFILE_PAN = yes
MTK_BT_PROFILE_HFP = yes
MTK_BT_PROFILE_A2DP = yes
MTK_BT_PROFILE_AVRCP = yes
MTK_BT_PROFILE_AVRCP14 = yes
MTK_BT_PROFILE_TIMEC = no
MTK_BT_PROFILE_TIMES = no
MTK_BT_PROFILE_MAPS = no
MTK_BT_PROFILE_MAPC = no
MTK_BT_PROFILE_SPP = yes
####config BT feature end ####
*********************************************
mediatek/custom/common/kernel/btwlanem/btwlanem/btwlanem.c
------------------------------------------------------------------------------------------------------------
EEPROM
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_HAL_EEPROM = dummy_eeprom
CUSTOM_KERNEL_EEPROM = dummy_eeprom
*********************************************
mediatek/custom/common/kernel/eeprom/dummy_eeprom/dummy_eeprom.c
------------------------------------------------------------------------------------------------------------
FM
------------------------------------------------------------------------------------------------------------
*********************************************
MTK_FM_CHIP = MT6620_FM
MTK_FM_SUPPORT = yes
MTK_FM_TX_SUPPORT = yes
MTK_FM_AUDIO = FM_ANALOG_INPUT
#FM_DIGITAL_INPUT
*********************************************
mediatek/custom/common/kernel/fm/mt6620/dummy.c
------------------------------------------------------------------------------------------------------------
voice coil motor driver
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_HAL_LENS = dummy_lens dummy_lens
CUSTOM_KERNEL_LENS = dummy_lens dummy_lens
CUSTOM_HAL_MAIN_LENS = dummy_lens
CUSTOM_HAL_MAIN_BACKUP_LENS =
CUSTOM_HAL_SUB_LENS = dummy_lens
CUSTOM_HAL_SUB_BACKUP_LENS =
CUSTOM_KERNEL_MAIN_LENS = dummy_lens
CUSTOM_KERNEL_MAIN_BACKUP_LENS =
CUSTOM_KERNEL_SUB_LENS = dummy_lens
CUSTOM_KERNEL_SUB_BACKUP_LENS =
*********************************************
mediatek/custom/common/kernel/lens/dummy_lens/dummy_lens.c
------------------------------------------------------------------------------------------------------------
OFN
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_OFN = ofn1090
*********************************************
mediatek/custom/common/kernel/ofn/inc
mediatek/custom/tm100/kernel/ofn/ofn1090/cust_ofn.c
------------------------------------------------------------------------------------------------------------
wifi
-----------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_WIFI =
MTK_SCREEN_OFF_WIFI_OFF = no
MTK_WIFI_P2P_SUPPORT = yes
MTK_WIFI_HOTSPOT_SUPPORT = yes
*********************************************
mediatek/custom/common/kernel/wifi/mt592x/dummy.c
------------------------------------------------------------------------------------------------------------
HEADSET
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_HEADSET = accdet
MTK_HEADSET_ICON_SUPPORT = yes
*********************************************
mediatek/custom/tm100/kernel/headset/accdet/accdet_custom.h
------------------------------------------------------------------------------------------------------------
board 配置与分区信息
------------------------------------------------------------------------------------------------------------
*********************************************
*********************************************
mediatek/custom/tm100/kernel/core/src/board.c
mediatek/custom/tm100/kernel/core/src/partition.c
------------------------------------------------------------------------------------------------------------
PM
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_BATTERY = battery
*********************************************
mediatek/custom/tm100/kernel/battery/battery/cust_battery.h
mediatek/custom/tm100/kernel/battery/battery/custom_fuel_gauge.h
mediatek/platform/mt6573/kernel/drivers/power/mt6573_battery.c
------------------------------------------------------------------------------------------------------------
RTC
------------------------------------------------------------------------------------------------------------
*********************************************
CUSTOM_KERNEL_RTC = rtc
# default settings: rtc
# candidate settings: rtc
# For RTC
*********************************************
mediatek/custom/tm100/kernel/rtc/rtc/rtc-mt6573.h
mediatek/platform/mt6573/kernel/drivers/rtc/mtk_rtc.c

mkbootimg created boot.img creation discrepenacy

Hi,
I have noticed a discrepancy which I am unable to understand and appreciate if someone can provide a clarification in case they have noticed the same issue. I tried to split (using unmkbootimg) boot.img (from Xiaomi Mi MAX update ROMs) and merged it back (using mkbootimg) and found that the newly made boot.img was smaller by 1354 bytes. Appreciate your reply if I am missing anything.
% ls -l boot.img ../boot.img
-rw-rw-r-- 1 skanduru skanduru 12924234 Jan 1 2009 ../boot.img
-rw-rw-r-- 1 skanduru skanduru 12922880 Jan 15 01:07 boot_new.img
% cat output.txt
# kernel written to 'kernel' (10172221 bytes)
# ramdisk written to 'ramdisk.cpio.gz' (2746601 bytes)
# To rebuild this boot image, you can use the command:
mkbootimg --base 0 --pagesize 2048 --kernel_offset 0x80008000 --ramdisk_offset 0x81000000 --second_offset 0x80f00000 --tags_offset 0x80000100 --cmdline
'console=ttyHSL0,115200,n8 androidboot.console=ttyHSL0 androidboot.hardware=qcom msm_rtb.filter=0x237 ehci-hcd.park=3 androidboot.bootdevice=7824900.sdhci
lpm_levels.sleep_disabled=1 earlyprintk ramoops_memreserve=4M' --kernel kernel --ramdisk ramdisk.cpio.gz -o boot_new.img
A bindiff of the two images shows that the original boot.img has some stuff (1354 bytes) appended at the bottom which makes the difference. The net result is the boot_new.img doesn't boot up. Just wondering if someone has seen this issue.
boot image to try
The link to boot.img image to try out mkbootimg issue. We can see that @C53000, the original boot.img has extra stuff (1374 bytes).
Image can be downloaded from (Couldn't update it in the previous query)
s000 DOT tinyupload DOT com/?file_id=42124441031490820660
skanduru said:
The link to boot.img image to try out mkbootimg issue. We can see that @C53000, the original boot.img has extra stuff (1374 bytes).
Image can be downloaded from (Couldn't update it in the previous query)
s000 DOT tinyupload DOT com/?file_id=42124441031490820660
Click to expand...
Click to collapse
Could be an issue with Xiaomi image as it doesn't specify second_bootloader size, but appends it. Tried this change and it works. Not sure if it might be the case for potentially other manufacturer's boot.img. Posting it if it could be of some use.
--- a/mkbootimg/unmkbootimg.c
+++ b/mkbootimg/unmkbootimg.c
@@ -80,6 +80,30 @@ int usage(void)
return 1;
}
+int maybe_fix_second_image_size(boot_img_hdr *hdr, void *file_data)
+{
+ int offset = ((hdr->kernel_size + hdr->ramdisk_size
+ + 2*hdr->page_size - 1) / hdr->page_size) * hdr->page_size;
+ char *second_image = ((char *)file_data + offset);
+ u_int16_t *s = (u_int16_t *) second_image;
+ int is_second_image_true = 0;
+
+ if (s[0]) {
+ /*
+ * Second_image does exist ! Calculate the size and fix the
+ * size in hdr.
+ */
+ int size = 0;
+ while (s[0]) {
+ size += 2;
+ s++;
+ }
+ hdr->second_size = size;
+ is_second_image_true = 1;
+ }
+ return is_second_image_true;
+}
+
int main(int argc, char **argv)
{
void *file_data = 0;
@@ -160,7 +184,13 @@ int main(int argc, char **argv)
hdr->ramdisk_size);
}
- if(hdr->second_size != 0) {
+ /*
+ * Even though the second_size is 0, some vendors may place secondary
+ * image there, for ex. Xiaomi. In such a case do calculate the size
+ * based on termination with a null.
+ * XXX: Temp fix.
+ */
+ if(hdr->second_size != 0 || maybe_fix_second_image_size(hdr, file_data)) {
offset = ((hdr->kernel_size + hdr->ramdisk_size
+ 2*hdr->page_size - 1) / hdr->page_size) * hdr->page_size;
if (save_file(second_fn, &((char *)file_data)[offset],

BlueStacks ADB HELP, please & TY

Code:
local $results, $h, $PID, $BlueStacks_Path
$BlueStacks_Path = @ProgramFilesDir & "\BlueStacks\"
$BlueStacks_Path = StringReplace($BlueStacks_Path, "\\", "\")
$h = Run($BlueStacks_Path & "hd-Adb connect localhost","","",$STDIO_INHERIT_PARENT)
sleep(1000)
$PID = run($BlueStacks_Path & "HD-Frontend.exe Testing")
WinGetProcess($PID)
sleep(1000)
Do
$result = run($BlueStacks_Path & "HD-Adb shell getprop sys.boot_completed", "", "", BitOR($STDIN_CHILD, $STDERR_MERGED))
ConsoleWrite("$result: " & $result & @CRLF)
sleep(1000)
until $result = 1
Hi ALL, I am really knew at this and I am trying to figure out why I get an infinite loop when I am checking to see if BlueStacks is open.
If I do everything command line based, everything WORKS as above, but when I put it in AutoIT it just LOOPS & LOOPS & LOOPS. When I do the consolewrite, it's like it is giving me a PID# rather than return 1.
What am I doing wrong?

Categories

Resources