AMLogic aml8726-mx TV BOX new PCB "HD18 v2.22"

Search This thread
Sep 25, 2013
43
7
Hello,

there is a new board label "HD18 v2.22" at the market. It looks like the known "HD18 v2.2" (detachable wifi antenna cable connector) and "HD18 v2.21" (not detachable wifi antenna cable), the only thinks that are different
- there is a little bit bigger headsink witch is 45° rotated (covers the NAND a little bit) and is fixed to the board with two plastic pins/sticks
(- there are more louver at the bottom of the case)

More I can not say at first stepp, because I've received a defective device.
No Signal at HDMI or AV.
The only think that works is that the color of the light will toggle between blue and red by using the red RC power-button.

---------------------------------

Hello,

one step further: the A/V cable delivered with the device is damage!
(PS: there was a plastic selvage at the pin, so I can't put the pin deep enough into the hole; I've cut it with a knife, now the cable works)
Now I try another cable and get A/V out. But HDMI don't work furthermore, not at my TV.
At my TV I try every display resolution in the android, that is possible, but no output, only "no signal"...

One or two times at my many many trey after startup to plug the HDMI parallel to the A/V into the box, I got a videoout at HDMI, but the system freez at that moment...

-----------------------------------

System
a) not rooted
b) Settings -> System -> About MediaBox
Code:
Model number: MBX reference board (g18ref)
Android version: 4.2.2
Kernel version: 3.0.50 / ubuntu@ubuntu-desktop #4 / Sat Jun 29 10:13:43 CST 2013
Build number: JDQ39.20130629

SSHelper

[@localhost /data/data/com.arachnoid.sshelper/home ]$ cat /proc/mtd
Code:
dev:    size   erasesize  name
mtd0: 00800000 00200000 "bootloader"
mtd1: 00400000 00200000 "ubootenv"
mtd2: 00800000 00200000 "logo"
mtd3: 00800000 00200000 "aml_logo"
mtd4: 00800000 00200000 "recovery"
mtd5: 00800000 00200000 "boot"
mtd6: 40600000 00200000 "system"
mtd7: 20000000 00200000 "cache"
mtd8: 10000000 00200000 "backup"
mtd9: 18c600000 00200000 "userdata"
http://xdaforums.com/showpost.php?p=46059326&postcount=158 ????


--------------------------------------------------------------

This device really sucks me out...

It seems so, that it only doesn't work at my TV (WUXGA 1920 x 1080).
At a monitor (1280 x 1024) with 720, at two HDready TV and another fullHD TV it works fine via HDMI....

I also try a HDMI-Splitter (v1.4)... I get a lighting InPut LED at the splitter until I connect the splitter-OutPut with my TV, then the InPut LED stops to light (output LED is lighting)...
(BTW: onetime at the beginning of my many trys with the spillter, I got a signal to my TV, but it wasn't reproducible???)

My notebook, SAT-receiver and a RK3188-box works fine with my TV...

Than I found out, at the toothpick method, there isn't any output via AV...
(opening the device and pressing the little switch)
Know I don't really know, whether a bootable SD-card (using DD or SDTools or the Matricom recovery SD respectively the merge by BenniBenassi-solution) is helpful, because I think it's a generally problem of the output-possibility of the recovery and I don't know, whether it is possible to use a choice with the knowing recovery.img like here


I found any way out, how to root the existing installed android...
Perhaps
http://xdaforums.com/showthread.php?t=2146226
http://tabletrepublic.com/forum/and...how-root-any-aml-8726-based-mini-pc-3449.html
BUT without any output, so I can forget it...

And don't found any exploit like this ...

I want to root it, because of the possibility to use
- dmesg
- cat log (whichever)
:

And last but not least, the "cat /proc/mtd" output I found at my device don't compare to the standard output flying around in the I-Net, so I don't really sure that I can reflash my box with the g-box MX2 FW...
I thinking about it, perhaps it isn't a HW problem/incompatibility with my TV, because it seems so the actually installed FW have some bugs (because in Settings for example, if I move trough the sections, the background colure sometimes still is blue and not grey when I leave that point... on the other hand perhaps it's "normal")

Greetings
 

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
New to the thread? Here's pretty much everything you need to know!:
http://xdaforums.com/showthread.php?p=63092584

---------- Post (above) added 1st October 2015 at 11:08 PM ---------- Previous post (below) was 29th October 2013 at 01:35 AM ----------

