Latest product reviews
ARCHOS 50 Diamond
ARCHOS GamePad2
ARCHOS
Smartphones
ARCHOS
TV Connect
ARCHOS 101 XS

A A A
Avatar

Please consider registering
Guest

Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

Register Lost password?

ClockworkMod (CWM) Recovery easy install for RK3066 and RK3188 -- TWRP/CWM Flash-Tool and root for RK3288

 Please donate to support OMA and CrewRKTablets firmware work, thank you !

sp_Feed sp_TopicIcon
Updating TrekStor Ventos 10.1 (ST10216-2A) to Android 4.4?
Any way to update this device to a more recent ROM/kernel/Android version?
Avatar
ri9000

Contributor
Forum Posts: 29
Member Since:
2014/09/07
sp_UserOfflineSmall Offline

Thanks Received: 7
106
2015/03/14 - 04:35
sp_Permalink sp_Print

it was a pleasure following this development to a successful conclusion.

well done everyone!

Awl, now you just have to come back and get a 3036 kernel running! SmileSmile

Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
107
2015/03/14 - 15:06
sp_Permalink sp_Print

Unfortunately, it's not over yet even for CM 10.1: Yell

I did not realize at first that proper battery support is still missing:

Settings - Battery tells me that "Battery usage data isn't available", and also battery life time is short and cannot be improved by any battery saver apps, probably because battery framework/kernel integration is missing.

It looks like even though the Ventos clearly is an RK30 board, the Trekstor stock kernel provides RK29-style of battery drivers/integration:

root@android:/ # find . -name "*battery*"
./sys/devices/platform/rk2918-battery
./sys/devices/platform/rk2918-battery/power_supply/battery
./sys/bus/platform/devices/rk2918-battery
./sys/bus/platform/drivers/rk2918-battery
./sys/bus/platform/drivers/rk2918-battery/rk2918-battery
./sys/class/power_supply/battery
./sys/module/rk29_adc_battery
./proc/irq/325/rk29_adc_battery

@Oma/Jochen:

As it looks like the CM 10.1 for RK30 expects battery device names with "rk30" in their names, I am wondering whether this battery fix for the RK29 CM10.1 build:

http://crewrktablets.arctablet.com/?wpfb_dl=1055

might be a valid starting point? Unfortunately, even this fix seems to rely on a file named

/sys/devices/platform/rk2918-battery/startget

which I don't have at all... Frown

Am I on the right track? Do you have any further hints/tips for me how to fix this?

I don't have much time at the moment, but I'll try to look into this (how do things look like with the stock 4.1.1 kernel?) tomorrow...

Thanks again & best regards,

awl

Avatar
ri9000

Contributor
Forum Posts: 29
Member Since:
2014/09/07
sp_UserOfflineSmall Offline

Thanks Received: 7
108
2015/03/14 - 23:28
sp_Permalink sp_Print sp_EditHistory

i2c driver?

..or i could be completely off track here..but in one rom I saw this in "power_profile.xml":

<?xml version="1.0" encoding="utf-8"?>
<device name="Android">
<item name="none">0</item>
<item name="screen.on">0.1</item>
<item name="bluetooth.active">0.1</item>
<item name="bluetooth.on">0.1</item>
<item name="screen.full">0.1</item>
<item name="wifi.on">0.1</item>
<item name="wifi.active">0.1</item>
<item name="wifi.scan">0.1</item>
<item name="dsp.audio">0.1</item>
<item name="dsp.video">0.1</item>
<item name="radio.active">1</item>
<item name="radio.scanning">0.5</item>
<item name="gps.on">1</item>
<array name="radio.on">
<value>0.2</value>
<value>0.1</value>
</array>
<array name="cpu.speeds">
<value>400000</value>
</array>
<item name="cpu.idle">0.1</item>
<array name="cpu.active">
<value>0.2</value>
</array>
<item name="battery.capacity">1000</item>
</device>

.....................

these values gave meaningless battery stats until I populated with sane values.

