English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Asm / Hardware

 
 
Thread Tools
Old 21 February 2021, 11:26   #201
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,410
I've recently become re-aware of this and tried it out. It seems to work well enough, but I can't get the WinUAE debug (or run) to work. Only FS-UAE seems to work, the WinUAE configurations give the error "unknown type: WinUAE".

Does anyone know how I can fix this?
Because source level debugging my HW banging asm code is such a nice feature I really would like to have it working, preferably in WinUAE
roondar is online now  
Old 21 February 2021, 20:58   #202
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
Quote:
Originally Posted by roondar View Post
I've recently become re-aware of this and tried it out. It seems to work well enough, but I can't get the WinUAE debug (or run) to work. Only FS-UAE seems to work, the WinUAE configurations give the error "unknown type: WinUAE".

Does anyone know how I can fix this?
Because source level debugging my HW banging asm code is such a nice feature I really would like to have it working, preferably in WinUAE



Same for me.
BippyM is offline  
Old 22 February 2021, 16:37   #203
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by emiespo View Post
Hi, let me say that the Amiga Assembly extension for VSC is really great, and express my gratitude.
Thanks !


Quote:
Originally Posted by emiespo View Post
Following up on this example I have a question: is it possible to launch the debugger as if the exec were launched via CLI? While debugging I can't open a library that is not in ROM (asyncio), and that is stopping me from being able to properly debug.
If you dynamically load your library, you must try with an absolute path.
I don't really know all the surroundings of the CLI. One I've tried to rework the exe load sequence but didn't succeed to have something better.

You should try the winuae version, I think it's more CLI compatible. A merge with fs-uae is possible, but, that's some work...
prb28 is offline  
Old 22 February 2021, 16:43   #204
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by roondar View Post
Does anyone know how I can fix this?
Try from a clean example project download : https://github.com/prb28/vscode-amig...indows_x64.zip
It should work.
prb28 is offline  
Old 22 February 2021, 18:42   #205
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,410
Quote:
Originally Posted by prb28 View Post
Try from a clean example project download : https://github.com/prb28/vscode-amig...indows_x64.zip
It should work.
Ok, that does work.
Strange... I only first downloaded and installed the extension/example two days ago and it most definitely didn't work at the time. At any rate, it works now so thanks for the help. I'll be trying this out for sure

Edit: it is possible the link via the marketplace doesn't work and the one you gave does? Because I installed it through the VS Code marketplace and your link is directly from Github.

Last edited by roondar; 22 February 2021 at 18:48.
roondar is online now  
Old 22 February 2021, 22:58   #206
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by roondar View Post
it is possible the link via the marketplace doesn't work and the one you gave does? Because I installed it through the VS Code marketplace and your link is directly from Github.
Which link did you use ? this : https://github.com/prb28/vscode-amig...ample/releases ?
prb28 is offline  
Old 22 February 2021, 23:05   #207
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,410
Quote:
Originally Posted by prb28 View Post
Yes, that's the one. And then I picked https://github.com/prb28/vscode-amig...indows_x64.zip

Not quite sure what went wrong then, because that does seem to be the exact same link as you sent me. At any rate, it works now and I'm quite impressed with how easy it all works so far. I love the way the registers show the meaning of their bit values when you hover over them. Saves me looking them up!

Granted, I've yet to try many things but that's half the fun
roondar is online now  
Old 23 February 2021, 00:06   #208
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Yes, it's the same link and I did not update it recently.

To start discovering the extension, you have some features in the wiki : https://github.com/prb28/vscode-amiga-assembly/wiki

If you want to try some useful (not so clearly explained) options :
prb28 is offline  
Old 24 February 2021, 23:02   #209
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
How exactly does one use the debugger commands? Like where are these entered and set?

How do I view the memory pointed to by an address register?
BippyM is offline  
Old 24 February 2021, 23:11   #210
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by BippyM View Post
How exactly does one use the debugger commands? Like where are these entered and set?

How do I view the memory pointed to by an address register?
In the lower part (input field) of the "Debug Console" type "m 5c50,10,2,4" to print the contents of $5c50.


You can add a watch an type the same command.


Screen example :

https://github.com/prb28/vscode-amig...the-watch-view
prb28 is offline  
Old 24 February 2021, 23:28   #211
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
I have followed this, and it displays from mem location 0 or doesn't show from the memory location I set.


I have tried with both FSUae and Winuae



Quote:
Originally Posted by prb28 View Post
In the lower part (input field) of the "Debug Console" type "m 5c50,10,2,4" to print the contents of $5c50.


You can add a watch an type the same command.


Screen example :

https://github.com/prb28/vscode-amig...the-watch-view
Attached Thumbnails
Click image for larger version

Name:	Clipboard Image.jpg
Views:	99
Size:	215.3 KB
ID:	71031  
BippyM is offline  
Old 24 February 2021, 23:35   #212
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by BippyM View Post
I have followed this, and it displays from mem location 0 or doesn't show from the memory location I set.
I think, I've something wrong in my documentation, try with the address :

"m $184b2,10,2,4"
prb28 is offline  
Old 24 February 2021, 23:43   #213
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
Spot on, that has fixed it. Thank you

