-- hp_ret.lua -- return values of the host-port sub-tests. local machine = manager.machine local cpu = machine.devices[':maincpu'] local dbg = machine.debugger if not dbg then print("ERROR: no debugger"); machine:exit(); return end local function bp(addr, msg) dbg:command(string.format('bpset %s,,{ printf "%s a8=%%08X a7=%%08X a9=%%08X a13=%%08X\\n", a8, a7, a9, a13 ; g }', addr, msg)) end bp("3fa71bb0", "RET-BC0") -- L3FA71BC0 rets bp("3fa753c0", "RET-RXCHECK") -- L3FA753D0 rets bp("3fa767d0", "RET-XMITPASS") -- L3FA767E0 rets bp("3fa84fe0", "RET-HOSTPORT") -- after calla L3FA6E4B0 bp("3fa6e4b0", "ENTER-GENERIC") local n = 0 emu.register_frame_done(function() n = n + 1 if n >= tonumber(os.getenv("HP_FRAMES") or "700") then print("done "..n); machine:exit() end end, "vt1200-hp-ret") dbg.visible_cpu = cpu dbg.execution_state = 'run'