hope this is of use.

The following users say thank you to ri9000 for this useful post:

awl
Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
109
2015/03/16 - 11:00
sp_Permalink sp_Print

Hello Oma,

hmm - with the battery fix for the RK29 CM10.1 build linked above:

http://crewrktablets.arctablet.com/?wpfb_dl=1055

things seem a little better: I can now see the file

/data/system/batterystats.bin

is being written and continuously updated, but nevertheless the Android "Settings" app seems unable to display this information in the "Battery" submenu: "Battery usage data isn't available".

Battery load level is displayed properly, and when I tap on the battery graph, I also get some information.

Please see the screenshots attached below for more information.

I have tried to look for the part of the Android codebase that is responsible for displaying the error message "Battery usage data isn't available", but so far, have been unable to locate it.

dmesg and logcat output are as follows:

root@android:/ # dmesg | grep -i batt
<4>[    2.785436] rk29_adc_battery_probe--1150:
<4>[    2.789489] rk29_adc_battery_lowpower_check--1078:
<6>[    3.100211] rk29_adc_battery: driver initialized
<4>[    7.528176] battery: load capacity<82> from /data/bat_last_capacity.dat
<4>[  131.056123] battery: load capacity<81> from /data/bat_last_capacity.dat
<4>[  176.135319] battery: load capacity<80> from /data/bat_last_capacity.dat
<4>[  510.935271] battery: load capacity<79> from /data/bat_last_capacity.dat
<4>[  679.245274] battery: load capacity<78> from /data/bat_last_capacity.dat
<4>[  891.805253] battery: load capacity<77> from /data/bat_last_capacity.dat
<4>[ 1012.465288] battery: load capacity<76> from /data/bat_last_capacity.dat
<4>[ 1093.425252] battery: load capacity<75> from /data/bat_last_capacity.dat
<4>[ 1190.385222] battery: load capacity<74> from /data/bat_last_capacity.dat
<4>[ 1572.256178] battery: load capacity<73> from /data/bat_last_capacity.dat
<4>[ 1768.075245] battery: load capacity<72> from /data/bat_last_capacity.dat
<4>[ 1960.185232] battery: load capacity<71> from /data/bat_last_capacity.dat
<4>[ 2181.905203] battery: load capacity<70> from /data/bat_last_capacity.dat
<4>[ 2387.626727] battery: load capacity<69> from /data/bat_last_capacity.dat
<4>[ 2951.815218] battery: load capacity<68> from /data/bat_last_capacity.dat
<4>[ 2996.914936] battery: load capacity<67> from /data/bat_last_capacity.dat
<4>[ 3098.115035] battery: load capacity<67> from /data/bat_last_capacity.dat
<4>[ 3711.754998] battery: load capacity<67> from /data/bat_last_capacity.dat
<4>[ 3736.635500] battery: load capacity<67> from /data/bat_last_capacity.dat
<4>[ 4085.445269] battery: load capacity<68> from /data/bat_last_capacity.dat
<4>[ 4207.105201] battery: load capacity<69> from /data/bat_last_capacity.dat

root@android:/ # logcat | grep -i batt
I/SystemServer(  419): Battery Service
I/ActivityManager(  419): Start proc com.google.android.apps.uploader for broadcast com.google.android.apps.uploader/com.google.android.picasasync.BatteryReceiver: pid=845 uid=10012 gids={50012, 3003, 1015, 1023, 1028}
I/ActivityManager(  419): Start proc com.google.android.gms for broadcast com.google.android.gms/com.google.android.libraries.social.autobackup.AutoBackupEnvironment$BatteryReceiver: pid=900 uid=10000 gids={50000, 3003, 1007, 1028, 1015, 1023, 1006, 3002, 3001, 2001, 3006}
W/BroadcastQueue(  419): Failure sending broadcast Intent { act=android.intent.action.BATTERY_CHANGED flg=0x60000010 (has extras) }
E/Lights  (  419): write_int failed to open sys/class/leds/battery_led/brightness
I/ActivityManager(  419): Start proc com.google.android.apps.uploader for broadcast com.google.android.apps.uploader/com.google.android.picasasync.BatteryReceiver: pid=2949 uid=10012 gids={50012, 3003, 1015, 1023, 1028}
I/iu.Environment(  900): update battery state; isPlugged? true*
D/PicasaUploader( 2949):    syncOnBattery changed to true

