delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/07/19/12:00:03

Lines: 64
X-Admin: news AT aol DOT com
From: sterten AT aol DOT com (Sterten)
Newsgroups: comp.os.msdos.djgpp
Date: 19 Jul 2001 15:52:09 GMT
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1010719172847 DOT 2839B-100000 AT is>
Organization: AOL http://www.aol.com
Subject: Re: pokeb peekb
Message-ID: <20010719115209.02086.00000298@ng-bd1.aol.com>
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Tom:
 >Why do you have to put a smiley in the middle of the screen?  Some wierd
 >obsession?

that should serve as an example for proper usuage.
In fact I needed a fast routine to increment the screen byte
at location (x,y) for a jigsaw-like puzzle-solver 
to visualize the regions of current activity.


 >Anyways in DJGPP you can use
 >
 >#include <stdio.h>
 >#include <conio.h>
 >
 >int main(void)
 >{
 >    gotoxy(40,12);
 >    printf("\x01\n");
 >    return 0;
 >}
 >
 >which isn't portable but works in DJGPP at least.

does it work with the INTEL- compiler ?
I need also a routine for the intel-compiler , since it is
about 30% faster on that program.
Our actual program runs with both compilers.



Eli:
 >On Thu, 19 Jul 2001, Tonu Aas wrote:
 >
 >>> >     And I think that djgpp is not the best choise to produse
 >> smallest/fastest
 >>> > program to show 01h on screen.
 >>>
 >>> Why not?  I've just posted a way to do that in 2 assembly instructions.
 >> 
 >> :)) You just forgot all the startup code.
 >
 >Who cares about the startup code? 

it adds to the other code. How large can it be ? 500K ?
Presumable it has to fit into low memory.
Large programs are also not so good to transmit by email.

 >You don't meant to say that someone 
 >would actually write a program that just puts the character in the middle 
 >of a screen and exits, do you?  Who would need a ridiculous toy program 
 >like that?  That's even less useful than the proverbial hello world.

it's useful to teach newbies proper usage of DJGPP  :-)
(put it in the FAQ , to save others the time which I spent !)

 >I assumed we were talking about the code to do that as part of a larger 
 >program.

yes, see above



Guenter

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019