probe-web / @probe-web/client / index / Core
Class: Core
Defined in: index.ts:779
Direct control of one core, without the debugger's bookkeeping. Get one from Session.core. For breakpoints, stepping and variables use Session.debugger.
Methods
halt()
halt(timeoutMs?): Promise<WireCoreInformation>;Defined in: index.ts:793
Halt the core, waiting up to timeoutMs. Resolves with the program counter.
Parameters
| Parameter | Type | Default value |
|---|---|---|
timeoutMs | number | 500 |
Returns
Promise<WireCoreInformation>
run()
run(): Promise<void>;Defined in: index.ts:797
Resume the core.
Returns
Promise<void>
status()
status(): Promise<WireCoreStatus>;Defined in: index.ts:799
Whether the core is running, halted (and why), sleeping or locked up.
Returns
Promise<WireCoreStatus>
reset()
reset(): Promise<void>;Defined in: index.ts:801
Reset the core and let it run.
Returns
Promise<void>
resetAndHalt()
resetAndHalt(timeoutMs?): Promise<WireCoreInformation>;Defined in: index.ts:803
Reset the core and halt it at the reset vector, waiting up to timeoutMs.
Parameters
| Parameter | Type | Default value |
|---|---|---|
timeoutMs | number | 500 |
Returns
Promise<WireCoreInformation>
readMemory8()
readMemory8(address, count): Promise<Uint8Array<ArrayBufferLike>>;Defined in: index.ts:807
Read count bytes starting at address.
Parameters
| Parameter | Type |
|---|---|
address | number | bigint |
count | number |
Returns
Promise<Uint8Array<ArrayBufferLike>>
readMemory32()
readMemory32(address, count): Promise<Uint32Array<ArrayBufferLike>>;Defined in: index.ts:811
Read count 32-bit words starting at address (which must be word aligned).
Parameters
| Parameter | Type |
|---|---|
address | number | bigint |
count | number |
Returns
Promise<Uint32Array<ArrayBufferLike>>
writeMemory8()
writeMemory8(address, data): Promise<void>;Defined in: index.ts:815
Write bytes starting at address.
Parameters
| Parameter | Type |
|---|---|
address | number | bigint |
data | Uint8Array |
Returns
Promise<void>
writeMemory32()
writeMemory32(address, data): Promise<void>;Defined in: index.ts:819
Write 32-bit words starting at address (which must be word aligned).
Parameters
| Parameter | Type |
|---|---|
address | number | bigint |
data | Uint32Array |
Returns
Promise<void>
dumpCore()
dumpCore(ranges): Promise<WireCoreDump>;Defined in: index.ts:830
Registers plus the memory in ranges, as structured data.
Ranges are [start, end) pairs. Reading is not free — the memory comes back over the probe — so ask for the regions you care about, typically the stack and any RAM a postmortem needs.
Parameters
| Parameter | Type |
|---|---|
ranges | [number | bigint, number | bigint][] |
Returns
Promise<WireCoreDump>
dumpCoreFile()
dumpCoreFile(ranges): Promise<Uint8Array<ArrayBufferLike>>;Defined in: index.ts:840
The same snapshot as a coredump file, in the encoding native probe-rs reads.
Pair it with downloadBytes from @probe-web/artifacts to save it, then open it with the usual tools — a dump taken in a browser is not a dead end.
Parameters
| Parameter | Type |
|---|---|
ranges | [number | bigint, number | bigint][] |
Returns
Promise<Uint8Array<ArrayBufferLike>>