[ROM][SM-G313HU] AOSP 5.1.1 and CM12.1 for Galaxy Ace 4

Search This thread

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
Code:
#include 
/*
* Your warranty is now void.
*
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you.
*/
General:
AOSP 5.1 and CM12.1 for Samsung Galaxy Ace 4 (SM-G313HU). Note that Google apps are not included.

What works:
  • Pretty much everything
What does not:
  • FM Radio (removed from the firmware)

Download:
Downloads moved.
CM12.1
AOSP
Google Apps

Screenies:
Screenshot_2015-12-27-10-36-01.jpgScreenshot_2015-12-27-10-36-35.pngScreenshot_2015-12-27-10-36-30.pngScreenshot_2015-12-27-10-36-45.pngScreenshot_2015-12-27-10-38-20.png

Sources:

Please report any bugs to this thread.

Thanks alot to TheNikiz for a device tree and helping me with some thingies.
 
Last edited:

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
Did you figure out the codec issues? For example the Facebook video playback?

Yeah, you need to patch frameworks_av like in cm12 to add YcbYCr color format, and add proper media_codecs.xml. Haven't tested facebook tho, but video recording/playing and apps like youtube work. Check out git repo.
Tho that routing still annoys crap outta me, it tries to add route to gateway, but fails, cause gw is in another network, we need to add static route to rmnet0 address instead, i tested adding it manually and it worked.
 
Last edited:

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
@itigr Thanks for the ROM but isn't there any possibility of getting the mobile data thing fixed permanently?
Also,ROM with pretty much everything working with tiltle[Experimental].
weird. @Nikiz how did you unlock the bootloader of the almost dead Trend 2 or it wasn't locked?
 
Last edited:
  • Like
Reactions: Ammar Alshammery

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
@itigr Thanks for the ROM but isn't there any possibility of getting the mobile data thing fixed permanently?
Also,ROM with pretty much everything working with tiltle[Experimental].
weird.

No, at least not now. And i don't want to spend one more week figuring out why it doesn't work, i will probably pause dev for indefinite period 'coz i'm tired of this.
Yep, cause i messed with sources alot :D
 
Last edited:
  • Like
Reactions: Edwin Hamal

Nikiz

Senior Member
Feb 14, 2014
221
74
25
Kauhajoki
@Nikiz how did you unlock the bootloader of the almost dead Trend 2 or it wasn't locked?