Any ideas?

Thanks again & best regards,

awl

 

Settings-Battery.pngImage EnlargerSettings-Battery-History-details.pngImage Enlarger


Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
110
2015/03/16 - 11:14
sp_Permalink sp_Print

Just noticed something else that does not seem right when I read https://source.android.com/devices/tech/power.html:

root@android:/ # dumpsys batterystats
Can't find service: batterystats

Does this mean that this "batterystats" service has exited/crashed on my tab?

Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
111
2015/03/16 - 12:48
sp_Permalink sp_Print

Regarding #110:

Just found out that the service name only is "batterystats" in Android versions starting from KitKat, so before this in CM10.1 the correct service name is "batteryinfo".

And indeed, "dumpsys batteryinfo" returns a large text file of about 60kB full of "interesting" information, so this service seems to be running properly...

Looks like this boils down to the question why the code in Settings.apk seems unable to display the batteryinfo from this service...

Any ideas?

Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
112
2015/03/16 - 15:37
sp_Permalink sp_Print

Hello ri9000,

ri9000 said

..or i could be completely off track here..but in one rom I saw this in "power_profile.xml":

(...)
<item name="screen.full">0.1</item>
(...)

these values gave meaningless battery stats until I populated with sane values.

hope this is of use.

ok, one major step forward again:

It looks like you were on the right track: The "CrewRKTablets_RK30_Genio by Oma_CM10.1_v1.4" ROM indeed also contains a meaningless XML power profile - very similar to yours: see attached.

And even worse: In the code of Java class com.android.settings.fuelgauge.PowerUsageSummary - which is responsible for displaying the "Battery usage data isn't available" message, there is the following code:

    if (this.mPowerProfile.getAveragePower("screen.full") < 10.0D)
    {
      addNotAvailableMessage();
      return;
    }

... and indeed, the power profile as contained in the ROM has 0.1 as the "insane" value for "screen.full", which obviously is less than 10.0 and most probably explains why we always see the "NotAvailableMessage"...

I am now looking into a way to fix this. Unfortunately, the Trekstor stock Android 4.1.1 ROM also has the same meaningless power profile, but in the Settings.apk of this ROM, the above code fragment had been changed to read

    if (this.mPowerProfile.getAveragePower("screen.full") < 0.0D)
    {
      addNotAvailableMessage();
      return;
    }

The interesting question now is:

What is the best way to resolve this? I feel like providing a "meaningful" power profile is most certainly better than patching the PowerUsageSummary class, but then again - where did you get your "sane" values from?

Thanks again & best regards,

awl

Avatar
Oma7144

Moderator

Firmware Guru
Forum Posts: 6315
Member Since:
2012/10/06
sp_UserOfflineSmall Offline

Thanks Received: 1378
113
2015/03/16 - 17:19
sp_Permalink sp_Print

awl said
Hello Oma,

hmm - with the battery fix for the RK29 CM10.1 build linked above:

http://crewrktablets.arctablet.com/?wpfb_dl=1055

things seem a little better: I can now see the file

/data/system/batterystats.bin

is being written and continuously updated, but nevertheless the Android "Settings" app seems unable to display this information in the "Battery" submenu: "Battery usage data isn't available".

Battery load level is displayed properly, and when I tap on the battery graph, I also get some information.

Please see the screenshots attached below for more information.
 

Settings-Battery.pngImage EnlargerSettings-Battery-History-details.pngImage Enlarger

Perfect as it is. More is not implemented.