I just got one of these too.. Not sure what to do about it really since my TV is only AV-in.. The USB-OTG slot also doesn't register anything on my laptop with the Male-to-Male USB cord I just bought, either with USB Debugging enabled or when attempting to headlessly boot the custom cwm sdcard.

Kinda disappointing considering I bought this thing on eBay specifically to convert to Matricom with @BenniBenassi's image. :(

I'm thinking I might try to headless upgrade it anyway, just leaving the sdcard in for an hour or something so I know it had time to complete.

Edit: 100% successful!! :D
 
Last edited:

BenniBenassi

Senior Member
Hello,

there is a new board label "HD18 v2.22" at the market. It looks like the known "HD18 v2.2" (detachable wifi antenna cable connector) and "HD18 v2.21" (not detachable wifi antenna cable), the only thinks that are different
- there is a little bit bigger headsink witch is 45° rotated (covers the NAND a little bit) and is fixed to the board with two plastic pins/sticks
(- there are more louver at the bottom of the case)

More I can not say at first stepp, because I've received a defective device.
No Signal at HDMI or AV.
The only think that works is that the color of the light will toggle between blue and red by using the red RC power-button.

---------------------------------

Hello,

one step further: the A/V cable delivered with the device is damage!
(PS: there was a plastic selvage at the pin, so I can't put the pin deep enough into the hole; I've cut it with a knife, now the cable works)
Now I try another cable and get A/V out. But HDMI don't work furthermore, not at my TV.
At my TV I try every display resolution in the android, that is possible, but no output, only "no signal"...

One or two times at my many many trey after startup to plug the HDMI parallel to the A/V into the box, I got a videoout at HDMI, but the system freez at that moment...

-----------------------------------

System
a) not rooted
b) Settings -> System -> About MediaBox
Model number: MBX reference board (g18ref)
Android version: 4.2.2
Kernel version: 3.0.50 / ubuntu@ubuntu-desktop #4 / Sat Jun 29 10:13:43 CST 2013
Build number: JDQ39.20130629

SSHelper

[@localhost /data/data/com.arachnoid.sshelper/home ]$ cat /proc/mtd
dev: size erasesize name
mtd0: 00800000 00200000 "bootloader"
mtd1: 00400000 00200000 "ubootenv"
mtd2: 00800000 00200000 "logo"
mtd3: 00800000 00200000 "aml_logo"
mtd4: 00800000 00200000 "recovery"
mtd5: 00800000 00200000 "boot"
mtd6: 40600000 00200000 "system"
mtd7: 20000000 00200000 "cache"
mtd8: 10000000 00200000 "backup"
mtd9: 18c600000 00200000 "userdata"
http://xdaforums.com/showpost.php?p=46059326&postcount=158 ????


--------------------------------------------------------------

This device really sucks me out...

It seems so, that it only doesn't work at my TV (WUXGA 1920 x 1080).
At a monitor (1280 x 1024) with 720, at two HDready TV and another fullHD TV it works fine via HDMI....

I also try a HDMI-Splitter (v1.4)... I get a lighting InPut LED at the splitter until I connect the splitter-OutPut with my TV, then the InPut LED stops to light (output LED is lighting)...
(BTW: onetime at the beginning of my many trys with the spillter, I got a signal to my TV, but it wasn't reproducible???)

My notebook, SAT-receiver and a RK3188-box works fine with my TV...

Than I found out, at the toothpick method, there isn't any output via AV...
(opening the device and pressing the little switch)
Know I don't really know, whether a bootable SD-card (using DD or SDTools or the Matricom recovery SD respectively the merge by BenniBenassi-solution) is helpful, because I think it's a generally problem of the output-possibility of the recovery and I don't know, whether it is possible to use a choice with the knowing recovery.img like here


I found any way out, how to root the existing installed android...
Perhaps
http://xdaforums.com/showthread.php?t=2146226
http://tabletrepublic.com/forum/and...how-root-any-aml-8726-based-mini-pc-3449.html
BUT without any output, so I can forget it...

And don't found any exploit like this ...

I want to root it, because of the possibility to use
- dmesg
- cat log (whichever)
:

And last but not least, the "cat /proc/mtd" output I found at my device don't compare to the standard output flying around in the I-Net, so I don't really sure that I can reflash my box with the g-box MX2 FW...
I thinking about it, perhaps it isn't a HW problem/incompatibility with my TV, because it seems so the actually installed FW have some bugs (because in Settings for example, if I move trough the sections, the background colure sometimes still is blue and not grey when I leave that point... on the other hand perhaps it's "normal")

