[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 80 Columns & DOS 3.3 for cc65?



Hi Linards,

>I have used DOS 3.3 by simply doing what you'd do from BASIC:
>
>printf("\r\4BLOAD TRACK%02d,A$%X,S%1d,D%1d\r", trackno, BUFFER + 0x300,
>cur_slot, cur_drive + 1);
>
>Works very well, although it is admittedly not very pretty.

Thanks for pointing out! If thinking about it, it works bacause I
explicitly added code to the cc65 C library:

When chars are coming in through COUT then DOS 3.3 checks the zeropage
location PROMPT to see if you're in the BASIC interpreter intermediate
mode or running a BASIC program. The cc65 C library changes the PROMPT
in the same way (to make DOS 3.3 understand that it shouldn't react on
"CATALOG" but only on "<Ctrl-D>CATALOG").

Seems to work nicely after all :-)

And maybe worth mentioning: On the Apple2 the cc65 C library makes all
stdio I/O from/to stdin/stdout/stderr go through the standard BASIC
I/O hooks (therefore the printf() above works). On the other hand
conio I/O is directly from/to the hardware. But conio still
uses/updates the usual zeropage locations (even the less common for
"windows") so you can easily mix both kinds of screen output...

Best, Oliver