Sample file "z88dk/libsrc/_DEVELOPMENT/EXAMPLES/zx/demo_nirvanap/nirvanadem.c" contains the following definition:
Code: Select all
#define printAt(row, col) printf("\x16%c%c", col<<1, row)
Sample file "z88dk/libsrc/_DEVELOPMENT/EXAMPLES/zx/demo_nirvanam/nirvanadem.c" contains the following definition:
Code: Select all
#define printAt(row, col) printf("\x16%c%c", col, row)
Sample files "z88dk/libsrc/_DEVELOPMENT/EXAMPLES/zx/demo_bifrosth/bifrosthdem.c" and "z88dk/libsrc/_DEVELOPMENT/EXAMPLES/zx/demo_bifrostl/bifrostldem.c" contain the following definition:
Code: Select all
#define printAt(row, col) printf("\x16%c%c", (col), (row))
I vaguely remember z88dk changing this behavior a while ago. Please update the first 2 files mentioned above, to use this last definition too.
Moreover, all 4 files above contain the following definitions:
Code: Select all
#define printInk(k) printf("\x10%c", '0'+k)
#define printPaper(k) printf("\x11%c", '0'+k)
It would be better to modify all 4 files as follows:
Code: Select all
#define printInk(k) printf("\x10%c", '0'+(k))
#define printPaper(k) printf("\x11%c", '0'+(k))
The lack of parenthesis doesn't make any difference in this case, but since these files are provided as examples for z88dk developers, it's better to provide fail-proof definitions, for programmers that will reuse the same definitions somewhere else.