On 25/05/2015 06:33, Ralf Quint wrote: >> DIR: When using DIR/P, DIR seems to think that the screen is 1-row high, >> and asks for a keypress for every line (the screen is CGA-based, 25 rows). > That must be some issue with your PC, works fine for me and should not > be related to 8086 code or not at all...
Hi, I had a few minutes of time to look into this. And what I was half-guessing two days ago seems correct: my PC is fine, that's FreeCOM who's buggy. Here is an extract of what makes the DIR command wait after a page of text (extracted from SVN's trunk and slightly reformatted for better mail readability): /* increment our line if paginating, display message at end of screen */ static int incline(void) { if (!optP) return E_None; if (++line >= MAX_Y) { line = 0; return pause(); } return 0; } Now the obvious question of course is "what is MAX_Y?". And one grep later, I've got the answer: $ grep 'MAX_Y' -R * cmd/dir.c: if (++line >= MAX_Y) include/misc.h:#define MAX_Y (*(unsigned char far*)MK_FP(0x40, 0x84)) include/misc.h:#define SCREEN_ROWS (MAX_Y + 1) (...) This is exactly what I was implying in my previous message - FreeCOM doesn't care about CGA, and assumes that the screen's height will always be available under 0040:0084, which is true only for EGA+. Mateusz ------------------------------------------------------------------------------ _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel