Code: Select all
#define NIRVANAP_TOTAL_ROWS 19
static unsigned char NIRVANAP_isr[3] @ (56698+328*NIRVANAP_TOTAL_ROWS);
void main(void)
{
NIRVANAP_isr[0] = 205;
}
Code: Select all
; --- Start of Scope Defns ---
PUBLIC _NIRVANAP_isr
defc _NIRVANAP_isr = 62930
PUBLIC _main
The equivalent in sdcc is working with the static keyword there but sccz80 is ignoring static for placement syntax. The relevant code is line 388 in sccz80::main.c. There should be some way to know if the symbol is static and if so, the PUBLIC part should not be output. However once that's done, there's another problem: sccz80 emits these symbols at the end of the translation so z80asm will be left with a lone defc at the end and will complain about symbol not found when it is used above in the source code (the 'PUBLIC' causes z80asm to resolve the symbol and without it defc is undefined prior to its occurrence). So sccz80 would also have to be modified to output either all symbols before the translation or just these static defcs.
Are you up for another problem? I can start poking around but it's better if it's done by someone who knows what's going on.
------------------------------------------------------------------------------