[MOD] Audio Modification Library v5.1

Which mods do you use?

  • AM3D

    Votes: 73 3.9%
  • V4AFX

    Votes: 1,326 70.2%
  • V4AXhifi

    Votes: 120 6.4%
  • Dolby Atmos (ahrion)

    Votes: 227 12.0%
  • Dolby Atmos Oreo (guitardedhero)

    Votes: 175 9.3%
  • Dolby Digital Plus

    Votes: 218 11.5%
  • B&O Ice (Ainur)

    Votes: 32 1.7%
  • Arkamys (Ainur)

    Votes: 33 1.7%
  • Dirac (Ainur)

    Votes: 42 2.2%
  • Dirac Hexagon (Ainur)

    Votes: 38 2.0%
  • JamesDSP

    Votes: 203 10.8%
  • Audio Compatibility Patch (formerly udbr)

    Votes: 230 12.2%
  • Ainur Sauron

    Votes: 379 20.1%

  • Total voters
    1,888
Search This thread

Steven.kz

New member
Aug 30, 2014
4
0
Hi, I installed AML and ACP. But later not sure related or not, my microphone is not working during video calls but I can still hear other side through speaker.
So I tried uninstall, unroot and even clean install the rom again. However, that problem still persists. Even clean install didn't fix the problem confused me. Is anything I can do? Thank you.

Edited: Sorry. It's custom rom related.
 
Last edited:

avaie

Senior Member
Nov 9, 2014
57
9
Hi - Mods in use with AML crashes - leading to no sound processing. It works fine and in most cases, a few weeks before the issue occurs again. The devices are LG V-Series but I have two uploaded. The V30 is on Oreo with DDP and Viper. The V40 has DDP, Dolby Atmos RC4 by GuiteredHero and Viper; running on Pie. It does not matter the version of AML, the problem persists. ROMS are stock.

I have attached files contain Magisk logs and the data/adb files.
 

Attachments

  • magisk_log_20211207_152643_V40.log
    347.3 KB · Views: 23
  • V30+ aml_4.zip
    52.3 KB · Views: 72
  • V30+ aml_4.zip
    52.3 KB · Views: 30
  • magisk_log_20211207_175831_V30+1.log
    275.1 KB · Views: 8
  • V40 aml_3.5.zip
    242.9 KB · Views: 60
  • magisk_log_20211207_152643_V40.log
    347.3 KB · Views: 21

Techguy777

Senior Member
May 24, 2018
1,515
426
Samsung Galaxy S10 Lite
Xiaomi Poco F3
Thanks. My magisk v.23 stable. May my rom have issue.☹️
Is it a custom rom? If it is than it's possible but if it's stock that's highly unlikely. Custom roms do have trouble with sound files from time to time and that effects it. Can I ask you what sound mode are you trying to install. Also switch selinux to permissive. I know it'll lower security and I don't know anyone who has ever had some virus on their Android device. I've always used selinux permissive especially with viper 4 Android and I have never had the issues people have you also need busy box installed from magisk manager app.They claim to have it working with selinux enforcing but even when it does work it shuts off all the time and permissive never has that problem ever. I could go on forever about how enforcing doesn't really do anything if you have root access and install a bad app that ask for root and you accidentally grant it permission because you don't think about it when it pops up than there's nothing it can't do. Modded apks that don't have icons are the only virus's that you can get on Android if you install an app that's invisible that's probably a virus it'll ask for root permission or administrator rights.
 
  • Like
Reactions: repey6

svendsvin

Senior Member
Oct 21, 2013
271
55
Lost in space
Hi! Is there a magisk 24.1 compatible version that supports Zygisk? I've seen version 4.1 on your github but nowhere to download the module.
Install Fox's Magisk Module Manager from github. There you find version 4.1 among many other great modules.

 

Lughnasadh

Senior Member
Mar 23, 2015
6,160
7,663
Google Nexus 5
Huawei Nexus 6P
Hello, does this module improve the audio quality when I listen to music with headphones?
From the OP:

What is the purpose of this?
Audio mods often function in part by modifying some audio files (such as audio_effects, mixer_paths, etc.). The problem here is that each mod has it's own copy of the files and magisk can only mount 1 copy of each, so only 1 mod will completely work. AML functions by combining them all into one set of files to remedy this issue.
 
  • Like
Reactions: mrrocketdog

Lughnasadh

Senior Member
Mar 23, 2015
6,160
7,663
Google Nexus 5
Huawei Nexus 6P
@Zackptg5 Just wanted to give you a heads up that it appears AML 4.1 is causing bootloops when using Canary 24304. It was working fine with Canary 24303. There were some sepolicy changes. I enabled all my mods one by one and once I enabled AML it started causing the bootloops. I understand this is Canary but in case these changes make their way into the Stable builds I just wanted to let you know.

Using:
Pixel 6 Pro
Android 12L QPR3 Beta 1
Canary 24304
AML 4.1
 

Lughnasadh

Senior Member
Mar 23, 2015
6,160
7,663
Google Nexus 5
Huawei Nexus 6P
@Lughnasadh
Which audio mods are installed? You able to grab a logcat via adb with the loop?
AML doesn't apply any sepolicy patches so I'm wondering if it's another audio mod that's causing it
I had JamesDSP and V4A installed as well when I updated to Canary Magisk 24304 and got into a bootloop. I disabled all mods and then enabled one by one to see which one was causing it. V4A was fine (however I'm using a A12 version of 2.7.2.1) I'm fairly certain that I enabled AML, rebooted, and then got into a bootloop, without enabling JamesDSP first. However, It's possible that I enabled JamesDSP with AML at the same time, but I really don't think I did.

There are some other reports, however, that JamesDSP was causing their phone to bootloop when updating to Canary 24304. A user also reported that V4A was causing them bootloops on Canary 24304 (v. 2.7.2.1). They were on Android 11.

Sorry, but I didn't grab any logs as I was not certain you would be interested since it was a Canary version of Magisk (and frankly just forgot as well). I have since downgraded to Canary 24301 where JamesDSP, V4A and AML have been working fine together.

There were also some other changes to Canary 24304 aside from the sepolicy changes.

This commit to Canary 24304 was causing problems for another non-audio mod. Not sure if it could be related to the problems with the audio mods or not but may be worth taking a look at. It appears the Magisk people found a fix for that mod and commit that I assume will be merged into the next Canary version.
 

Zackptg5

Recognized Developer
Sep 18, 2014
4,148
7,005
zackptg5.com
Google Pixel 4a
Google Pixel 5a
I had JamesDSP and V4A installed as well when I updated to Canary Magisk 24304 and got into a bootloop. I disabled all mods and then enabled one by one to see which one was causing it. V4A was fine (however I'm using a A12 version of 2.7.2.1) I'm fairly certain that I enabled AML, rebooted, and then got into a bootloop, without enabling JamesDSP first. However, It's possible that I enabled JamesDSP with AML at the same time, but I really don't think I did.

There are some other reports, however, that JamesDSP was causing their phone to bootloop when updating to Canary 24304. A user also reported that V4A was causing them bootloops on Canary 24304 (v. 2.7.2.1). They were on Android 11.

Sorry, but I didn't grab any logs as I was not certain you would be interested since it was a Canary version of Magisk (and frankly just forgot as well). I have since downgraded to Canary 24301 where JamesDSP, V4A and AML have been working fine together.

There were also some other changes to Canary 24304 aside from the sepolicy changes.

This commit to Canary 24304 was causing problems for another non-audio mod. Not sure if it could be related to the problems with the audio mods or not but may be worth taking a look at. It appears the Magisk people found a fix for that mod and commit that I assume will be merged into the next Canary version.
I was seeing some talk on ak3 breaking on pixel 6 on latest canary too so may be something with magisk itself
 
  • Like
Reactions: mrrocketdog

Top Liked Posts

  • There are no posts matching your filters.
  • 145
    Audio Modification Library is a library of known audio mods. It'll search your magisk directory for any supported audio mods and incorporate them into itself. It's been completely redone to act as a standalone module so devs no longer need to worry about using a framework for their audio mods and users no longer are limited to just mods using that framework.

    Some history
    Originally, Unity Installer and AML were combined into one. That's what's archived on ahrions github.
    Nowadays, unity is its own thing and AML was completely redesigned into what it is today. The whole purpose of aml is to combine the audio effect/policy/mixer/etc files from multiple audio mods into one set because only one copy of a file can be active mounted at any given time. With non-magisk installs, the actual copies of those audio files are all modified by various mods (aka they all work with the same copy) and so there's no need for aml

    What is the purpose of this?
    Audio mods often function in part by modifying some audio files (such as audio_effects, mixer_paths, etc.). The problem here is that each mod has it's own copy of the files and magisk can only mount 1 copy of each, so only 1 mod will completely work. AML functions by combining them all into one set of files to remedy this issue.

    So how does it work?
    It's now a standalone zip that is flashed once and forgetten about. It's magisk only for obvious reasons and will incorporate all supported audio mods into itself automatically during install, and then during each boot if any changes were detected. So it will adjust for any changes in audio mods such as new ones being installed, some being removed, or an existing one being updated.

    Where the Mod is Located:
    This is more of the nitty gritty for anyone interested but the aml specific copies of audio files and the mod itself are stored in the aml folder in the magisk directory like a typical module. However, it moves any detected audio files out of the folder of any audio mods so they won't be mounted by magisk and conflict. They're moved to .core/aml for safe keeping so they can be restored back to the mod later if you choose to uninstall aml or if upgrading aml

    When do I flash this?
    Unlike with older version of aml, order doesn't matter. However, it's best to flash aml FIRST. The reason for this is that an increasing number of audio mods look for aml and behave differently if it doesn't yet exist.

    Compatibility:
    • Magisk v20.4+
    • Magisk Delta
    • KernelSU
    Troubleshooting:
    If a mod didn't work before you flashed aml, it probably won't work after. Take up the issue on the mod's thread.
    Otherwise, if a mod works before flashing aml and doesn't after: First, try uninstalling all audio mods and then reinstalling them (including aml). If that doesn't work, then I'll need you to make a post with this in it:
    • Recovery log after flashing AML
    • List of Audio Mods Installed
    • AML version last working on (if applicable)
    • Zip attachment of your aml magisk module (/data/adb/modules/aml) folder (note that there's a debug.log file in here that's shows everything)
    • Zip attachment of your aml backup folder (/data/adb/aml) folder
    Currently Supported Mods:
    • AM3D
    • AudioWizard
    • V4AFX
    • V4AXhifi
    • Dolby Atmos (ahrion's ports)
    • Dolby Atmos Axon 7 Oreo (guitardedhero's port)
    • Dolby Digital Plus
    • Bang&Olufsen ICEPower (only tested ainur version)
    • Arkamys (only tested ainur version)
    • Dirac (only tested ainur version)
    • Dirac Hexagon (only tested ainur version)
    • JamesDSP
    • MaxX Audio 3
    • Audio Compatibility Patch (formerly universal deep_buffer remover)
    • Ainur Sauron
    • SquareSound
    • Sony Xperia Z2 Sound System
    • Ainur Narsil
    • Ainur DTSX
    • Ainur DTS Ultra
    • Dolby Atmos Pie/Q+ (guitardedhero's ports)
    • Numerous other mods

    Want an audio mod added to AML?
    Make a post about it and I'll see if it's eligible. No guarantees that I'll add it but these are things that it must have to even be considered:
    • Original/unique (so not a repackaging of other audio mods)
    • Universal(ish) (support a large number of devices - not specific to a handful of devices)
    • Patches files rather than replaces them (the whole point of aml is to be a collection of patches)
    • Patches must be static (won't be changing with each mod update)

    Audio Mod Can't be Added to AML Directly? You can still add it in! :)
    If it doesn't meet these requirements, you can still make it aml compatible.
    You just need your mod to create a file called ".aml.sh" in the root of the mod directory ($MODPATH typically). It'll need to have the patches for your mod in a format that aml can understand:

    1. For patching audio_effect files, AML includes a 'patch_cfgs' function that makes life much easier. So if you have an effect and library to add:
      Code:
      patch_cfgs <effect_name> <UUID> <library_name> <library_path>
      For example:
      Code:
      patch_cfgs v4a_fx 41d3c987-e6cf-11e3-a88a-11aba5d5c51b v4a_standard_fx /vendor/lib/soundfx/libv4a_fx.so
      Note that this patch_cfgs function is for audio effects files only. If you're patching audio policy or mixer_paths files, then you'll need to make the patches the old fashioned way yourself.
      So if you're not patch audio effects files, skip on down to the 'Some other variables/options' section :cowboy:

      'patch_cfgs' has several flags that can be used (the format followed by an example for each is listed here as well):
      • -l: patch library
        Code:
        patch_cfgs -l <library_name> <library_path>
        Code:
        patch_cfgs -l v4a_fx /vendor/lib/soundfx/libv4a_fx.so
      • -e: patch effect
        Code:
        patch_cfgs -e <effect_name> <UUID> <library_name>
        Code:
        patch_cfgs -e v4a_standard_fx 41d3c987-e6cf-11e3-a88a-11aba5d5c51b v4a_fx
      • -o: patch output_session_processing (postprocessing). Typically used with both 'l' and 'e' flags as well
        Code:
        patch_cfgs -ole <osp_section> <effect_name> <UUID> <library_name> <library_path>
        Code:
        patch_cfgs -ole music atmos 9d4921da-8225-4f29-aefa-aacb40a73593 atmos /vendor/lib/soundfx/libatmos.so
      • -q: patch pre_processing (preprocessing). Typically used with both 'l' and 'e' flags as well
        Code:
        patch_cfgs -qle <pp_section> <effect_name> <UUID> <library_name> <library_path>
        Code:
        patch_cfgs -qle music atmos 9d4921da-8225-4f29-aefa-aacb40a73593 atmos /vendor/lib/soundfx/libatmos.so
      • -p: patch proxy effect (note that since this is a special kind of effect, it cannot be used with '-e'). When used by itself
        Code:
        patch_cfgs -p <proxy_effect_name> <proxy_UUID> <sw_library_name> <sw_UUID> <hw_library_name> <hw_UUID>
        Code:
        patch_cfgs -p dax 9d4921da-8225-4f29-aefa-6e6f69726861 dax_sw 6ab06da4-c516-4611-8166-6168726e6f69 dax_hw a0c30891-8246-4aef-b8ad-696f6e726861
        But it's typically used with 'l'
        Code:
        patch_cfgs -pl <proxy_effect_name> <proxy_UUID> <sw_library_name> <sw_UUID> <sw_library_path> <hw_library_name> <hw_UUID> <hw_library_path>
        Code:
        patch_cfgs -pl dax 9d4921da-8225-4f29-aefa-6e6f69726861 dax_sw 6ab06da4-c516-4611-8166-6168726e6f69 /vendor/lib/soundfx/libswdax.so dax_hw a0c30891-8246-4aef-b8ad-696f6e726861 /vendor/lib/soundfx/libhwdax.so
      • -r: replace. Normally, aml will only apply any of the above if it doesn't exist in the audio cfg file. With this flag enabled however, it'll replace any existing effects. It's pretty rare that this would be needed (none of the mods patches built-in to aml have this)
      • no flag specified: if no flags are specified, patch_cfgs will use -le by default (patch library and effect). This is what's typically used (like in the first example before this list)
    2. For patching other files: just add you script logic like it it was in your mod.
      If you're patching mixers for example:
      Code:
      for i in $(find $MODPATH/system -type f -name "*mixer_paths*.xml"); do
        <add_patch_here> for mixer '$i'
      done
      MODPATH is equivalent to aml's directory since it's running the aml.sh script
    3. Then when AML is installed, it'll detect this .aml.sh file and apply the patches accordingly


    Source

    Download
    29
    AML 3.0 is finally HERE!!!

    I've had several different beta channels over the past couple months including many scrapped ideas. The big one was using diff3 but there was no good way to automate conflict merging and so that was scrapped.
    Instead I rewrote 2.5 to be much learner, more efficient, and easier to make an aml.sh script for if you need to.
    Note that the logic for aml.sh files has been changed - it's much easier now - as you can see by the bottom section in the OP

    If you were on a previous beta, completely uninstall that beta first (I used different directories in that one). If you fail to do this, you'll have to reinstall all of your audio mods

    Changelog:
    * Complete overhaul - most everything happens in the boot script now, no need for redunduncies
    * Added Guitardedhero's Dolby Atmos Pie/Q
    * Added Ainur DTS
    * Removed IceWizard
    20
    Updated AML to v1.8.3!
    It came to my attention that there may be the situation in which a user may disable one audio mod rather than uninstall it. In this case, AML would do nothing and so all of the patches/props would still be present for that mod. So with this update, I fixed that.
    Changelog: Have AML remove patches/props for disabled mods and have it not patch disabled mods in the first place

    So now you can disable/enable audio mods and aml will compensate for that
    18
    Updated AML to new magisk template! Note that it's compatible with magisk 18+ now (19 fixes issues with most problem devices anyways)
    18
    So a quick update on the progress for AML v3.0

    As you may already know, it's completely different from aml v2.x in that it uses diffutils to compare files and some hacky scripting to merge conflicts. The problem here is that conflict merging is a manual process and so there's no way for me to script it to be truly automated. Due to this, I'm not going ahead with the v3 beta that uses the diffutils. I took down the beta builds I posted here to eliminate confusion

    Instead, I'm working on updating and revamping/redoing v2.x so it'll become the v3 once it's ready.

    What's changed?
    The mod itself has been completely rewritten - slimmer, more efficient, more idiot proofed.
    The big change for any audio module devs is that the aml.sh logic has changed slightly - it actually makes things much easier now:
    • The extra variables (NAME, LIBDIR, RUNONCE, COUNT) have been removed. There's no need for them anymore and they made things way more confusing then they needed to be.
      The aml.sh script only runs once which is why the above is no longer needed. If you're patching aml files, call them like you would any other - $MODPATH/system/whatever
      This isn't really a change - it behaved the same way before minus how many times the script is run
    • The syntax for patch_cfgs has changed to be more streamlined. the <library_path> actually should point to your library now:
      i.e. /vendor/lib/soundfx/whatever.so
      Note that lack of $MODPATH or any magisk paths - just use what the path would show up as if you were patching an audio_effect file

    Once this becomes stable - I'll update the OP and such with better instructions but as you can see, the changes you would need to make are minimal and make life easier