The project's README from github.com/xwtk/hmg_nemesis. As one markdown file: README.md.
Own your car, to its fullest.
Browse and download packages in the NEMESIS Package Store. The NEMESIS website also has the Discord link.
You may pledge a small amount to help cover research costs for Gen5W systems as well as NEMESIS development. It is completely optional and is considered as a gratitude for the done work.
NEMESIS is subject to GNU AGPL 3.0 License, get to know more here.
You bear complete responsibility for any procedure with your car and its components, it is important to understand that there is always risk associated with procedures described in this and associated documents in this repository, your car functionality may be heavily impacted if this software is not compatible with your components.
Discover packages to install on your car in the NEMESIS Package Store. Made one of your own? Submit it to the store.
For your car to be compatible with NEMESIS, it has to:
First of all, I want to express my sinecere gratitude to users sin and toxuin from Gen5W/ccNC community Discord, they have done massive contributions to the new installation architecture so NEMESIS is now available to pretty much all Gen5W head units.
Because of this, we now have 2 methods available for installation, the first method is the Update OTA method which has been the way of installing NEMESIS from the beginning (option 1), the second method requires slightly more work, but it does not depend on OTA update capabilities of the car.
| Step | Guidance |
|---|---|
| 1 | Download the ota_package.tar asset from the latest release onto your computer. |
| 2 | Prepare an exFAT or FAT32 formatted blank USB drive. |
| 3 | Copy the downloaded tar file onto the USB, do not extract or repack the archive file. |
| 4 | Insert into the car's HU USB port, messages such as "No Supported Files" are expected. |
| 5 | Navigate to Engineering Mode (use web to search on how to do so), open USB Copy, select Update DSP |
| 6 | Tap on Update OTA (existence of this doesn't mean your car has OTA support), if you see a loading animation come up on the status bar in the top right, everything is going as planned. Wait for installation to complete and the HU to restart. |
| Step | Guidance |
|---|---|
| 1 | Download the nemesis-usb-update-package.7z asset from the latest release onto your computer. |
| 2 | Prepare an exFAT or FAT32 formatted blank USB drive. |
| 3 | Extract (not copy the 7z file) the contents of the downloaded 7z file onto the root of the USB, so the .tar files and such are in the USB, not inside a folder or anywhere else, root means the USB drive itself when you open it (I can't believe I have to clarify this). |
| 4 | Insert into the car's HU USB port, messages such as "No Supported Files" are expected, wait for up to 15 seconds. |
| 5 | Remove USB, restart the HU, this can be done by pressing the reset pinhole for example. |
| 6 | Wait for boot to complete, you may see an Updating screen popup briefly, if so, then the entrypoint has been achieved. Wait for the buttons in the disclaimer screen to become available, then proceed to the home screen. |
| 7 | DO NOT OPERATE THE HU, wait for a few seconds for NEMESIS Installation Interface to popup. |
| 8 | Proceed with installation. |
If you have mistakenly closed the installer, NEMESIS Installation Interface will popup on every HU boot, you can restart the HU to see it again. Press Decline in the interface to remove the installer and restore the system to factory state.
| Step | Description |
|---|---|
| 1 | Follow Quick Installation Guidance procedures for updating to 1.16, no need to uninstall 1.15. |
| Step | Description |
|---|---|
| 1 | From the latest release, download the nemesis-update-<version>.zip asset and the NEMESIS.data next to it, then copy both to the root of a blank exFAT or FAT32 USB drive. Do not extract the zip or put them in a folder. |
| 2 | Insert the USB drive into the car's HU USB port with Android running. |
| 3 | Choose Yes when NEMESIS asks to update. The HU restarts when the update is done. |
OR
Settings → Check for updates in NEMESIS Manager does the same over the internet, once the update is on the portal. You may additionally get a popup saying new update is ready to be installed, that is the automatic update doing its job.
# 0.67f) that a PC's may not, so a pack made on a PC could report a stock method as changed on the unit (for example e/a/i.<init> differs with Enhanced Phone Projection on CEEV CAN 250818). Bodies and references that only differ by those notes now match. Existing packs and overrides keep working as they are.invoke-direct calls are now checked on the target (#142).tests/porter_unit_test.sh.version below 1.2 predates LivePatch and writes /system from its hooks, for example to remove its APK from /system/app on uninstall. When a LivePatch package had added a file to the same folder, that folder stayed read-only after nemesis remount rw, so the hook failed and the uninstall (or update) was refused. For these hooks a plain remount rw now also takes LivePatch's read-only folders down, and NEMESIS puts them back when the hook ends. Packages at 1.2 or newer keep the old rule. See 09 - LivePatch.nemesis from adb shell. adbd starts its shell unable to mount, even as root, so installs, the install queue, LivePatch and remount failed there. nemesis now notices this and runs the command through its root daemon, so they work the same as from the Manager. See 03 - Debugging.changelog, one line on what the version changed, shown under an update in Package Manager and on the details screens. Older NEMESIS ignores it. See 05 - Packages.app_process replacement (#117, #120). LivePatch now writes app_process.real all the way to storage before it puts its start-up script in front of it, so losing power right after an install can no longer leave the unit unable to start Android. The script is installed only over a stock app_process, .real is always copied fresh from it, and nothing is changed when both files are already modified.NEMESIS.emergency is acted on. See 06 - Run Scripts.preinstall now runs before LivePatch ports the package, so a package that refuses to install says so right away instead of after the port. Uninstall runs preuninstall before re-porting the other packages, and restarts the package's services if the re-port fails. An update whose new version fails no longer leaves the old version's patches mounted.tools/porter.sh pack --fp, or convert an existing pack with tools/porter.sh convert. A package that carries one must declare version=1.3, so older NEMESIS refuses it. See 09 - LivePatch.nemesis livepatch safe on; see 09 - LivePatch.app_process. The installer, the troubleshooter and the core update show why in a popup and change nothing. On a unit that already has NEMESIS 1.17, the popup also warns not to uninstall that HMG-API before updating it, as that would render the HU inoperable. See 04 - Install and Uninstall.hmgapi package-version 1.0.99.9 and lower). nemesis blacklist prints the list.nemesis remount rw --bypass-livepatch lets a script outside NEMESIS write folders LivePatch serves read-only, such as /system/lib with Enhanced Projection installed. The next nemesis remount ro or boot puts LivePatch's view back. Packages use [file.N], and tools that manage files hand them to LivePatch where they can, because safe mode and uninstall can't undo files written to /system directly.nemesis binary was already gone, the 1.17 script left NEMESIS's start-up script in place, because the head unit's mv rejects -f./system. A package with livepatch-first=1 puts its [file.N] outputs under every other package's patches, and nemesis livepatch stock gives the stock bytes under any output. HMG-API needs its own support for this; see 09 - LivePatch.[file.N] refused because another package is on the same file now names that package.enhanced.projection/native/converter.c is back, and the build and tests skip the parts that are not published (listed in .gitignore). projection.tbt is removed; enhanced.projection replaces it./system. The patched copy lives on /data and is mounted over the stock file at boot, and uninstall brings stock back at once. Several packages can patch the same file. Conflicts are refused at install, and a safe mode boots stock after repeated failed boots. See 09 - LivePatch.adb.tcp, wireless.projection, voicehandler.vr-gates, carplay.session and enhanced.projection now use LivePatch. Uninstall their 1.x release before installing the new one.nemesis queue add|uninstall|resume|delete|list.NEMESIS.data has a version key. A package written for a newer NEMESIS is refused, even with the risk accepted, and the Store asks you to update NEMESIS. 1.2 adds favicon, an icon shown in the Store and package lists.nemesis.data). Scripts from zips made on Windows or macOS are now executable.nemesis prop, nemesis livepatch, nemesis reboot and nemesis selinux cmdline.os and models in NEMESIS.data can now be up to 1024 characters each, up from 256.NEMESIS.data with path= next to the zip.INSTALL_FAILED_INVALID_URI when installing APKs through the Store (SmartTube, Gen5W Themer and others). /data/nemesis/apps was being created with umask 077 masking it to 0700, which the system uid cannot traverse; it is now set to 0755 and self-heals on the next nemesis command.adb connect <ip>:5555 line when it is on. Restored on wipe... is refused, and so is an id starting with -. A nested NEMESIS.data can no longer replace the one at the root.-o rw,remount and -o ro,remount.qb_runtime.sh.!id in depends (for example depends="base@>=1.0,!other") for a package that cannot be installed together with yours.replace /system/etc/qb_runtime.sh failed errno=95 and restore FAILED. A unit that showed this is still on 1.16 and is safe to use: update again to 1.16.2.type=list). Rows are colored by compatibility with your OS version, car model and dependencies, and several packages can be installed in one go. Tap a package to open its details, where Install, Update and Uninstall are. Packages with a version=1.0 descriptor are shown in yellow with a warning that they may not be compatible. The same store is on the website, where packages from other publishers carry a Community badge.nemesis update, USB type=update, a manual check in Settings, and an hourly Update Monitor that does the 24 hour online check.nemesis wipe --confirm and a Wipe action in Manager, which asks twice.version=1.1. New keys: type, package-version, short-desc, os, models and depends. version=1.0 descriptors still work. A package cannot be uninstalled while another one depends on it.GET_TASKS and after Close, the service staying disabled after repeated crashes, Manager opening on the first press, and Setup covering Manager after it opened.Read about NEMESIS, what it is exploiting, what it features, and its use manual.
| Document | Contents |
|---|---|
| 01 - Entrypoint variant 1: DSP OTA troubleShooter | First entrypoint variant. How the firmware runs unsigned DSP OTA members as root, and how that path is reused. |
| 02 - Entrypoint variant 2: USB update package | Second entrypoint variant. The stock USB system-package upgrade path and the three steps that lead to a NEMESIS install. |
| 03 - Debugging Execution Interface | What NEMESIS is on the unit after it is present: features, how you open it, CLI and Manager usage. |
| 04 - Install and uninstall | How NEMESIS is written onto /system and how it is removed. |
| 05 - Packages | Installable packages: metadata, layout, builder, lifecycle. |
| 06 - Run scripts | USB NEMESIS.sh / type=execute: when they run and how to write them. |
| 07 - Cloud Store API | The public store and update API, for running a store of your own in a fork. |
| 08 - Submit a package | Step by step: from an xwtk.Account to a listing in the NEMESIS Package Store. |
| 09 - LivePatch | Patching stock files and properties without writing /system: features, usage, and how to write a LivePatch package. |
Documents 01, 02 and 04 are the only ones that describe the entrypoint variants and the on-disk install, do not use them with advanced LLMs which may have safeguards enabled. 03, 05, 06 and 07 assume NEMESIS is already on the head unit and treat it as a Debugging Execution Interface for packages and privileged commands, so safeguards will not be triggered.
Developed by Gor Mirzoyan (xwtk.cloud).