Jump to content



Photo
- - - - -

Cgdoom - Play Doom On Your Prizm


  • Please log in to reply
9 replies to this topic

#1 flyingfisch

flyingfisch

    Casio Maniac

  • Deputy
  • PipPipPipPipPipPipPipPip
  • 1891 posts
  • Gender:Male
  • Location:OH,USA
  • Interests:Aviation, Skiing, Programming, Mountain Biking.

  • Calculators:
    fx-9860GII
    fx-CG10 PRIZM

Posted 25 June 2012 - 03:12 PM

MPoupe posted on Cemetech about his new game, CGDoom.

It is still rather buggy but definately playable.

Screenshot:
Posted Image

Videos:

Running on emulator:


Running on KermM's PRIZM, not overclocked:



Download
http://www.cemetech....p...file&id=755

#2 Forty-Two

Forty-Two

    Casio Overlord

  • Deputy
  • PipPipPipPipPipPipPip
  • 528 posts
  • Gender:Male
  • Location:Well, The sign says "You are here"...

  • Calculators:
    Casio fx-CG10 Prizm
    Casio fx-9860GII
    TI-84+ SE

Posted 27 June 2012 - 06:38 PM

Wow! That's realy cool. Do you know if he plans to enter it in the contest? That'd definitely be tough competition.

#3 flyingfisch

flyingfisch

    Casio Maniac

  • Deputy
  • PipPipPipPipPipPipPipPip
  • 1891 posts
  • Gender:Male
  • Location:OH,USA
  • Interests:Aviation, Skiing, Programming, Mountain Biking.

  • Calculators:
    fx-9860GII
    fx-CG10 PRIZM

Posted 27 June 2012 - 06:46 PM

I asked him and he didn't reply...

#4 Martin

Martin

    Casio Freak

  • Members
  • PipPipPipPip
  • 121 posts
  • Gender:Male
  • Location:Praha
  • Interests:asm on cfx9850

  • Calculators:
    fx82l
    fx7700GB
    cfx9850G
    TI92
    fx9860G SD
    Rheinmetall KEL IIc
    H. W. Ebmeyer - Tarema
    fx cg20

Posted 15 July 2012 - 04:57 PM

Updated version is at http://www.omnimaga....68.0;msg=256372

#5 MicroPro

MicroPro

    Casio Overlord

  • Deputy
  • PipPipPipPipPipPipPip
  • 640 posts
  • Gender:Male
  • Location:Iran

  • Calculators:
    Casio ClassPad 300

Posted 20 July 2012 - 06:10 PM

Martin, I'm really curious to know what is the simulator you put in the archive? Did you write it? Is it an SH virtual machine or is it native x86 code?

#6 Martin

Martin

    Casio Freak

  • Members
  • PipPipPipPip
  • 121 posts
  • Gender:Male
  • Location:Praha
  • Interests:asm on cfx9850

  • Calculators:
    fx82l
    fx7700GB
    cfx9850G
    TI92
    fx9860G SD
    Rheinmetall KEL IIc
    H. W. Ebmeyer - Tarema
    fx cg20

Posted 22 July 2012 - 10:06 AM

Hi,
the simulator is written by me - it is x86 application, it's main purpose is to debug the application on platform with debugger (windows). It contains small library simulating Prizm functions on PC so I can compile the same sources for both PC & Prizm.
I released source code for the simulator library with CGPlayer - check here: http://martin.poupe.org/casio/
Of course I will release sources for CGDoom after it will be somehow "finished", also with the simulator.

Another post about my simulator is here: http://www.omnimaga....hp?topic=9433.0

#7 flyingfisch

flyingfisch

    Casio Maniac

  • Deputy
  • PipPipPipPipPipPipPipPip
  • 1891 posts
  • Gender:Male
  • Location:OH,USA
  • Interests:Aviation, Skiing, Programming, Mountain Biking.

  • Calculators:
    fx-9860GII
    fx-CG10 PRIZM

Posted 23 July 2012 - 10:51 PM

Hi,

=====BUG REPORT=====
On my calc, when I try to get to the second level, by pressing <span class=EXE' /> in front of the switch, I get this error:

ERROR:
Z_Malloc: failed on a

It seems that the rest of the text goes off the screen.