Greetings

Confirming HD18 v2.22 works with the image.....

CWM works, too.

Sent from my ST18i using xda app-developers app
 
  • Like
Reactions: osm0sis

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Confirming HD18 v2.22 works with the image.....

CWM works, too.

Hi Benni, thank you for all your extremely informative and helpful work over on the FreakTab and AndroidGadget Forums where I've been reading up on things.

Do you know any way to use CWM with the AV output, or is HDMI required?

Also did you ever get adb shell working with the Male-to-Male USB cord? I'm customizing your image via Titanium and File Explorer but some things would definitely be more straightforward with adb. :)

Edit: I'm planning on pulling and modding the kernel ramdisk on this thing via dd commands to add init.d support, if possible. I'll keep you posted. :good:
 
Last edited:
  • Like
Reactions: BenniBenassi

BenniBenassi

Senior Member
Hi Benni, thank you for all your extremely informative and helpful work over on the FreakTab and AndroidGadget Forums where I've been reading up on things.

Do you know any way to use CWM with the AV output, or is HDMI required?

Also did you ever get adb shell working with the Male-to-Male USB cord? I'm customizing your image via Titanium and File Explorer but some things would definitely be more straightforward with adb. :)

Edit: I'm planning on pulling and modding the kernel ramdisk on this thing via dd commands to add init.d support, if possible. I'll keep you posted. :good:

Adb shell instructions are here :

http://forum.androidgadget.co.uk/showthread.php?tid=1140&pid=3173#pid3173

Male-to-Male ADB does not work out of the box.... USE the instructions above !!!

And for the CWM with AV output, man you have to be kidding..... just boot the device by inserting the CWM sdcard and holding the match in the AV hole... let's say you wait about 50 seconds. Afterwards you insert the AV cable and you can use the CWM and see it from the TV.

The device and Android system does not need AV screen or monitor or TV to boot up, is is only for us humans to see what is on the screen.

Just boot without the TV connection and insert it afterwards..... come on .... :)


And keep me posted.... keep up the good work :)
 
  • Like
Reactions: osm0sis

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Adb shell instructions are here :

http://forum.androidgadget.co.uk/showthread.php?tid=1140&pid=3173#pid3173

Male-to-Male ADB does not work out of the box.... USE the instructions above !!!

And for the CWM with AV output, man you have to be kidding..... just boot the device by inserting the CWM sdcard and holding the match in the AV hole... let's say you wait about 50 seconds. Afterwards you insert the AV cable and you can use the CWM and see it from the TV.

The device and Android system does not need AV screen or monitor or TV to boot up, is is only for us humans to see what is on the screen.

Just boot without the TV connection and insert it afterwards..... come on .... :)


And keep me posted.... keep up the good work :)

Hahah not my first rodeo Benni, I actually just found the adb over Wifi instructions myself a couple of minutes ago:
http://xdaforums.com/showthread.php?t=1685736

Shame I bought the M-M USB, connecting across the network is much easier. Not sure I trust it for file transfers but I guess that's what sha1sum is for.. Hopefully someone will figure out a way to enable the USB port for adb at some point. Only time the direct USB connection would still be extremely handy is likely when CWM is booted since I assume it doesn't do network, but ah well.

As for AV in CWM, come on.. you better believe I wouldn't be asking if I hadn't tried that. ;)

I re-insert the AV cable after waiting a minute or so and still I don't get any output.. that's why I said I upgraded the ROM with your sdcard image blindly. Are you saying it works on your HD18 v2.22?

Image dumps:
Code:
# backing up partitions on MX MediaBox CS838 with USB Debugging and root.

md backup

adb shell

su

#backup=/storage/external_storage/sdcard1/backup/`date +"%Y-%m-%d.%H.%M.%S"`;
backup=/sdcard/backup/`date +"%Y-%m-%d.%H.%M.%S"`;
mkdir -p $backup;
cat /proc/mtd | tail -n +2 | while read mount; do
  part=`echo $mount | cut -d '"' -f 2`;
  mtd=`echo $mount | cut -d ':' -f 1`;
  echo $backup/$mtd-$part.img;
  test $part != "userdata" -o $part != "system" && nanddump -f $backup/$mtd-$part.img /dev/mtd/$mtd;
done;
echo Calculating checksums...;
cd $backup
busybox sha1sum * > $backup/backup.log;

exit

exit

adb pull /sdcard/backup backup/

