Good job zoranc, thank you. I think will write a new asm startup file which will initialize the global ram variables.
Time to implement more PM specific functions...
C compiler
Re: C compiler
Another day another bomb, ops I mean version. Version 0.0014 first more or less functionally complete. I'll be happy to receive your bug reports!
New in this version is: initialization of global ans static variables and arrays, pm.h file for PM registers, starting position of the RAM variables can be set and last one is the awesome -help command line option.
Enjoy!
Z
.
New in this version is: initialization of global ans static variables and arrays, pm.h file for PM registers, starting position of the RAM variables can be set and last one is the awesome -help command line option.

Enjoy!
Z
.
- Attachments
-
- vbccpm_0014.zip
- (294.91 KiB) Downloaded 638 times
Re: C compiler
TADA: Version 0.015 on your attention. This time only change is the obsoleted __rom attribute, use const instead. 
At this point all of the items on the TODO list are either involving or non essential, so I'll name it alpha 1 version.
It is still full of bugs. Most notable ones: 1. comparison of unsigned numbers, 2 char/short on the stack make problems.

At this point all of the items on the TODO list are either involving or non essential, so I'll name it alpha 1 version.
It is still full of bugs. Most notable ones: 1. comparison of unsigned numbers, 2 char/short on the stack make problems.
- Attachments
-
- vbccpm_0015.zip
- (294.76 KiB) Downloaded 599 times
Re: C compiler
hey zoranc, nice job. i wrote a small example to control the PRC. But i just noticed that there is no way to align arrays in memory. The PRC needs tiles to be aligned at 8 byte boundard and sprites at 64 bytes boundary. Please consider adding an option to do that. Attached you can find the code, it works but the gfx is wrongly aligned. Please put that on top of your list 
Chars are still causing trouble (i think when writing chars to ints).
Good job, keep it up!

Chars are still causing trouble (i think when writing chars to ints).
Good job, keep it up!
- Attachments
-
- prc_test.zip
- (15.74 KiB) Downloaded 606 times
Re: C compiler
Seems I spam this site the most...
I use it as both release and change-log history.
Anyway ver. 0.016 features some fixes of unsigned comparison and also of short int handling. Also there is a new demo included with tile-map usage.

Anyway ver. 0.016 features some fixes of unsigned comparison and also of short int handling. Also there is a new demo included with tile-map usage.

- Attachments
-
- vbccpm_0016.zip
- (295.02 KiB) Downloaded 618 times
- YasaSheep
- Posts: 202
- Joined: November 20th, 2005, 04:04
- Location: Portland (Also the discord)
- Contact:
Re: C compiler
When you're producing content, I'm sure nobody minds. ;]
Re: C compiler
Too bad we post simultaneously. I read you mind so fixed chars and alignment. Well in this revision is the 64 alignment too.
- Attachments
-
- vbccpm_0017.zip
- (295.54 KiB) Downloaded 617 times
Re: C compiler
Reading from global char* doesn't work yet... In this example i use a work-around. I am surprised it works for OAM[0].tile ^= 1;
Nice job on the align feature, works nicely.
Nice job on the align feature, works nicely.
- Attachments
-
- prc_test.zip
- (16.42 KiB) Downloaded 597 times
Re: C compiler
global char * fixed. return char top pri, now. here you go 0.018.
- Attachments
-
- vbccpm_0018.zip
- (295.9 KiB) Downloaded 606 times
Re: C compiler
Wa do you intend to restart work on PkMn Orange now that we got semi-working C-compiler?
Oh, and the new version (0.019) of course - char return fix...
Oh, and the new version (0.019) of course - char return fix...
- Attachments
-
- vbccpm_0019.zip
- (295.86 KiB) Downloaded 604 times