Would it be possible to have the ability to right click on a register/label and select for it to display the memory location?
BippyM is offline  
Old 24 February 2021, 23:59   #214
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by BippyM View Post
Would it be possible to have the ability to right click on a register/label and select for it to display the memory location?
Yes, I've added a feature request (https://github.com/prb28/vscode-amig...bly/issues/140) in the github project, feel free to add more.
prb28 is offline  
Old 25 February 2021, 00:43   #215
emiespo
Registered User
 
Join Date: Jul 2017
Location: Oxford
Posts: 104
Amiga Assembly extension for Visual Studio Code

Quote:
Originally Posted by prb28 View Post
Thanks !







If you dynamically load your library, you must try with an absolute path.

I don't really know all the surroundings of the CLI. One I've tried to rework the exe load sequence but didn't succeed to have something better.



You should try the winuae version, I think it's more CLI compatible. A merge with fs-uae is possible, but, that's some work...


Thanks for your reply!

I tried with every possible path, absolute, relative, etc... I believe the issue is in the way the emulator is called. In the run config, you can see the emulator will just start off the disk and follow the normal startup-sequence, in debug mode, the exec is just “passed” to the emu.



Unfortunately I can’t use a Windows machine atm. I’ll give it a go when possible, just to see if the same issue happens.



On a different topic, still related to the fs-uae debugger, is there a way to debug a memory location with a labelled offset from a register? I can’t find a way...



Ie:



move.w d0,myLabel(a0)



...it won’t find the symbol “myLabel”. It only seems to work with absolute addresses. Either I don’t know how to do it, or is this an actual limitation of fs-uae?

Last edited by emiespo; 25 February 2021 at 22:03.
emiespo is offline  
Old 25 February 2021, 00:56   #216
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by emiespo View Post
move.w d0,myLabel(a0)

...it won’t find the symbol “myLabel”. It only seems to work with absolute addresses. Either I don’t know how to do it, or is this an actual limitation of fs-uae?
This is part of the extension syntax parse. I didn't add this case.
You can try :
m ${mylabel}+${a0},10,2,4
or m #{mylabel}+${a0},10,2,4
(I think I've a bug on this)

prb28 is offline  
Old 26 February 2021, 21:32   #217
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
Any idea why my registers are no longer showing?
Attached Thumbnails
Click image for larger version

Name:	Clipboard Image (1).jpg
Views:	91
Size:	141.8 KB
ID:	71048  
BippyM is offline  
Old 26 February 2021, 22:22   #218
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by BippyM View Post
Any idea why my registers are no longer showing?
No idea. The debugger didn't retrieve fs-uae debug info.
Try :
- set a breakpoint at the beginning of the program (3rd line) or set stop at entry in the launch params : "stopOnEntry":true
- Run with winua
- Clean the workspace and the unwanted .s files
- modify the launch command to add "trace":true - you should see the communications between fs-uae and vscode

Otherwise : I can have a look if you send me the folder.
prb28 is offline  
Old 26 February 2021, 22:32   #219
BippyM
Global Moderator
 
BippyM's Avatar
 
Join Date: Nov 2001
Location: Derby, UK
Age: 48
Posts: 9,355
Find my (your) workspace attached. I haven't included the bin folder which is unmodified.


Ignore my spaghettiness (unless it is the reason the debugger isn't working at all). No breakpoints are working


I haven't done anything since last night apart from start to split my code across multiple files (poorly I may add)


Thjanks



Quote:
Originally Posted by prb28 View Post
No idea. The debugger didn't retrieve fs-uae debug info.
Try :
- set a breakpoint at the beginning of the program (3rd line) or set stop at entry in the launch params : "stopOnEntry":true
- Run with winua
- Clean the workspace and the unwanted .s files
- modify the launch command to add "trace":true - you should see the communications between fs-uae and vscode

Otherwise : I can have a look if you send me the folder.
Attached Files
File Type: zip Amiga_Asm_Learning.zip (2.61 MB, 81 views)
BippyM is offline  
Old 27 February 2021, 10:45   #220
prb28
Registered User
 
Join Date: May 2018
Location: France
Posts: 246
Quote:
Originally Posted by BippyM View Post
Find my (your) workspace attached. I haven't included the bin folder which is unmodified.
Thanks for the workspace.
Well, I saw it... start to debug trying to understand, and it started working and I can't make it fail again !

What I did before it works :
- I've edited the launch file and removed all the configurations, kept only one debug configuration and start debugging (F5).
I thought it was a corrupted file but restoring the zip does not make it fail again.

Can you try the same procedure ?
Does it work with default workspace ?
(This is the 'science' part of 'computer science' )
prb28 is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
assembly code to test for assign (2.0+) jotd Coders. System 2 27 December 2017 23:16
very basic C/ASM/Visual Studio hand holding Sephnroth Coders. C/C++ 2 08 March 2016 20:15
Amiga Audio/Visual KhneFr request.Other 6 03 January 2015 10:25
Profiling WinUAE with Visual Studio 2013 mark_k support.WinUAE 3 14 January 2014 20:26
amiga visual editor thinlega request.Apps 1 22 January 2003 15:48

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 16:07.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.21922 seconds with 16 queries