Edit 2: Since I couldn't rig up init.d, I made a little toggle script I could run from Terminal Emulator.

/system/xbin/netadb:
Code:
#!/system/bin/sh

if [ `getprop service.adb.tcp.port` != 5555 ]; then
  echo Restarting adbd with TCP port 5555 open...;
  port=5555;
else
  echo Restarting adbd with TCP disabled...;
  port=-1;
fi;

su -c setprop service.adb.tcp.port $port;

su -c stop adbd;
su -c start adbd;

Edit 3: Okay this thing actually uses install-recovery.sh still, so by replacing that we can get init.d working, at least until you OTA or something. I heard terrible things about 1.1.6 so I froze all the OTA services, etc. anyway ;)

/system/etc/install-recovery.sh:
Code:
#!/system/bin/sh

/system/xbin/busybox run-parts /system/etc/init.d;
 
Last edited:

BenniBenassi

Senior Member
Yes, the image works perfectly on v2.22, I installed it..

For getting the ram disk, try image kitchen

1.1.6 is BS, tried it. Recovered within 10 minutes with my sdcard :)

And lol, regarding the AV hole, in that case they do have hardware check .... which is problematic.

Sent from my ST18i using xda app-developers app
 
  • Like
Reactions: osm0sis

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Alrighty, well I tried it again, and I still get no AV output with the sdcard trick, so I guess CWM is out of the question for me until I can test out HDMI.

I used my own Android Image Kitchen to split the boot.img but it's not a normal image and contains several kernels in one, and the extracted ramdisk (the root fs where all the init.* files come from) isn't recognized and looks like pure data. :confused:

If there's another kitchen that can handle them better I'd definitely be interested to know. :D

Either way, I'm pretty happy with things now, with init.d I'm enabling network adb, overclocking to 1.5GHz, raising the min freq to 192MHz, switching the governor to ondemand from conservative, etc.
 
Last edited:

BenniBenassi

Senior Member
HERE'S HOW to use CWM with AV:

Open up the MX box (unscrew 4 screws), insert the AV cable and then press the reset button UNDER IT - its possible while the box is open, only then plug in the POWER cable.

That should do it!

Other:

I used the same kitchen, ramdisk was opened successfully...

Maybe your boot img is corrupted? How did you extract it? I took mine directly from the box.
 
Last edited:
  • Like
Reactions: osm0sis

BenniBenassi

Senior Member
Alrighty, well I tried it again, and I still get no AV output with the sdcard trick, so I guess CWM is out of the question for me until I can test out HDMI.

I used my own Android Image Kitchen to split the boot.img but it's not a normal image and contains several kernels in one, and the extracted ramdisk (the root fs where all the init.* files come from) isn't recognized and looks like pure data. :confused:

If there's another kitchen that can handle them better I'd definitely be interested to know. :D

Either way, I'm pretty happy with things now, with init.d I'm enabling network adb, overclocking to 1.5GHz, raising the min freq to 192MHz, switching the governor to ondemand from conservative, etc.

Care to share how you increased cpu speed etc... :)
 

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Care to share how you increased cpu speed etc... :)
Haha you're chomping at the bit, my friend. I worked a 12h shift today, so please excuse me. :)

Gotta love Matricom for rooting their ROMs, this made it easy for me to install the latest busybox and then start messing around to give myself init.d support like I explained before. With init.d I can set a number of values on boot with shell scripts for the sysfs (old school :D), but with just root and busybox installed we should also be able to use TricksterMod to play with a LOT of device functionality more easily. I haven't tried Trickster yet, but it's on my to-do; for now I've got the following scripts I'm playing with:

My Franco's Dev Team scripts. Something in there seems to have slowed the device down though, so I'm working by process of elimination now, commenting things out to see what tweaks work and what don't for speeding things up. I'll keep you posted.

Matricom also did us a solid by including the OC functionality in the kernel, but just limiting it by default to 1200MHz. Here are all the defaults which I pulled with my settingsdump.sh script:

Code:
/sys/devices/system/cpu/cpu0/cpufreq/
0 1 affected_cpus
336000 cpuinfo_cur_freq
1512000 cpuinfo_max_freq
48000 cpuinfo_min_freq
200000 cpuinfo_transition_latency
0 1 related_cpus
96000 192000 312000 408000 504000 600000 696000 816000 912000 1008000 1104000 1200000 1296000 1416000 1512000  scaling_available_frequencies
conservative ondemand performance  scaling_available_governors
336000 scaling_cur_freq
meson_cpufreq scaling_driver
conservative scaling_governor
1200000 scaling_max_freq
96000 scaling_min_freq
<unsupported> scaling_setspeed
 stats


