Module Control
About 1720 wordsAbout 6 min
2025-01-11
🎯 Module control function allows you to customize the display and behavior of the module list, optimizing module management experience. Through these settings, you can control module update checks, sorting optimization, display information, etc., making module management more efficient and convenient. At the same time, this also includes advanced setting functions for APM (Android Patch Module) and KPM (Kernel Patch Module).
Function Overview
Module control includes the following core functions:
- Disable Module Update Check: Turn off automatic update check for system modules
- Fold System Modules: Click module card to expand/collapse operation buttons
- Module Sorting Optimization: Pin system modules with WebUI and Action to top
- Show More Info: Display module ID and size in module list
- APM Batch Install Full Process: Use full process for batch installation of system modules
- KPM Auto Load Config: Automatically load specified KPM modules when application starts
- KPM File Management: Import, delete and manage KPM files
- Auto Backup Module List: Automatically backup existing modules during batch installation
Disable Module Update Check
Function Description
Disable automatic update check function for system modules, avoiding module update checks at startup.
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Disable Module Update Check | Turn off automatic update check for system modules | Off | As needed |
Usage Scenes
Applicable Scenes
- Make page more concise
- Wish to keep current module version, avoiding accidental updates
- Using specific version of module, don't want to be disturbed by update prompts
Usage Example
# Config stored in SharedPreferences
# Key: disable_module_update_check
# Default: false
# After enabling, system modules will no longer automatically check for updatesFold System Modules
Function Description
When enabled, system module cards will be folded by default. Clicking the card can expand/collapse operation buttons (such as enable/disable, uninstall, etc.). This makes the module list more concise and reduces visual clutter.
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Fold System Modules | Click module card to expand/collapse operations | Off | On (when many modules) |
Usage Scenes
Applicable Scenes
- Large number of installed modules, wish to simplify interface
- Reduce risk of accidental touch on operation buttons
- Wish to quickly browse module list without frequent operations
Interaction Method
- Default State: Module card folded, showing only module name and basic info
- Click to Expand: Click card to expand, showing complete operation buttons
- Click Again: Click card again to refold
Usage Example
# Config stored in SharedPreferences
# Key: fold_system_module
# Default: false
# After enabling, module cards will default to folded stateModule Sorting Optimization
Function Description
When module sorting optimization is enabled, system modules with WebUI/META and Action will automatically be ranked at the top of the list, facilitating quick access to modules with visual interfaces and shortcut operations.
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Module Sorting Optimization | Pin modules with WebUI/META and Action to top | On | On |
Sorting Rules
Sorting optimization arranges in following priority:
Module Loading Priority (High to Low)
- META Priority:
METAmodules (Highest priority, usually for global config, shared resources or core functions) - First Priority: Modules with both WebUI and Action
- Second Priority: Modules with only WebUI
- Third Priority: Modules with only Action
- Default Priority: Ordinary modules (Regular modules without WebUI or Action)
Usage Scenes
Applicable Scenes
- Wish to quickly access modules with WebUI/META (e.g., module setting page)
- Need to frequently use module shortcut operation functions
- Large number of modules, wish to optimize access efficiency
Show More Info
Function Description
Display detailed information of modules in module list, including module ID and module size, helping you better understand basic module info.
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Show Detailed Info | Show module ID and size | On | On |
Display Content
When enabled, displays following info:
- Module ID: Unique identifier of module in system
- Module Size: Storage space occupied by module
Usage Scenes
Applicable Scenes
- Need to view module ID for debugging or troubleshooting
- Concerned about module space usage, optimizing storage use
- Distinguish modules with same name or similar modules
- Developers or advanced users
Display Effect
# Before enabling
Module Name
Module Description Info
# After enabling
Module Name
Module ID: com.example.module
Module Size: 2.5 MB
Module Description InfoMinimalist List Bottom Bar
When enabled, APM and KPM module lists will only show icons and not text, minimalist but not simple.
Undo Delete Function
Function Description
FolkPatch introduces a module deletion undo function. When you delete a module in the manager, the module is not immediately removed from the file system, but is marked as "pending deletion". As long as you have not rebooted the device to make the changes take effect, you can undo the deletion operation at any time and restore the module to its original state.
Usage Scenes
Applicable Scenes
- Misoperation Protection: If you accidentally clicked the delete button, you can recover immediately.
- Temporary Adjustment: Want to test the effect of deleting a module (although deletion requires a reboot to take effect, this function gives you a chance to regret at the last moment).
- Peace of Mind: Knowing there is a "regret medicine" makes operations more reassuring.
Operation Method
- In the module list, click the Delete/Uninstall button of the module.
- The module status changes to Deleted (Pending Reboot), and the delete button changes to an Undo button (usually an undo icon or text prompt).
- Click the Undo button, and the module can be restored to its normal state.
- If you are sure you want to delete it, just Reboot the Device, and the module will be physically removed during system startup.
APM Batch Install Full Process
Function Description
APM batch install function allows you to install multiple system modules at once. When full process mode is enabled, batch installation will use the complete installation process, supporting modules that require volume key interaction.
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Full Batch Install Process | Use full process for system module batch installation | Off | Depends on module type |
Usage Modes
Quick Install Mode (Default)
- Applicable Modules: Simple modules not requiring volume key interaction
- Features: Quick batch install, no user interaction
- Suitable for: Simultaneous installation of large number of simple modules
Full Process Mode
- Applicable Modules: Complex modules requiring volume key interaction or confirmation
- Features: Install one by one, support full interaction process
- Suitable for: Modules requiring user confirmation or configuration
Usage Scenes
Usage Suggestion
- Simple Module Batch Install: Disable full process, use quick mode to improve efficiency
- Complex Module Batch Install: Enable full process, ensure modules install correctly
- Mixed Module Install: Recommended to install in batches, simple modules use quick mode, complex modules use full process
KPM Auto Load Config
Function Description
KPM (Kernel Patch Module) auto load function allows you to automatically load specified KPM modules when application starts, without manual operation. This method is more convenient than directly embedding into kernel, especially suitable for modules that can only be loaded temporarily.
Core Features
- Auto Startup Load: Automatically load configured KPM modules when app starts
- Flexible Configuration: Support both visual and JSON configuration modes
- File Management: Automatically import and manage KPM files
- State Saving: Configuration persisted, automatically effective after restart
Configuration Method
Visual Mode (Recommended)
Visual mode provides friendly graphical interface, suitable for most users:
- Add KPM: Click "Add KPM" button, select
.kpmfile - View List: Show all added KPM modules and paths
- Enable Switch: Turn on "Enable Auto Load" switch
- Save Config: Click "Save Config" button
JSON Mode
JSON mode suitable for advanced users, can directly edit configuration:
{
"enabled": true,
"kpmPaths": [
"/data/data/me.bmax.apatch/files/autoload_kpms/module1.kpm",
"/data/data/me.bmax.apatch/files/autoload_kpms/module2.kpm"
]
}Config Field Description:
| Field | Type | Description |
|---|---|---|
enabled | Boolean | Whether to enable auto load |
kpmPaths | Array<String> | KPM file path array |
Setting Options
| Option | Description | Default | Recommended |
|---|---|---|---|
| Enable Auto Load | Automatically load KPM modules at app startup | Off | As needed |
| Config JSON | JSON format configuration file | Empty Config | See example below |
| Visual Mode/JSON Mode | Configuration interface mode | Visual Mode | Recommended Visual Mode |
Usage Scenes
Applicable Scenes
- KPM Preventing Partition Modification: Some KPMs may cause boot failure if embedded in kernel, can only be loaded temporarily
- Quick Test Module: Test module effect via auto load before deciding to embed in kernel
- Not Modify BOOT Partition: If don't want to modify BOOT partition, can use auto load config
- Development Debugging: Frequently load and test different KPM modules
Loading Flow
KPM auto loading flow at app startup:
- App Startup: Check auto load config
- Read Config: Load
kpm_autoload_config.json - Check Switch: If
enabledistrue, continue loading - Verify File: Check if each KPM file exists
- Load Module: Load KPM modules one by one
- UI Refresh: User needs to manually pull down to refresh to view loading status
Notes
Important Hint
- Manual Refresh: Remember to manually pull down to refresh after loading completes to check if modules loaded correctly
- File Existence: Ensure configured KPM file path is correct and file exists
- Startup Time: Enabling auto load will increase app startup time
- Module Compatibility: Ensure KPM module is compatible with current kernel version
KPM Module Warning
When accessing KPM page for first time, important warning will be shown:
Kernel modules directly modify Boot implementation. Unlike system modules, they lack good recovery mechanisms. If problems occur, you can only fix by entering Fastboot. Recommended to load module first to ensure no problems, then embed into Boot. If module can only be used via loading, can try auto KPM module load function. If you don't understand kernel modules, please do not use this function!
Security Warning
- High Risk Operation: KPM modules directly modify Boot, high risk
- Lack Recovery Mechanism: Unlike system modules, KPM errors can only be fixed via Fastboot
- Recommended Flow: Load test first, embed into Boot after confirming no errors
- Use with Caution: If you don't understand kernel modules, please do not use this function
Related Settings
- Backup & Restore - Set module auto backup
- Settings Overview - View all setting categories
Get Help
If you encounter problems when using module control function:
- Check "FAQ" section on this page
- Visit FAQ
- Join community group for help:
- QQ: 1074588103 (FolkPatch Exchange Group)
- Telegram: FolkPatch
Tip
Module Control, APM and KPM are powerful functions of FolkPatch, recommended to fully understand related knowledge and risks before use, especially for KPM module operations.
Copyright
Copyright Ownership:FolkPatch Team
License under:Attribution 4.0 International (CC-BY-4.0)
