diff --git a/examples/chaos.ts b/examples/chaos.ts index 3994d3c..a834e45 100644 --- a/examples/chaos.ts +++ b/examples/chaos.ts @@ -1,3 +1,4 @@ +import fs from 'node:fs'; import { parseArgs } from 'node:util'; import { ChaosLoader } from "../src/index.js"; import { openPort } from "./utils.js"; @@ -49,6 +50,8 @@ const result = await chaos.readMemory(0xA0000000, 1024 * 1024 * 64, { console.timeEnd("readMemory"); console.log(result); +fs.writeFileSync("ff.bin", result.buffer) + /* // test writing to ram await chaos.writeMemory(0xA8000000, Buffer.from([ 0xDE, 0xAD, 0xBE, 0xEE, 0xFF ]));