/sys/devices/system/cpu/cpufreq/conservative/
1 change_skips
50 down_threshold
8 freq_step
0 ignore_nice_load
100000 sampling_rate
20000 sampling_rate_min
408000 screen_off_max
80 up_threshold


/sys/devices/system/cpu/cpufreq/ondemand/
0 ignore_nice_load
0 io_is_busy
0 powersave_bias
1 sampling_down_factor
200000 sampling_rate
20000 sampling_rate_min
95 up_threshold


/sys/block/mmcblk0/queue/


/sys/block/mmcblk0/queue/iosched/


/sys/block/mtdblock9/queue/
1 add_random
0 discard_granularity
0 discard_max_bytes
0 discard_zeroes_data
512 hw_sector_size
 iosched
1 iostats
512 logical_block_size
127 max_hw_sectors_kb
0 max_integrity_segments
127 max_sectors_kb
65536 max_segment_size
128 max_segments
512 minimum_io_size
0 nomerges
128 nr_requests
0 optimal_io_size
512 physical_block_size
128 read_ahead_kb
1 rotational
1 rq_affinity
noop [deadline]  scheduler


/sys/block/mtdblock9/queue/iosched/
16 fifo_batch
1 front_merges
500 read_expire
5000 write_expire
2 writes_starved


/proc/sys/vm/
0 block_dump
0 dirty_background_bytes
5 dirty_background_ratio
0 dirty_bytes
200 dirty_expire_centisecs
20 dirty_ratio
500 dirty_writeback_centisecs
0 drop_caches
0 highmem_is_dirtyable
0 laptop_mode
32	32 lowmem_reserve_ratio
65530 max_map_count
2415 min_free_kbytes
4 min_free_order_shift
32768 mmap_min_addr
0 nr_pdflush_threads
1 oom_dump_tasks
0 oom_kill_allocating_task
1 overcommit_memory
50 overcommit_ratio
3 page-cluster
0 panic_on_oom
0 percpu_pagelist_fraction
0 scan_unevictable_pages
1 stat_interval
60 swappiness
100 vfs_cache_pressure


/sys/module/lowmemorykiller/parameters/
0,1,2,4,9,15 adj
32 cost
2 debug_level
8192,10240,12288,14336,16384,20480 minfree

So as you can see, all the frequencies up to 1512MHz are present, it's just a matter of adjusting the max. Conservative is also the default governor, and I tried ondemand but that was when I tried a bunch of things and it got slow; haven't determined if ondemand works well enough or not. Either way their conservative is pretty aggressive (in a good way, because otherwise it's rather sluggish) with an up_threshold of 80, so we're not too poorly off. (We could also lower both thresholds even more if we want it more responsive/aggressive) :good:

The directory and filenames involved are the files we change to get what we want, so I ended up with these basic tweaks, and I'm still working on others...

/system/etc/init.d/900bootsettings:
Code:
#!/system/bin/sh
# chmod -R 755 /system/etc/init.d

# allow network adb shell access
setprop service.adb.tcp.port 5555;
stop adbd;
start adbd;

# cpufreq tweaks
for i in /sys/devices/system/cpu/cpu*/cpufreq; do
  echo 1512000 > $i/scaling_max_freq;
  echo 312000 > $i/scaling_min_freq;
done;

# tcp tweaks
echo "reno" > /proc/sys/net/ipv4/tcp_congestion_control;

HERE'S HOW to use CWM with AV:

Open up the MX box (unscrew 4 screws), insert the AV cable and then press the reset button UNDER IT - its possible while the box is open, only then plug in the POWER cable.

That should do it!

Other:

I used the same kitchen, ramdisk was opened successfully...

Maybe your boot img is corrupted? How did you extract it? I took mine directly from the box.

Definitely going to try that, also just trying adb reboot recovery with the sdcard in already - possibly save me digging out the screwdriver. ;)

Also not sure how the image could have been corrupted.. maybe adb pull across the network? Or maybe my dd from the mtd partitions I also showed in my other post was flawed somehow.. It definitely pulled everything from the mtdblock#'s and got the associated name from the /proc/mtd partition table correctly, so yeah.. I don't know. How did you extract yours? CWM or another method? CWM might produce a better image, if I can ever get into it! :p

---------- Post added at 08:35 PM ---------- Previous post was at 07:53 PM ----------

"adb reboot recovery" definitely doesn't work :(, I'll have to try your open-box method on my next day off since I don't want to mess around with the screwdriver tonight..

Also definitely install Xposed Framework and checkout the Master Key vulnerability fix and Gravity Box, both great modules. Gravity Box takes AOSP and makes it like CM if you want. Fantastic way to mod without touching system files. :good:

---------- Post added at 09:12 PM ---------- Previous post was at 08:35 PM ----------

Couldn't resist. Open box method didn't work either. :(
 
Last edited:
  • Like
Reactions: BenniBenassi

BenniBenassi

Senior Member
Try to use nanddump command to dump the img... Dd does not handle bad blocks well.... I can provide you several versions of recovery.img if you want... Which all extract nicely with your image kitchen :)

I have plan to make a new recovery sd with all of the above tricks, oc etc.

Since I'm clueless regarding init.d, can you advise how to add these init.d scripts to the rom in the first place and then how to add them so they would install automatically from inside a custom rom?

And is there any sense to oc mali?

Sent from my GT-P3110 using xda app-developers app
 
  • Like
Reactions: osm0sis

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Thanks I'll try nanddump. I'm not too familiar with mtd just yet. :)

Easiest method to do this is make install-recovery.sh with the run-parts command and have it in the same directory as a script that'll install init.d support and then the settings script of your choice. I'll write it for use in recovery (only difference is the location of sh in the first line):

Code:
#!/sbin/sh

busybox mount -o remount,rw /system;
rm -f /system/etc/install-recovery.sh;
cp install-recovery.sh /system/etc/;
chmod 755 /system/etc/install-recovery.sh;
mkdir /system/etc/init.d;
cp 900bootscript /system/etc/init.d/;
chmod -R 755 /system/etc/init.d;

You may have to add paths for the scripts that need to be copied since I'm not sure what that looks like from recovery on the sdcard.
 
  • Like
Reactions: BenniBenassi

BenniBenassi

Senior Member
Thanks I'll try nanddump. I'm not too familiar with mtd just yet. :)

Easiest method to do this is make install-recovery.sh with the run-parts command and have it in the same directory as a script that'll install init.d support and then the settings script of your choice. I'll write it for use in recovery (only difference is the location of sh in the first line):

Code:
#!/sbin/sh

busybox mount -o remount,rw /system;
rm -f /system/etc/install-recovery.sh;
cp install-recovery.sh /system/etc/;
chmod 755 /system/etc/install-recovery.sh;
mkdir /system/etc/init.d;
cp 900bootscript /system/etc/init.d/;
chmod -R 755 /system/etc/init.d;

You may have to add paths for the scripts that need to be copied since I'm not sure what that looks like from recovery on the sdcard.


Weird things, I applied the init.d script and the max frequency is 1.2GHz. ....
I applied both the min and max to the 1512000 and it still is 1200MHz .....
Very strange......

No-frills CPU shows its 1.512GHz, but CPU-Z shows its 1200MHZ.
Setting of the lower minimum frequency works.

See pics:

Screenshot_2013-11-02-23-55-05_zps9af73199.png


Screenshot_2013-11-03-00-04-56_zpsdc1f1c72.png


Screenshot_2013-11-03-00-02-21_zps68bb0f2c.png
 
Last edited:

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
Evidently has something to do with nandargs.... Haven't been able to figure out fully...

Ah damn.. I just saw that the value set correctly and didn't follow up to make sure it actually was using the new max. I'll look into it too.

The other weird thing is that it always says 336 is the current frequency, but it's not even one of the listed scaling_frequencies options.

I did a quick search for Mali 400 to see if I could find anything to overclock/tweak with, and didn't come up with anything useful at first glance, but hunted around and found /sys/module/mali/parameters/ which may contain something useful, just not too sure what to do there. Looks like we could potentially expand the shared memory it uses at least?
 
Last edited:

BenniBenassi

Senior Member
Ah damn.. I just saw that the value set correctly and didn't follow up to make sure it actually was using the new max. I'll look into it too.

The other weird thing is that it always says 336 is the current frequency, but it's not even one of the listed scaling_frequencies options.

I did a quick search for Mali 400 to see if I could find anything to overclock/tweak with, and didn't come up with anything useful at first glance, but hunted around and found /sys/module/mali/parameters/ which may contain something useful, just not too sure what to do there. Looks like we could potentially expand the shared memory it uses at least?

The script you ran shows this line: 336000 scaling_cur_freq .....
 