Battery usage data per app is always a "lie". If you'd like to show this up use a third party app (i.e. One Power Guard).

- Oma -

The following users say thank you to Oma7144 for this useful post:

awl
Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
114
2015/03/16 - 18:40
sp_Permalink sp_Print

Thanks Oma,

but in the meantime, I have succeeded in updating my "model fix" with a modified framework-res.apk containing a much more reasonable power_profile.xml.

And indeed, battery stats are now available and working fine, as you can see from the attached screenshot. Smile

So I think that the stock CM10.1 can clearly be improved in this regard...

 

@ri9000:

I'd still be grateful for any hints regarding the "sane" values that you chose for your power_profile.xml... Wink

Thanks & best regards,

awl

 

Settings_Battery-working.pngImage Enlarger

Avatar
Oma7144

Moderator

Firmware Guru
Forum Posts: 6315
Member Since:
2012/10/06
sp_UserOfflineSmall Offline

Thanks Received: 1378
115
2015/03/16 - 18:48
sp_Permalink sp_Print

Great! Blog updated: http://crewrktablets.arctablet.com/?p=1913

- Oma -

The following users say thank you to Oma7144 for this useful post:

awl
Avatar
ri9000

Contributor
Forum Posts: 29
Member Since:
2014/09/07
sp_UserOfflineSmall Offline

Thanks Received: 7
116
2015/03/18 - 12:16
sp_Permalink sp_Print sp_EditHistory

Hi Awl it seems I can't attach the file no matter what the format... so sorry about the long post. I found info on this setup on google source. As a starting point I used values from a nexus7, and modified them based on my experience using the tablet and the relative power drain of each item. The cpu speeds are for my u30gt cube mini. The "battery.capacity" is my cubes battery rating in milliamp/ hours. Now the battery monitor displays useful information and "better battery stats" fills in the blanks with "cpu states" etc. Here is my "power_profile.xml. Hope this helps.

ps: my cube has a small 7" screen

<?xml version="1.0" encoding="utf-8"?>
<device name="Android">
<item name="none">0</item>
<item name="screen.on">250</item>
<item name="screen.full">350</item>
<item name="bluetooth.active">10</item>
<item name="bluetooth.on">5</item>
<item name="wifi.on">10</item>
<item name="wifi.active">100</item>
<item name="wifi.scan">50</item>
<item name="dsp.audio">2</item>
<item name="dsp.video">5</item>
<item name="radio.active">1</item>
<item name="radio.scanning">0.5</item>
<item name="gps.on">100</item>
<array name="radio.on">
<value>0.2</value>
<value>0.1</value>
</array>
<array name="cpu.speeds">
<value>252000</value>
<value>504000</value>
<value>816000</value>
<value>1008000</value>
<value>1200000</value>
<value>1272000</value>
<value>1416000</value>
</array>
<item name="cpu.idle">15</item>
<item name="cpu.awake">35</item>
<array name="cpu.active">
<value>92</value>
<value>108</value>
<value>118</value>
<value>133</value>
<value>173</value>
<value>209</value>
<value>228</value>
</array>
<item name="battery.capacity">3600</item>
</device>

The following users say thank you to ri9000 for this useful post:

awl
Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
117
2015/03/19 - 23:18
sp_Permalink sp_Print

Thank you, ri9000, you basically confirmed what I had also found out from the internet.

I have used pretty similar values, but note that in order to avoid false messages about 3G radio using the battery on the Ventos (which does not have a 3G support), I need to omit/set all values for "radio.*" to zero.

Best regards,

awl

Avatar
ri9000

Contributor
Forum Posts: 29
Member Since:
2014/09/07
sp_UserOfflineSmall Offline

Thanks Received: 7
118
2015/03/20 - 06:55
sp_Permalink sp_Print

re radio not used: or maybe delete this key altogether? 

One day when i can be bothered i'll setup an ammeter and measure the currents properly, but for me the results are useful and accurate enough as is.

Avatar
awl
Regular Member
Forum Posts: 90
Member Since:
2015/02/11
sp_UserOfflineSmall Offline

Thanks Received: 1
119
2015/03/26 - 20:09
sp_Permalink sp_Print sp_EditHistory

Hello again,

so I have started looking into kernel 3.0.36 and a KitKat ROM.

So far, I have a kernel based on

http://git.gnorth.ru/surf1011_kernel_3.0.36.git/master/

Linux version 3.0.36+ (android@android-build) (gcc version 4.4.7 (Ubuntu/Linaro 4.4.7-1ubuntu2) ) #1 SMP PREEMPT Thu Mar 26 18:35:39 CET 2015

that compiles and boots fine (but with black screen after the framebuffer boot logo), but unfortunately only when I use my boot.img for the Ventos from CM10.1...

When I try to use the boot.img from either "Oma_RK31_Chuwi_V88_KK_4.4.2_v2.3_gen1 loader" or "Oma_RK30_Pipo_S1s_KK_4.4_v1.0", the boot process hangs when the frame buffer is shown, i.e. before I am able to connect with "adb shell".

I have attached the dmesg and logcat output that I get so far when using my CM10.1 boot.img for the Ventos, and will now try to start looking into how the contents of boot.img differ between CM 10.1 and KitKat.

@Oma/Jochen:

Any ideas why the stock boot.img from KitKat might cause the hang? Also, do you have any idea why a number of crashes in /system/lib/libc.so (which is the KitKat version)?

What about SELinux? Do the "Oma_RK31_Chuwi_V88_KK_4.4.2_v2.3_gen1 loader" and/or "Oma_RK30_Pipo_S1s_KK_4.4_v1.0" images expect SELinux support?

Many thanks one more time & best regards,

awl

Avatar
ri9000

Contributor
Forum Posts: 29
Member Since:
2014/09/07
sp_UserOfflineSmall Offline

Thanks Received: 7
120
2015/03/28 - 02:32
sp_Permalink sp_Print sp_EditHistory

Hi Awl well done so far!

(I hope i'm not stating things you already know here? ..) have you managed to unpack the bootloader?

I found a site that explained the bootloaders inner workings but unfortunately I didn't bookmark it.Embarassed (will look again)

If this information was correct, board specific info like the screen driver and the screen orientation, wifi ... is passed to the kernel by the bootloader at boot time.

I don't know why we can't override and simply insmod the driver/s we want?Confused

As for selinux support: I think(but not 100%) kernel support needs to be compiled in?

But KK init.board.rc and init.rc are vastly different to JB. eg:

# Set the SELinux system-wide enforcing status 

setenforce 1 

..and booting on a JB boot.img will hang a KK rom that expects selinux support and the "extras" that go with it...eg:

# We restorecon /cache in case the cache partition has been reset.
restorecon /cache

..also don't the rk-KKs use an extra partition for some strange reason?

..i'm not sure how hacked rockchip KK roms are? I've read early rk-KKs were "pretend" versions?.. so I wonder if you have the drivers and a working kernel config, could you compile your own cm11?

Forum Timezone: Europe/Paris

Most Users Ever Online: 749

Currently Online: edet
73 Guest(s)

Currently Browsing this Page:
1 Guest(s)


Devices in use: Desktop (66), Phone (7), Tablet (1)

Top Posters:

finless: 604

DarthJabba: 551

maikal: 394

mussonero1: 350

alex: 252

damo: 243

DanielVd: 237

Mark06: 222

Newest Members:

javionico

kazakovlxndr

leutu17

fisgi1991

polosoft

keyzoo

Forum Stats:

Groups: 10

Forums: 185

Topics: 6037

Posts: 60500

 

Member Stats:

Guest Posters: 43

Members: 262194

Moderators: 5

Admins: 1

Administrators: admin

Moderators: globula_neagra, exelletor, JochenKauz, Oma7144, cracktech


CrewRKTablets moderators: JochenKauz and Astralix