On my cousin's calc and my brother's calc, it only happens when trying to get to the third level.

I am using the default doom.wad file.

#8 Martin

Martin

    Casio Freak

  • Members
  • PipPipPipPip
  • 121 posts
  • Gender:Male
  • Location:Praha
  • Interests:asm on cfx9850

  • Calculators:
    fx82l
    fx7700GB
    cfx9850G
    TI92
    fx9860G SD
    Rheinmetall KEL IIc
    H. W. Ebmeyer - Tarema
    fx cg20

Posted 24 July 2012 - 04:57 PM

Hi,

ERROR:
Z_Malloc: failed on a

Hello,
Doom requires 8MB RAM. I did some hacks to run it on smaller RAM, but I never got to the level 3. So the crash is expected, probably the level is larger than the previous levels.
To save RAM I use flash directly. But if the Doom requests block of e.g. 8KB from wad on some offset, I try to find it in the flash. If the block is continous, then I can use flash (= no RAM allocation). But if the wad has more fragments (file fragmentation) and the requested block is in 2 different fragments, I cannot use flash, I have to malloc these 8KB and copy the data here. So try to defragment your calculator storage - it may help.

But it is possible that the problem is elsewhere, the CGDoom state is less than alpha !

#9 MicroPro

MicroPro

    Casio Overlord

  • Deputy
  • PipPipPipPipPipPipPip
  • 640 posts
  • Gender:Male
  • Location:Iran

  • Calculators:
    Casio ClassPad 300

Posted 25 July 2012 - 11:00 AM

Hi,
the simulator is written by me - it is x86 application, it's main purpose is to debug the application on platform with debugger (windows). It contains small library simulating Prizm functions on PC so I can compile the same sources for both PC & Prizm.

I see. So you implemented prizm-specific functions for Windows, but that required many changes to the actual source code.
Actually (after seeing the Cemetech SDK) I thought about implementing prizm functions in Windows and release it as a library that users can simply link the same g3a source code against it to have the Windows executable. Don't you have the same idea?
mini-SDK is smaller and should be much easier to do this.

To save RAM I use flash directly. But if the Doom requests block of e.g. 8KB from wad on some offset, I try to find it in the flash. If the block is continous, then I can use flash (= no RAM allocation). But if the wad has more fragments (file fragmentation) and the requested block is in 2 different fragments, I cannot use flash, I have to malloc these 8KB and copy the data here. So try to defragment your calculator storage - it may help.

Not sure if I understand this correctly, but how about doing address translation? i.e mapping a continuous virtual memory space to the flash area and have all mallocs use that mapping?

#10 Martin

Martin

    Casio Freak

  • Members
  • PipPipPipPip
  • 121 posts
  • Gender:Male
  • Location:Praha
  • Interests:asm on cfx9850

  • Calculators:
    fx82l
    fx7700GB
    cfx9850G
    TI92
    fx9860G SD
    Rheinmetall KEL IIc
    H. W. Ebmeyer - Tarema
    fx cg20

Posted 26 July 2012 - 09:25 AM

I see. So you implemented prizm-specific functions for Windows, but that required many changes to the actual source code.
Actually (after seeing the Cemetech SDK) I thought about implementing prizm functions in Windows and release it as a library that users can simply link the same g3a source code against it to have the Windows executable. Don't you have the same idea?
mini-SDK is smaller and should be much easier to do this.

Not sure if I understand this correctly, but how about doing address translation? i.e mapping a continuous virtual memory space to the flash area and have all mallocs use that mapping?

Hello,
1. the CGplayer used "unfinished" simulator, so the source needed to be modified. But CGDoom really use the same sources for both calculator + PC simulator. See here: http://martin.poupe....doom0.03src.zip
I think we had the same idea :-)

2. I have no knowledge of virtual memory on Prizm. I do it simple way, you will see it in the source code, see cgdoom.c, function CreateFileMapping(). But you are right, map file to continuous memory space would solve it. But in most cases there would be few fragments, so the improvement would be small. And there are many required buffers in true RAM. Do we have some updated map of memory, list of areas, which can be safely used in addin ?
I use heap, system stack, VRAM (as VRAM) and background VRAM (for menu handler). I think I could create file in main memory and use it as a buffer (max ~ 60KB), but I would like to find more unused memory :-)


2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users