Generates a single data URI that runs a Game Boy emulator entirely in the browser — no server required. Just paste the URL into your address bar.
Uses binjgb compiled to WebAssembly.
python generate_url.py <rom_file> [-o output_file]Arguments:
rom_file— Path to a.gbROM file-o, --output— Output file for the URL (default:output.txt)
Examples:
python generate_url.py drmario.gb
python generate_url.py tetris.gb -o tetris_url.txtOpen the resulting URL in any modern browser (Chrome, Firefox, Edge, Safari).
- Embeds the ROM, WASM emulator, and UI assets into a single HTML page
- Gzip-compresses the HTML and base64-encodes it
- Wraps it in a bootstrapper that decompresses and renders the page
- Outputs the whole thing as a
data:text/html;base64,...URI