Manager interface
The manager interface allows third-party applications to determine the status of 86Box instances and issue commands to them.
JSON protocol
This is the latest interface protocol, introduced with 86Box 5.0 and used by the built-in VM manager.
The manager attaches to the 86Box instance by launching it with the VMM_86BOX_SOCKET environment variable set to the full path to a named pipe on Windows or a SOCK_STREAM domain socket on Unix-compatible operating systems. The pipe/socket must already exist.
Messages are sent as QString objects via QDataStream version Qt_5_7 (17).
JSON messages are formatted as such:
Name |
Type |
Description |
|---|---|---|
|
String |
|
|
String |
86Box version. |
|
String |
Message name. |
|
Object |
Message parameters, if applicable. Contents are specific to each message. |
The following messages are sent by the 86Box instance to the manager:
Name |
Description |
|---|---|
|
Sent when the main window is blocked due to a modal dialog box being shown. |
|
Sent when the main window is unblocked. |
|
Sent when the emulated machine transitions to a new state. The
|
|
Sent when the emulated machine’s settings are changed. |
|
Sent upon startup to pass the platform-specific window handle through the |
|
Sent when preferences are changed. The manager should respond by sending a |
The following messages can be sent to the instance by the manager:
Name |
Description |
|---|---|
|
Pause or unpause the emulated machine. |
|
Send a Ctrl+Alt+Delete keyboard sequence to the emulated machine. |
|
Open the emulated machine’s Settings window. |
|
Force a reset of the emulated machine. |
|
Send a shutdown request, which displays a confirmation prompt if enabled. |
|
Force a shutdown. |
|
Update preferences. Should be sent to all running instances after receiving a |
Plain text protocol
This earlier protocol, introduced in 86Box 3.3, uses plain text messages instead of structured JSON.
The manager attaches to the 86Box instance by launching it with the 86BOX_MANAGER_SOCKET environment variable set to the full path to a named pipe on Windows or a SOCK_STREAM domain socket on Unix-compatible operating systems. The pipe/socket must already exist.
Commands sent by the manager must be followed by a newline character (\n). The following commands are recognized:
Name |
Description |
|---|---|
|
Open the emulated machine’s Settings window. |
|
Pause or unpause the emulated machine. |
|
Send a Ctrl+Alt+Delete keyboard sequence to the emulated machine. |
|
Force a reset of the emulated machine. |
|
Send a shutdown request, which displays a confirmation prompt if enabled. |
|
Force a shutdown. |
Furthermore, the emulator writes an ASCII 1 to the pipe/socket when the main window is blocked by a modal dialog box, and an ASCII 0 when the window is unblocked.
Window message protocol (Windows-only)
Warning
This protocol is deprecated as of 86Box 5.0 and will be removed in a future release. It is documented here for completeness only.
This earlier protocol, used by the legacy 86Box Manager application., uses Windows window messages sent to the emulator window and received on a specified window handle.
The manager attaches to the 86Box instance by launching it with the -H/--hwnd vm_id,hwnd command line option, where vm_id is an arbitrary 64-bit identifier number and hwnd is the window handle to receive messages on, both in hexadecimal without the 0x prefix.
All window messages sent by the emulator include the main window’s handle in LPARAM, including WM_SENDHWND which is sent on startup and can be used to match the window handle to the identifier provided in the command line.
Name |
Value |
Sent by |
Description |
|---|---|---|---|
|
|
Manager |
Open the emulated machine’s Settings window. |
|
|
Manager |
Pause or unpause the emulated machine. |
|
|
86Box |
Sent when the emulator window is first displayed. |
|
|
Manager |
Force a reset of the emulated machine. |
|
|
Manager |
Trigger a shutdown. |
|
|
Manager |
Send a Ctrl+Alt+Delete keyboard sequence to the emulated machine. |
|
|
86Box |
Sent when the emulated machine is paused ( |
|
|
86Box |
Sent when the emulator is waiting for user input in a modal dialog box ( |
|
|
86Box |
Sent when the emulated machine shuts down. |