![]() |
![]() |
#1 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
Pre-release vscode amiga assembly with WinUAE integration
If some of you are interested in testing the extension with WinUAE integration, I've made a pre-release :
https://github.com/prb28/vscode-amig...eases/tag/0.21 I'll be glad to have some feedback to tackle the bugs. |
![]() |
![]() |
#2 |
Registered User
Join Date: Feb 2020
Location: Germany
Posts: 195
|
This is really awesome.When I am in debug mode and click with the mouse into the window of WinUAE I get this code in the VS code.
Pro: - The feature "Step Out" at debugging works fine! - Key Shift+F12 trigger the VSCode debugger Bugs: - Breakpoint at first line dont work - mouse click in WinUAE stop at strange code - Setting "stopOnEntry" not work - Emulation reset not work as like as FS-UAE Last edited by JoeJoe; 12 November 2020 at 11:06. Reason: more content ;) |
![]() |
![]() |
#3 |
Oldtimer
![]() Join Date: Nov 2010
Location: VXO / Sweden
Posts: 153
|
Cool, I got it running in Ubuntu 20.05 with wine 5.5!
But not without problems, can you implement a configurable delay before the extension tries to connect to WinUAE or retry after a short time? As it is now, it tries to connect to the port before WinUAE is up and listening to the port resulting in "connect ECONNREFUSED 127.0.0.1:2345"! |
![]() |
![]() |
#4 | ||
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
Quote:
I think I should make the exception mask, configurable in the launch settings. I think it's some trigger launched at the click that is caught as an exception. Does work with FS-UAE too ![]() I'll try this, it's a surprise for me ! Quote:
Thanks for the test ! |
||
![]() |
![]() |
#5 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
|
![]() |
![]() |
#6 |
OCS forever!
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 418
|
The example workspace works good. When I try and do my own project (a500 config from makefile) with what I think are the correct launch.json settings I get the "connect ECONREFUSED" message while the winuae is still booting up.
Edit: My launch.json below (and fsuae entries that work for debugging for comparing). I replaced my winuae.exe with yours and added a A500Debug.uae to point to correct ROMs etc. I call my exe "demo" so SYS: Demo launches it. Code:
{ "version": "0.2.0", "configurations": [ { "type": "winuae", "request": "launch", "name": "WinUAE Debug", "buildWorkspace": false, "stopOnEntry": true, "serverName": "localhost", "serverPort": 2345, "startEmulator": true, "trace": true, "emulator": "${workspaceFolder}\\..\\..\\WinUAE\\winuae.exe", "emulatorWorkingDir": "${workspaceFolder}\\..\\..\\WinUAE", "program": "${workspaceFolder}\\dh0\\Demo", "options": [ "-config=A500Debug.UAE", "-s", "debugging_trigger=sys:Demo", "-s", "filesystem=rw,dh0:${workspaceFolder}\\dh0" ] }, { "type": "fs-uae-run", "request": "launch", "name": "WINDOWS Run", "buildWorkspace": false, "emulator": "${workspaceFolder}\\..\\..\\ToolChain\\VSCodeExt-bin\\fs-uae.exe", "emulatorWorkingDir": "${workspaceFolder}\\..\\..\\ToolChain\\VSCodeExt-bin", "options": [ "--hard_drive_0=${workspaceFolder}\\dh0", "--joystick_port_1=none", "--amiga_model=A500", "--chip_memory=512", "--slow_memory=512", "--kickstarts-dir=${workspaceFolder}\\..\\..\\WinUAE\\Roms" ] }, { "type": "fs-uae", "request": "launch", "name": "WINDOWS Debug", "stopOnEntry": true, "serverName": "localhost", "serverPort": 6860, "trace": false, "startEmulator": true, "buildWorkspace": false, "emulator": "${workspaceFolder}\\..\\..\\ToolChain\\VSCodeExt-bin\\fs-uae.exe", "emulatorWorkingDir": "${workspaceFolder}\\..\\..\\ToolChain\\VSCodeExt-bin", "program": "${workspaceFolder}\\dh0\\Demo", "options": [ "--hard_drive_0=${workspaceFolder}\\dh0", "--joystick_port_1=none", "--amiga_model=A4000/040", "--kickstarts-dir=${workspaceFolder}\\..\\..\\WinUAE\\Roms", "--remote_debugger=200", "--use_remote_debugger=true", "--automatic_input_grab=0" ] }, ] } Last edited by Antiriad_UK; 12 November 2020 at 23:51. |
![]() |
![]() |
#7 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
@Antiriad_uk
In your config A500Debug.uae you must add some options that are in the workspace\bin\default.uae file, at least : debugging_features=gdbserver. I think the sys:Demomust be exactly the same command in the startup-sequence. (not sure, I did not try changing the path to see if it still works). It may work as the standard winuae debugger trigger. edit : unwanted smilies ![]() |
![]() |
![]() |
#8 | |
OCS forever!
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 418
|
Quote:
|
|
![]() |
![]() |
#9 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
New "pre" version at the same place :
- StopOnEntry fixed. - Use of UAEexit at the end of the example program startup-sequence. - New launch parameters : *"exceptionMask": 8188,NB: There is something wrong with my gencop example program, it does not exits to the cli normally. |
![]() |
![]() |
#10 |
OCS forever!
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 418
|
Still having some issues with this. If stoponentry is true then it stops on entry and I can single step through the source ok. But if I try and stop on a custom breakpoint the program pauses but doesn't show anything in the source and the CPU call stack says "error during frame selection: 0"
Edit: Hmm actually 0.21 breaks the fsuae debug as well. If I roll back to 0.20 it works again. Edit: I'll zip up a test project and PM you the details. Probably easier! Last edited by Antiriad_UK; 15 November 2020 at 22:24. |
![]() |
![]() |
#11 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
New pre-release to fix the bugs found by Antiriad_UK : https://github.com/prb28/vscode-amig.../tag/0.21_pre3.
|
![]() |
![]() |
#12 | |
Registered User
Join Date: Jun 2020
Location: Brno
Posts: 90
|
Quote:
Everything works just fine for me. WinUAE launches, my Amiga executable runs, breakpoints trigger, stepping in code works. So far I've encountered only one minor issue: When I place a breakpoint, the executable stops but at a different location (yet inside my code). If I press continue then it stops at the correct breakpoint. when I remove my breakpoint and later add it back again, the behaviour repeats. No big issue -- just an annoyance :-) The fact that using WinUAE allows me to run my code at the normal speed under the debugger is just great (emulation is slowed down under fs-uae when debugging). Thank you! Your addon is just the pure gold! Last edited by defor; 19 November 2020 at 13:53. |
|
![]() |
![]() |
#13 |
Registered User
Join Date: Feb 2020
Location: Germany
Posts: 195
|
I can only agree that now the extension works. My reported errors are no longer occurring. Thank you very much for that!
Is there a possibility to display the performance per frame like the "c extension" of BartmanAbyss? |
![]() |
![]() |
#14 | |
OCS forever!
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 418
|
Quote:
|
|
![]() |
![]() |
#15 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
|
![]() |
![]() |
#16 |
OCS forever!
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 418
|
Yes it happens in the code I sent. For it to occur the program must be running:
1. Set no breakpoints 2. Run code under debug 3. Whilst running create a new breakpoint in the level3 int handler in template.asm (say line 360) 4. Will jump into the debugger at a "random" line 5. Press f5 once 6 Will now be at the correct breakpoint |
![]() |
![]() |
#17 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
@antiriad thanks, I can reproduce it.
|
![]() |
![]() |
#18 |
Registered User
Join Date: Feb 2020
Location: Germany
Posts: 195
|
The parameter "exceptionMask" is really cool! Can the pointer to the command that caused the error be positioned correctly? But I think that this is not so easy.
Is this also possible for the FS-UAE version? Here again a few wishes: - memory breakpoints - Reset Emulator (For FS-UAE it is ALT-R/T) Thanks and greetings JoeJoe |
![]() |
![]() |
#19 | ||
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
Quote:
![]() Yes The mask parameter can be added to fsuae too. And it's already done in the version you have. Just add it to the launch parameters of fsuae. Quote:
Conditional breakpoints would be great too, but it can be really challenging. Reset emulator is an option of FS-UAE? This is a feature request to tonioni. In vscode there is the restart button (green arrow). |
||
![]() |
![]() |
#20 |
Registered User
Join Date: Feb 2020
Location: Germany
Posts: 195
|
|
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Features requests for vscode amiga assembly extension ? | prb28 | Coders. General | 0 | 27 December 2018 16:19 |
Benefactor Pre Release? | BarryB | support.Games | 4 | 30 December 2011 23:56 |
Amiga OS4 Pre-Release: who's got it? | Amiga1992 | Amiga scene | 45 | 03 October 2004 21:11 |
Twintris Pre-Release | tomcat666 | request.Old Rare Games | 2 | 23 April 2004 11:34 |
p.OS Pre-Release | ijelorriaga | request.Apps | 0 | 22 March 2002 22:51 |
|
|