Showing posts with label mod_proc. Show all posts
Showing posts with label mod_proc. Show all posts

Wednesday, March 31, 2010

signal working now?

After a few hours of reading and re-reading Bennu code and even reimplementing mod_proc, I think I finally fixed the regression in mod_proc that caused signal not to work.

This was a stupid bug. It was caused by me not knowing well enough how C works. Should I have read and understood how enums work in C, I wouldn't have redefined some internal value that told Bennu to kill a process when told so (I was instead messing with some other internal var).

Well, I just wanted to let you know that I think I fixed it.

Tuesday, March 9, 2010

Collision, signal fixed!

Ok, I finally fixed the signal and collision bugs. At some point during the integration of mod_proc & mod_grproc, I had broken a few things. What I'm not really sure of is why signal was working before...
Both 09_mod_proc.prg and 20_mod_grproc.prg work now as expected.

Wow! I did a few things in under an hour of coding today! :)

PS: BTW, this thing is starting to look usable (if you don't take colours being broken into the account) so if you want to start porting your games to the Wii and help test the port, please get in touch with me.

Thursday, February 25, 2010

Fixed librender, mod_map working (minus byte-order). Regressions in mod_proc.

Today I fixed librender, there were a few thing I had omitted, the most important of which was telling Bennu to redraw the screen every FRAME.

So after some rough testing, I believe that mod_map is working fine. I'll have to do more thorough testing, though.
I'm expecting to find problems with mod_map when working in a real Wii (I tested the code in my linux box) because of the different byte-order it uses. Colours will most likely seem broken. Expect a couple of demos about this later today or maybe tomorrow.

I've also found a regression in mod_proc. signal seems to not be working as expected. I'll have a look into that.

Also, the module dependency diagram is growing :)

Monday, December 28, 2009

Upsss! mod_proc is now working

mod_proc seems to be working now. I will have to do more testing, but LOCALs such as FATHER seem to work now.
The problem was that when I inserted the code for the LOCALs defined in mod_proc, I had not taken into the account how their values where referred in the DCB (file offsets.h).

This was quite a complex bug in the sense that it would've been very hard for me to find. I have created a modified Makefile so that now I can compile and test most of the code without having to be in front of my Wii.
That helped a bit to find the bug but it was my brother who did most of the debugging this time, so thanks to him :)

So now, only mod_sort, mod_mem and mod_timers are left before I start with the graphical part of Bennu!

Sunday, December 13, 2009

mod_proc is in, but it has problems with signal...

mod_proc is now in, but there seems to be a problem with signal...
Processes seem to be affected by signal, but they won't die; their id changes but nothing else.
Also, when a process is called, their father local var is not set correctly (it's always set to 0).

let_me_alone does kill the processes that you didn't try to kill with signal before.

There's also some other function that I've not yet isolated that results in an unhandled exception...

Will have to look into this....

A bit of hacking with globals, locals and DLVARFIXUP, in general

I'm not having much time lately to work on Bennu, but today I got to hack a bit on it.
Basically, what I've done is finish the mod_sound module (remember some time ago I said there were some bits left?).

What I've one is implement the code that initializes the global variables. The mechanism is the same as used for initializing local vars, so those should be easy to do now, too.

This is, however, a more important change that it can appear to be, as this was basically the only thing I didn't really understand about the new Bennu modular architecture (as opposed to the old Fenix static design). This means that I can finally also try to finish mod_proc.

So I'm hoping on having all applicable non-video related modules done very soon so that I can start with the code that makes Bennu so great: graphics :)

Happy coding!

Saturday, November 28, 2009

Long time, a few modules

Got a bit of time to work on this today:

  • I worked a bit more on mod_proc. Now bgdc, bgdrtm and bgdi compile. I wouldn't say it's working yet, as there are some values that have to be defined at runtime that are not yet being defined, but it's a start.
    Also, this modules defines some LOCAL vars. They're defined right after the GLOBALs.
    A funny thing I noticed about how Bennu works is that these vars are defined, from within C code, with Bennu syntax. What that means is that the compiler adds that Bennu code in the Process declaration, as if you'd written it there.
  • Got mod_rand in. This one was really easy :)
  • Started working on mod_mouse. mod_mouse has no real code or definitions, all the code is in libmouse. It won't work, yet, as libmouse depends in the graphical part of Bennu and work on that has not yet started.
    The compiler & interpreter will, however, be fine with you messing around with the MOUSE struct. Obviously the values you'll get are default ones and won't bear any resemblance with your mouse's position.
  • Fixed a few warnings.
I plan on getting all the modules that don't depend in libgrbase in soon, make sure they work and then proceed with the remaining modules.

Tuesday, October 27, 2009

mod_time in (will crash) and mod_proc thoughts

Spent a bit of time today getting mod_time to work with Bennu.
This module makes use of SDL for the ftime function, therefore I've had to make bgdi link to it.
bgdi will crash if you try to use it as it is (get_timer and time should work fine, though) because I SDL must be running for this function to work, and I don't yet initialize it, but that shouldn't be too hard to do.

Also, spent a few minutes looking at mod_proc. It defines a few LOCALs and GLOBALs, so I have to find the place where they belong to.

Stay tuned for more updates.

PS: re-reading this, get_timer will also crash, as it also uses SDL. Initializing SDL isn't hard to do, at all, so these crashes should be easy to fix.