@2072: They're located at 1A20:0000..1A20:17FF, so they match exactly into the video buffer (not 1 byte left). But it would be a problem when you want to use more than one pages with 6 layers each; you had to reloc pages into the program's own memory and define a buffer therefore, buts not THE solution, because programs have already 56KB mem only...
Btw, does your memzone lib create save buffers in the 144KB user space or in the programs mem? Additional space in the 144KB mem was quite cool...
@C@siomax: Yeah, I noticed already... I need about 3 minutes to upload Add Ins to my calc, but f100 and gcomm sadly don't work on my computer
But for the new demo I`ll also upload the EXE at least now.
Thx for the info, showing it should work with all calcs, but different settings (altough meanwhile I noticed giving me the frequency the program puts out has no use for, because it's calced too unexact; the new calibration tool will be better)
------------------------
I tried to find out now the display's frequency with Deimos' method, and got 155 Hz for slow - and 310 Hz for fast sweeping mode (hope that I interpreted the results correctly). But there was one really strange discovering I made:
If you use the same timing parameters in fast sweeping mode as in slow mode, timing cycles are about 6.3% longer then, altough nothing but the content of port 4 (e.g., displays frequency) has been changed then. Thus, if display is in fast sweeping mode, a programm has 6.3% less CPU ressources than it has in slow mode.
The only way I could explain this was, when the display had an IRQ that was called each time the display begins or ends with a refresh cycle (in fast sweeping mode the IRQ would be called more often than and thus leave less ressources left for the program). That would be great, because it would provide a way achieving perfect synchronisation with the display.
So I began scanning for interrupts that are frequently called (scanned all 255), but am not REALLY happy with my result. Amongst some interrupts around 78 (called on keystroke), I found only two that were called frequently: Interrupts 1C (the timer) and 53. Interrupt 53 is that what is mentioned to force an "update of the display" in Oliver Coupelons Guide, but it's called 50 times a second only, no matter weather you use fast or slow sweeping mode, or if you even stop it.
That seemed really strange to me, so I passed int 53's code through a disassembler. I listed below what I got. What this interrupt does is not (as mentioned in Oliver's guide) to update the display, but it seems to be the timer's IRQ, because it calls int 1C (the timer interrupt).
Here is what it does:
- Call Interrupt 1C (thus, 1C is not the timer IRQ, but called by it)
- refresh the display one time in 10.24 seconds (have no idea what this should be good for)
- (probably) read out the keyboard's touch lines
- do some other stuff (not analized the whole code)
int 53's code
00000000 50 push ax //save registers
00000001 53 push bx
00000002 51 push cx
00000003 52 push dx
00000004 56 push si
00000005 57 push di
00000006 55 push bp
00000007 1E push ds
00000008 06 push es
00000009 CD1C int 0x1c //call int 1C (timer interrupt)
0000000B B84000 mov ax,0x40 //test, if BIOS timerticks variable
0000000E 8ED8 mov ds,ax //is aligned to 200h
00000010 F7066C00FF01 test word [0x6c],0x1ff
00000016 7504 jnz 0x1c
00000018 B424 mov ah,0x24 //if so, force a display refresh, thus, force a display refresh once in 10.24 seconds.
0000001A CD7C int 0x7c
0000001C B84000 mov ax,0x40
0000001F 8ED8 mov ds,ax
00000021 A1AC00 mov ax,[0xac]
00000024 85C0 test ax,ax //not sure what now happenes, but note that prots 13 and 14 are known to be the,
00000026 7457 jz 0x7f //keyboard ports. Probably, the AFX's keyboard has no own IRQ, thus, the touch lines are
00000028 E713 out 0x13,ax //scanned frequently: 50 times a second, and then passed to other ints "emulating"
0000002A B90A00 mov cx,0xa //a keyboard IRQ
0000002D E2FE loop 0x2d
0000002F 8A26AE00 mov ah,[0xae]
00000033 813EAC000002 cmp word [0xac],0x200
00000039 741C jz 0x57
0000003B B90A00 mov cx,0xa
0000003E E413 in al,0x13
00000040 84C4 test ah,al
00000042 7403 jz 0x47
00000044 E9CD00 jmp 0x114
00000047 E85B01 call 0x1a5
0000004A E2F2 loop 0x3e
Thus, the LCD sadly has no IRQ providing perfect synchronisation - at least I found none.

(Altough wondering, why display sweeping takes CPU ressources then).
------------------------
So the bad news is, that we have to measure out the timing parameters ourselves, and furthermore 2^n color emulation ever will take 1/3 of the CPU ressources (except anyone finds a way
to program the timer directly via I/O; probably it's possible, but there are no docs mentioning it), whereas color emulation timed directly by the display IRQ would need only unimportant ressources.
One good news, however, is, that calibrating timing parameters for your calc is not that complicated anymore; I wrote a tool now based upon Deimos' idea (thx again), but did not upload it yet.