Umm, what? The Trend 2 bootloader was never locked. (Well, it shows the invalid signature check, but still allows booting) I think you mixed it up with the Huawei Y5-project I have now. (Got the bootloader unlocked and a custom recovery running on it within 24 hours of owning it.. :D)
 

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
@itigr ok... but...
First of all AOSP sucks(It doesn't even have a file manager)
There's alot more bugs i.e
Wifi does't work (always shows exclamation even though the wifi is working good)
Calls doesn't end(mention about the work around for this too)
Last thing isn't there anyway that I can flash both ROM's by @Nikiz and you without editing things?
Coz having to switch recovery is really a hard task!
 

Nikiz

Senior Member
Feb 14, 2014
221
74
25
Kauhajoki
@itigr ok... but...
First of all AOSP sucks(It doesn't even have a file manager)
There's alot more bugs i.e
Wifi does't work (always shows exclamation even though the wifi is working good)
Calls doesn't end(mention about the work around for this too)
Last thing isn't there anyway that I can flash both ROM's by @Nikiz and you without editing things?
Coz having to switch recovery is really a hard task!

Got the bootloader unlocked by just typing "fastboot oem unlock-go" into the terminal. I just made a minimal device tree for this phone, with the partition information, TWRP settings and the fstab-file. I just built it and I was surprised that it booted on the first try. All I had to do was to fix the fstab-file, change the pixel format and add couple of recovery settings to make it fully working. Building CM12.1 now. (Luckily there was couple of officially supported, similar Huawei devices, so I just copied bunch of code from there.. :D)
 
  • Like
Reactions: rahat044

doesntexits

Senior Member
Apr 12, 2015
1,332
1,743
/dev/null
Got the bootloader unlocked by just typing "fastboot oem unlock-go" into the terminal. I just made a minimal device tree for this phone, with the partition information, TWRP settings and the fstab-file. I just built it and I was surprised that it booted on the first try. All I had to do was to fix the fstab-file, change the pixel format and add couple of recovery settings to make it fully working. Building CM12.1 now. (Luckily there was couple of officially supported, similar Huawei devices, so I just copied bunch of code from there.. :D)

Lucky for you that almost all Huawei are Snapdragon.
 
  • Like
Reactions: adeii

doesntexits

Senior Member
Apr 12, 2015
1,332
1,743
/dev/null
Yeah, this processor is supported by AOSP too, so no patching needs to be done, which is nice. Currently I have only got to the boot animation. ADB doesn't work for some reason. (eng-build and insecure ADB)

Welcome to my world :) Now i'm still stuck at Samsung logo. adb shell works fine but logcat gives me a blinking cursor, ueventd.scx15.rc is included in out/target/vivalto3gvn/root. Idk the reason why it doesn't even gives me a boot animation. Tried stock init but it reboots straight to recovery mode. Now i wish i have a buddy to work with this phone.
 

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
@itigr ok... but...
First of all AOSP sucks(It doesn't even have a file manager)
There's alot more bugs i.e
Wifi does't work (always shows exclamation even though the wifi is working good)
Calls doesn't end(mention about the work around for this too)
Last thing isn't there anyway that I can flash both ROM's by @Nikiz and you without editing things?
Coz having to switch recovery is really a hard task!

Welp aosp still isn't as bad, i used to use it with xposed on my old xperia :D Maybe at some time i will compile cm12.1 or AOSPA (or it's still dead?).
Wifi and calls work, maybe i uploaded an old zip, i was drunk as hell and can't recall it really lol. Reuploading right now, ETA: 40 mins.
Idk how do you want to flash two roms, i've heard it only supported on nexus and still has bugs..
 
Last edited:

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
Front camera video recording doesn't work....
Why is this faster than CM12.1?
I wonder why you prefer AOSP over CM though?
@itigr
Codec issues has gone too.(I guess coz fb videos play now)
 
Last edited:

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
Great but CyanogenMod is also stock android isn't it? with added features which stock lacks.
By the way you're compiling CM12 or CM12.1?
Omni?! Guess you're die heart fan of stock Android! Pure Stock Android rather! :D @itigr
 

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
Great but CyanogenMod is also stock android isn't it? with added features which stock lacks.
By the way you're compiling CM12 or CM12.1?
Omni?! Guess you're die heart fan of stock Android! Pure Stock Android rather! :D @itigr

Yeah. CM12.1, i already compiled it and "fixed" mobile data (not really but now you don't have to mess with scripter since workaround is added to boot image). Uploading it now, 50 minutes left. Only thing is left to fix is offline charger but i got no idea how.
Not really :D
The reason i am compiling omni because i already had it downloaded, i would compile cm13.0 but i'm on my 2nd house now and internet here is crappy + i also heard it's not complete yet and compilinig can fail sometimes. It took me around 2 days to download cm12.1 source with a lot of disconnects.
 

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
Added cm12.1 and pushed data fix and patches to github.
Installed CM12.1 and there's one more problem.
Don't known if I'm only one who has this issue
but after some time device doesn't detect any
Sim cards till a reboot.(Faced this in the AOSP as well)
Has it happend to you?
 

itigr

Senior Member
Oct 21, 2014
188
259
23
Lahdenpohja
Installed CM12.1 and there's one more problem.
Don't known if I'm only one who has this issue
but after some time device doesn't detect any
Sim cards till a reboot.(Faced this in the AOSP as well)
Has it happend to you?

I was testing it for 2 days and have never noticed it.
Did you wipe data/cache/system after flashing?
 

Edwin Hamal

Senior Member
Feb 21, 2014
234
62
I was testing it for 2 days and have never noticed it.
Did you wipe data/cache/system after flashing?
Nah,just did wipe to install new ROM! using
philz.I think it does wipe everything required...
Edit:After flashing???
Edit:Figured out that decive doesn't detect sim card when I soft reboot.
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 11
    Code:
    #include 
    /*
    * Your warranty is now void.
    *
    * I am not responsible for bricked devices, dead SD cards,
    * thermonuclear war, or you getting fired because the alarm app failed. Please
    * do some research if you have any concerns about features included in this ROM
    * before flashing it! YOU are choosing to make these modifications, and if
    * you point the finger at me for messing up your device, I will laugh at you.
    */
    General:
    AOSP 5.1 and CM12.1 for Samsung Galaxy Ace 4 (SM-G313HU). Note that Google apps are not included.

    What works:
    • Pretty much everything
    What does not:
    • FM Radio (removed from the firmware)

    Download:
    Downloads moved.
    CM12.1
    AOSP
    Google Apps

    Screenies:
    Screenshot_2015-12-27-10-36-01.jpgScreenshot_2015-12-27-10-36-35.pngScreenshot_2015-12-27-10-36-30.pngScreenshot_2015-12-27-10-36-45.pngScreenshot_2015-12-27-10-38-20.png

    Sources:

    Please report any bugs to this thread.

    Thanks alot to TheNikiz for a device tree and helping me with some thingies.
    2
    Did you figure out the codec issues? For example the Facebook video playback?

    Yeah, you need to patch frameworks_av like in cm12 to add YcbYCr color format, and add proper media_codecs.xml. Haven't tested facebook tho, but video recording/playing and apps like youtube work. Check out git repo.
    Tho that routing still annoys crap outta me, it tries to add route to gateway, but fails, cause gw is in another network, we need to add static route to rmnet0 address instead, i tested adding it manually and it worked.
    1
    @itigr Thanks for the ROM but isn't there any possibility of getting the mobile data thing fixed permanently?
    Also,ROM with pretty much everything working with tiltle[Experimental].
    weird. @Nikiz how did you unlock the bootloader of the almost dead Trend 2 or it wasn't locked?
    1
    @itigr Thanks for the ROM but isn't there any possibility of getting the mobile data thing fixed permanently?
    Also,ROM with pretty much everything working with tiltle[Experimental].
    weird.

    No, at least not now. And i don't want to spend one more week figuring out why it doesn't work, i will probably pause dev for indefinite period 'coz i'm tired of this.
    Yep, cause i messed with sources alot :D
    1
    @itigr ok... but...
    First of all AOSP sucks(It doesn't even have a file manager)
    There's alot more bugs i.e
    Wifi does't work (always shows exclamation even though the wifi is working good)
    Calls doesn't end(mention about the work around for this too)
    Last thing isn't there anyway that I can flash both ROM's by @Nikiz and you without editing things?
    Coz having to switch recovery is really a hard task!

    Got the bootloader unlocked by just typing "fastboot oem unlock-go" into the terminal. I just made a minimal device tree for this phone, with the partition information, TWRP settings and the fstab-file. I just built it and I was surprised that it booted on the first try. All I had to do was to fix the fstab-file, change the pixel format and add couple of recovery settings to make it fully working. Building CM12.1 now. (Luckily there was couple of officially supported, similar Huawei devices, so I just copied bunch of code from there.. :D)
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone