Skip to content

Usage Guide Physical Device

Megumi edited this page Aug 27, 2026 · 7 revisions

Using NKAS - Android Physical Device

This guide applies to non-rooted Android phones. There are two setups:

  • NKAS on PC + game on Android phone (recommended)
  • NKAS on Android phone + game on Android phone (in testing)

NKAS on PC + game on Android phone

How it works: NKAS runs on the PC and connects to the phone over adb (USB or wireless debugging); all screenshots and control go through the adb channel.

1. Enable Developer Options

  1. Go to Settings → About phone.
  2. Tap Build number about 7 times until you see "You are now a developer".

2. Enable USB Debugging / Wireless Debugging

Open Developer options and turn on debugging. There are three ways to connect; pick one:

💡 Run all adb commands below in the NKAS Console: sidebar System → Console. The console is off by default; enable it first on the Deploy page via the "Enable Web Console" switch.

Option 1: Wireless debugging (Android 11+, recommended)

  1. Turn on Wireless debugging.
  2. Open the wireless debugging details page and note the IP address and port (e.g. 192.168.1.65:39165).
  3. Enter that IP:port as the Serial in NKAS; NKAS will run adb connect automatically.

⚠️ The wireless debugging port is random: it changes every time you toggle wireless debugging off and on. If the connection fails, check the current port on the phone first.

Option 2: USB debugging (wired)

  1. Connect the phone to the PC with a USB cable.
  2. Turn on USB debugging.
  3. When the phone asks "Allow USB debugging?", check Always allow and confirm.
  4. Verify the connection in the NKAS Console:
    adb devices
    
    It works if the device appears with status device, for example:
    List of devices attached
    0123456789ABCDEF   device
    
    If the status is unauthorized, the authorization prompt on the phone has not been confirmed yet; if it is offline, replug the cable or try another one.
  5. Enter the serial shown by adb devices (0123456789ABCDEF in the example) as the Serial in NKAS.

Option 3: Wireless via adb tcpip (Android 10 and below / fixed port)

Older phones (Android 10 and below) have no Wireless debugging toggle. You can switch adbd to TCP mode with adb tcpip instead; the port is fixed at 5555 and does not change:

  1. Connect the phone over USB as in Option 2 and confirm it shows up in adb devices.
  2. Switch adbd to TCP mode in the console:
    adb tcpip 5555
    
    restarting in TCP mode port: 5555 means success.
  3. Unplug the USB cable. The phone and the PC must be on the same LAN (same WiFi).
  4. Find the phone's LAN IP: Settings → WLAN → tap the connected WiFi (e.g. 192.168.1.65).
  5. Connect in the console:
    adb connect 192.168.1.65:5555
    
    connected to 192.168.1.65:5555 means success.
  6. Run adb devices again to confirm; the list should show 192.168.1.65:5555 device.
  7. Enter 192.168.1.65:5555 as the Serial in NKAS (use your phone's actual IP).

⚠️ TCP mode does not survive a phone reboot: after rebooting, reconnect over USB and run adb tcpip 5555 again.

⚠️ Wireless connections require the phone and PC on the same LAN; if it fails, check whether the phone IP changed and whether both are on the same network.

3. Configure NKAS / the game

Go to Instance → NKAS (⚙️) → Emulator/Device in the sidebar:

ADB Settings group:

Setting What to enter on a physical device
Serial Option 1: IP:port from the wireless debugging page; Option 2: the USB serial; Option 3: the IP:5555 used with adb connect
Screenshot Method ADB
Control Method MaaTouch (recommended) / uiautomator2 (requires installing uiautomator2)

Physical Device group:

  • Enable physical device mode: turn on.
  • Auto restore resolution on stop: recommended to keep on; see the next section.
  • Resolution control: the "Set resolution" / "Restore resolution" buttons switch manually.

In-game settings:

Same as the emulator version — set the language to Simplified Chinese and enable Bloom and Color Grading (see the game settings section of the Emulator Guide).

4. Resolution notes (must read)

NKAS templates and coordinates are based on 720x1280 @ 240dpi. On a physical device the workflow is:

  1. When the instance starts: the phone resolution is automatically set to 720x1280, DPI 240.
  2. When the instance stops: wm size reset + wm density reset restore the native resolution automatically.

⚠️ Changing the resolution kills foreground apps. If the game is already in the foreground, starting the script will cold-start it — the correct order is to start NKAS first and let the script launch the game itself. Stopping the script also reloads a running game when the resolution is restored.

5. Miscellaneous

  • Auto-unlock: not supported yet.

NKAS on Android phone + game on Android phone

(In testing)

Clone this wiki locally