uxn32 icon indicating copy to clipboard operation
uxn32 copied to clipboard

Can't step program?

Open HazeSystem opened this issue 3 years ago • 4 comments

It seems that no matter what I do, there's no way to pause a program and step through it in the debugger. I've only been able to step through a program that has a bug that causes execution to halt.

HazeSystem avatar Nov 24 '22 16:11 HazeSystem

There's a device you can write to that triggers the debugger. I forgot what it is.

randrew avatar Nov 29 '22 08:11 randrew

Ahh okay, it's writing a non-zero value to .System/debug (#0e). Could you add that to the Readme perhaps? :)

HazeSystem avatar Nov 29 '22 17:11 HazeSystem

It's in the Varvara document, sorta. Maybe @neauoire could change the Varvara documentation so that it says "invokes some emulator-specific debug function" or something?

randrew avatar Dec 27 '22 06:12 randrew

Ah! yeah I went and made it clearer :) #010e DEO is indeed the way to do this.

Sending a non-null byte to the 0x0e port will print the content of the stacks or pause the evaluation if the emulator includes a step-debugger, sending a non-null byte to the 0x0f port will terminate the application.

neauoire avatar Dec 27 '22 17:12 neauoire