Skip to content

Feature Request: Expose non-resetting “Detach Disk Image” action through MCP #125

Description

@c64cryptoboy

Feature request

Please expose the existing GUI Detach Disk Image action through MCP as a separate tool from retro_media_detach.

Motivation

The current MCP tool:

retro_media_detach

performs the equivalent of the GUI’s Detach Everything action. On C64, this triggers a power-cycle reset, erasing the current machine state. This makes it unsuitable for workflows that need to swap or remove a disk while preserving RAM and execution state.

The Retro Debugger GUI already provides a separate Detach Disk Image action that removes the mounted disk without resetting the emulator.

Source confirmation

The current MCP route is:

retro_media_detach
→ <platform>/detachEverything
→ debuggerApi->DetachEverything()

Relevant locations:

  • src/Remote/MCP/CMCPServer.cpp
  • src/Remote/CDebuggerServerApi.cpp

For the C64 VICE backend, detach-everything ultimately calls:

machine_trigger_reset(MACHINE_RESET_MODE_POWER_CYCLE);

The existing GUI disk-only path is:

Detach Disk Image
→ CMainMenuBar::DetachDiskImage()
→ CDebugInterfaceVice::DetachDriveDisk()
→ file_system_detach_disk(8, 0)

This path does not reset the C64.

Suggested MCP API

Add a separate tool, for example:

retro_disk_detach

with parameters such as:

{
 "platform": "c64",
 "device": 8
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions