Page 1 of 1

Code debugging without real hardware

Posted: August 17th, 2013, 8:02 am
by jman
Hello,

I'm moving the first steps with some sample code with the Psy-Q SDK.
I've never approached console development, so I wonder if it is possible to debug one's code (e.g. printf() statements) when code is run inside an emulator. Tried epsxe and xebra but none of them prints anywhere my printf()s. Xebra has a debug window but I don't have clear how making use of it.
Alternatively, shall I use FntPrint()?

Thanks for any suggestion!

Re: Code debugging without real hardware

Posted: August 18th, 2013, 12:53 am
by Shendo
To my knowledge only no$psx directs stdout to debug window. For other emulators you will have to use FntPrint().

Re: Code debugging without real hardware

Posted: August 18th, 2013, 1:40 pm
by Shadow
Virus Total reports it mainly as a trojan, but I trust no$cash and the emulator is excellent.

It is better than PSXFIN (PSx) and ePSXe, but it still doesn't beat XEBRA by Dr. Hell.
Some games work better under XEBRA than than do on NO$PSX, so NO$CASH has some tweaking to do ;)

https://www.virustotal.com/en/file/dc73 ... 376793443/

To debug, click 'Window' -> 'Debug Messages'.

Re: Code debugging without real hardware

Posted: January 26th, 2017, 7:28 pm
by LocoMJ
Sorry for updating this post but I'm very interested in the topic.

Yesterday I installed PSYQ and I played with some examples. But my question is, how could I debug the code? What's the minimum tools/hardware I need?

Thanks!

Re: Code debugging without real hardware

Posted: January 26th, 2017, 7:42 pm
by Shadow
To actually debug properly, you need an official Sony development kit, such as the DTL-H2000, H2500 or 2700. For basic debugging, printf's under NO$PSX works, but if you want something easier, you'll need CAETLA on an Xplorer/Xploder cartridge.

Re: Code debugging without real hardware

Posted: January 26th, 2017, 8:16 pm
by LocoMJ
Thanks for the info, Shadow.

I have a FX explorer, so I'll flash it :)
For the moment, I'll do some tests with PSY-Q and I'll write you an email telling something more.

Re: Code debugging without real hardware

Posted: January 27th, 2017, 9:17 am
by Xavi92
PCSX-R also allows console output. Just activate these two check boxes on "CPU Config" window:

Image

Could it be possible to modify PCSX-R's source code to allow ELF files with debugging symbols so as to run it using GDB? :shrug

Re: Code debugging without real hardware

Posted: April 6th, 2018, 7:17 pm
by Shadow
Yes, that's very much possible but it's a bit of work to do so.

Re: Code debugging without real hardware

Posted: March 18th, 2019, 5:21 pm
by riyasathe
Excellent information here. Great post. Thanks for such a helpful share!