2013-05-08 10:41 PM
Is there a way to define the address of main() to be at a specific location?
The Raisonance compiler has a ''at 0x8080 void main(void)'' syntax, does the cosmic compiler have something similar? I've tried doing void ''main(void) @ 0x8080'' but compiler complains it doesn't recognize it.2013-05-08 11:10 PM
of course after I posted this I found a solution.
#pragma section (main)
void main(void) { /* .... Code here */ } #pragma section() Then under linker settings: # Segment Main: +seg .main -b 0x9AAA -m 0x557 -n .main A little bit more static than I wanted but should hopefully work. If there is a better way to do this, I'm all ears.