Jump to content

Jaguar debugging


Recommended Posts

I'm coding a new game, of course, I'm using the same libraries (my own) but I'm having random hangs. I've commented several parts of the code and still I've hangs, even doing no game logic just rendering the sprites it hangs, some times it takes a bit more, some times a bit less.


Random hangs usually happens when you forget to initialize a variable and it gets random data, I've checked and is not the case (I think).


IMO the jaguar hangs because the OP list is wrong, but it's strange because I've used the same library in four games. 


There are any way to capture when the OP gets crazy, and execute some code to do a memory dump or something else? I've all 68000 exceptions pointing to a routine to print (through the skunboard) the exception name (bus error, address error...), but no exceptions are raised.


I'm running out of ideas to fix this weird bug.


Just before I summited this topic I've removed the call to init u235se and it works, but I wasn't playing any music or sound fx... ?


Edited by swapd0
Link to comment
Share on other sites

So are you saying it works if you don't init the SE but crashes the moment you init the SE or some time later?


The SE will quite happily sit there running on DSP without playing mods or sounds, it will continue to run RNG and poll pads.  Are you attempting to make any calls to talk to the pad addresses?


If it is crashing as soon as you init, I'd say there is something wrong with the init process or the binary blob being loaded onto the DSP.

Link to comment
Share on other sites

1 minute ago, swapd0 said:

With the SE running it hangs some time later, when I'm in the game loop (move player, move enemies, draw sprites and loop), later I'll test with a mod playing. I'm not using the SE for pad pooling, maybe DSP & 68000 are pooling the pads at the same time?

Yeah might be a conflict, if you are not using the pad code in the SE, I'd recommend disabling it (you can switch parts you are not using off with the SR)

  • Like 1
Link to comment
Share on other sites

Still hangs with the joypad polling (not pooling XD) and RNG disabled. Anyway I'll finish the gameplay and then enable the sounds fx and see what happens.


2 hours ago, CyranoJ said:

The 0.24 SE sometimes just gives up the will to live and dies on VirtualJaguar.  It's fine on h/w.  Don't know if thats where you are testing or not?

I code on real hardware, I've tried virtual jaguar only a couple of times.



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...