ppsspp_write8
Write a single unsigned byte (0-255) to a PSP physical memory address. Use for cheat codes, debug pokes, and game-state mutations.
Instructions
PURPOSE: Write an unsigned byte (0-255) to PSP memory at the given physical address. USAGE: Use for single-byte cheats, debug pokes, game-state mutations. For 16/32-bit use ppsspp_write16/write32; for spans use ppsspp_write_range. BEHAVIOR: DESTRUCTIVE: overwrites whatever was at address with no undo. Direct memory write — no hardware mediation. Returns an error if the address is outside valid memory or value > 255. RETURNS: Single line 'Wrote VAL → ADDR_HEX'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| address | Yes | PSP physical address. PSP memory layout: user RAM starts at 0x08800000 (or 0x08000000 — varies by firmware allocation), kernel RAM at 0x08000000-0x087FFFFF, VRAM at 0x04000000-0x041FFFFF, scratchpad at 0x00010000-0x00013FFF, hardware regs at 0xBC000000+. Most game state lives in user RAM. Note PPSSPP may also accept 0x88xxxxxx kernel-mode mirrors of the same physical memory. | |
| value | Yes | Byte value (0-255). |
Implementation Reference
- src/tools.ts:146-162 (registration)The 'ppsspp_write8' tool is registered in the TOOLS array with its name, description, and inputSchema (address + value 0-255).
{ name: "ppsspp_write8", description: "PURPOSE: Write an unsigned byte (0-255) to PSP memory at the given physical address. " + "USAGE: Use for single-byte cheats, debug pokes, game-state mutations. For 16/32-bit use ppsspp_write16/write32; for spans use ppsspp_write_range. " + "BEHAVIOR: DESTRUCTIVE: overwrites whatever was at `address` with no undo. Direct memory write — no hardware mediation. Returns an error if the address is outside valid memory or value > 255. " + "RETURNS: Single line 'Wrote VAL → ADDR_HEX'.", inputSchema: { type: "object", required: ["address", "value"], properties: { address: { type: "integer", minimum: 0, description: ADDRESS_PARAM_DESC }, value: { type: "integer", minimum: 0, maximum: 255, description: "Byte value (0-255)." }, }, additionalProperties: false, }, }, - src/tools.ts:457-460 (handler)The handler for 'ppsspp_write8' calls pp.call('memory.write_u8', ...) to write a byte to PSP memory, then returns a confirmation string.
case "ppsspp_write8": { await pp.call("memory.write_u8", { address: a(), value: p.value }); return ok(`Wrote ${fmtHex(p.value)} → ${addrHex(a())}`); }