osm0sis

Senior Recognized Developer / Contributor
Mar 14, 2012
16,767
40,430
Halifax
GT-i9250
Google Nexus 4
The script you ran shows this line: 336000 scaling_cur_freq .....

Exactly, it always says that's the current frequency, but..

96000 192000 312000 408000 504000 600000 696000 816000 912000 1008000 1104000 1200000 1296000 1416000 1512000 scaling_available_frequencies

It's not actually in the list,

48000 cpuinfo_min_freq

and neither is the apparent board min. Very odd. Could just be an issue with the meson-cpufreq driver not outputting the proper values to userspace, but this definitely makes it difficult to tell if it's properly using the frequencies we set, or even they set.
 
Last edited:

BenniBenassi

Senior Member
Exactly, it always says that's the current frequency, but..

96000 192000 312000 408000 504000 600000 696000 816000 912000 1008000 1104000 1200000 1296000 1416000 1512000 scaling_available_frequencies

It's not actually in the list,

48000 cpuinfo_min_freq

and neither is the apparent board min. Very odd. Could just be an issue with the meson-cpufreq driver not outputting the proper values to userspace, but this definitely makes it difficult to tell if it's properly using the frequencies we set, or even they set.

Found a thread :

http://www.slatedroid.com/topic/37201-how-to-get-15ghz-processor-speed/

something to do with uboot, kernel and replacing a9_clk_max=somenumber with a9_clk_max=1512000000

EDIT: **** looked into that ****

The thing is, when in adb shell, cat /dev/nand_env/ already gives this:

....................loads of parameters ....................
....................loads of parameters ....................
....................loads of parameters ....................
a9_clk_max=1512000000
....................loads of parameters ....................
....................loads of parameters ....................
....................loads of parameters ....................

So.... maybe it is a hardware or kernel limit?




EDIT 3: *********


For dumping the contents I have used the following simple commands over adb:

nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/bootloader.img /dev/mtd/mtd0
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/ubootenv.img /dev/mtd/mtd1
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/logo.img /dev/mtd/mtd2
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/aml_logo.img /dev/mtd/mtd3
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/recovery.img /dev/mtd/mtd4
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/boot.img /dev/mtd/mtd5
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/system.img /dev/mtd/mtd6
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/cache.img /dev/mtd/mtd7
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/backup.img /dev/mtd/mtd8
nanddump -b -f /storage/external_storage/sdcard1/nanddump.20131103/userdata.img /dev/mtd/mtd9
 
Last edited:
  • Like
Reactions: osm0sis

Top Liked Posts

  • There are no posts matching your filters.
  • 9
    Used Titanium Backup to convert all my downloaded GApps to system apps (renamed manually to the correct Stock ROM filenames) to save some space the other day.

    Also came across the following little gem.

    /system/etc/init.d/00dalvik2cache:
    Code:
    #!/system/bin/sh
    # chmod -R 755 /system/etc/init.d
    # osm0sis @ xda-developers
    
    # move the dalvik-cache to /cache to save space on /data
    busybox rm -f /data/dalvik-cache/*;
    busybox mkdir /cache/dalvik-cache;
    busybox chown system:system /cache/dalvik-cache;
    busybox chmod 771 /cache /cache/dalvik-cache;
    busybox mount -o bind /cache/dalvik-cache /data/dalvik-cache;

    We've got a ton of space in our cache partition we don't use since we don't bother with OTAs, so why not? :good: :)
    2
    I've never managed to brick it harder than the Benni emergency sdcard could recover, so if the toothpick method for getting into sdcard recovery doesn't work for you I don't really have any other firsthand ideas.

    There was mention of building a cable to connect to the board directly, that could be your best bet. On the other hand, for time and effort these things only cost like $35 nowadays so.. might be more cost effective to just start fresh?

    omg, i was doing the short on the NAND chip ( pin 7 and 8 )right now with the benni bennasi method.
    first i formated the sd card with HDDRawCopy1.02Portable and MATRICOM_MX2_115_FULL_AUG_09_2013. deleted files on the sd card, copied two files ( from dextars-nandscrubber ), did the tooth pick method, ( no hdmi output yet ), then do again the benni benassi method on the sdcard, short the nand pin 7 and 8 for 10-15 secs and when i removed the screwdriver im using to short pin 7 and 8, the system booted on the green android loading , now its stuck at around 25% and still loading.. i wonder if its working or if its stuck. will follow soon.

    ---------- Post added at 11:32 PM ---------- Previous post was at 11:04 PM ----------

    omg, i was doing the short on the NAND chip ( pin 7 and 8 )right now with the benni bennasi method.
    first i formated the sd card with HDDRawCopy1.02Portable and MATRICOM_MX2_115_FULL_AUG_09_2013. deleted files on the sd card, copied two files ( from dextars-nandscrubber ), did the tooth pick method, ( no hdmi output yet ), then do again the benni benassi method on the sdcard, short the nand pin 7 and 8 for 10-15 secs and when i removed the screwdriver im using to short pin 7 and 8, the system booted on the green android loading , now its stuck at around 25% and still loading.. i wonder if its working or if its stuck. will follow soon.


    so after flashing with mx2-boot-recovery.zip , i have been able to install 1.1.5 and its running. i tought it was the end... thank you all for the forum
    2
    Alright I think this is finally to a point where it's a good base to tweak from! :D

    MX-g18ref-r3-osmod:
    http://v.ht/osmod or http://d-h.st/users/osm0sis/osmod

    ramdisk changes:
    - change mounting to via fstab to allow for all the tweaked mount options I wanted
    - enable adb over TCP on boot, triggered by DHCP IP address assignment on eth0 or wlan0, and/or the new service.adb.tcp.enable property
    - fix up broken permissions on a number of files allowing for proper tweaking of various sysfs entires (resulting in...)
    - increase the Mali-400 GPU max freq to 400 MHz where it should be (was 333)
    - increase the CPU scaling max freq to the board max of 1512 MHz (was 1200)
    - increase the CPU scaling min freq to 696 MHz so that things are actually fast (was 96)
    - tuned conservative governor to scale up more aggressively (thanks droidphile)
    - various VM and kernel tweaks (randomize_va_space, minfree, lease-break-time, entropy)
    - various TCP tweaks (buffer sizes and thresholds from latest CM, "reno" TCP congestion avoidance algorithm)
    - replace the crappy G-Box bootsplash with the "Android Open System" image.. ooh rainbows!
    - add init.d support service
    - add busybox, nandwrite, nanddump and flash_erase binaries to /sbin to make life easy (thanks stericson & _n0p_)
    - add my flash_image and netadb scripts to /sbin to make it even easier
    - add /sbin/osbootscript.sh to run even further/more complicated tweaks

    osbootscript.sh tweaks:
    - create /system/etc/init.d/ directory and set proper permissions if it doesn't already exist
    - disable /system/lib/egl/libGLES_android.so to force rendering on the Mali GPU driver (thanks BenniBenassi)
    - disable some unnecessary debugging (thanks franciscofranco)
    - tune deadline IO scheduler for better throughput
    - some tried-and-true queue tweaks from myself and some experimental queue/bdi changes (thanks BenniBenassi)
    - remount sysfs+sdcard with tweaked mount options to improve responsiveness
    - TCP tweaks to reduce network latency (thanks anarkia1976)
    - lowmemorykiller tweaks for fewer background processes
    - renice (ie. increase priority of) systemui and launcher to improve responsiveness (thanks boype)


    I also attempted to enable USB adb by adding a number of entries to the .usb.rc files and default.prop but unfortunately it still doesn't work. Also, even though we can set the scaling_max_freq to 1512 MHz successfully, it still appears to cap at 1200 MHz; apparently changes to the kernel source are required to remove this weird, hardcoded limitation.


    To Flash:
    Use my flash_image script or do it directly with the MTD-Utils linked here:
    http://xdaforums.com/showthread.php?p=40409361#post40409361

    After the first flash you'll always have access to both the MTD-Utils and my flash_image script from /sbin to make it easier in the future, and the netadb script will toggle adb over TCP if the adbd service ever stops or we come across some circumstances where it doesn't trigger automatically. :good:
    2
    The first one is my favorite :)

    Me too, though it's a lot to take in for the half-second it's displayed, and things get a little warped on my old 4:3 television. ;)

    My girlfriend wants the GTV one on ours, but I won't force the branding on anyone else. :p

    @BenniBenassi, what do you prefer?

    Edit: Using those MTD-Utils I simplified the commandline flashing process into a flash_image script:
    http://xdaforums.com/showthread.php?p=40409361#post40409361

    Things just got way easy! :D Doing a bit of testing, then I'll upload my modded boot.img which will also include all the MTD-Utils in /sbin/. :good:
    2
    Ah. No idea. Go for it. ;)

    i will try, but my kernel compilation skills are near to zero.
    :)