HDTenEightyP/NetNews huggingface dataset:
Newsgroups: comp.os.msdos.programmer
Subject: VGA 360x480 mode
From: longshot@att2.cs.mankato.msus.edu (Erik Green)
Date: 12 Sep 92 01:55:29
Distribution: comp.os.msdos.programmer
Organization: Long polymers in double-helix formation


  If this isn't the right place for this, cope.


  I am currently going nuts trying to write routines that will work in/with
the 360x480x256 video mode shown in example by John Bridges in his VGAKIT41
listings available at finer archives anywhere.  He refers to this mode 
as mode X, but I note that it is different from the Mode X described by
Michael abrash in his code from DDJ.  The code (routines that write directly
to the video hardware, mostly) to enter into both of these modes appears
quite similar.  On to my problem: I have written routines in TC2.0(not c++)
and MASM to set the 360x480 mode, and also to plot pixels on the screen
in this mode.  I think I'm setting the mode correctly, as the screen clears
without snow or flashes in the same manner it does when I set standard mode
13h, but If I try to set the palette using interrupt 10h, I get a nasty flash
on the screen.  Attempting to draw pixels by calculating the memory location
((yposition * xwidth)+(xposition/4)) (Side note: In Bridges' code, xwidth is
commented as having the value of 360, and in a different section, is set to
90 and 80.  Anybody know the correct value?) and outputting the bitplane 
mask to the sequencer appears to do nothing.

   I would like to use this mode for a few programs, but I can't seem to get
it right.  This mode would be better than the 320x240 mode, as I don't 
need to use animation or more than 1 video page.

  For reference, my video card is a no-name 256k model with a Paradise 
chipset(PVGA1A, I think).  I'm working on a 80386-25DX with TC2.0 and
MASM 4.0.

Any Ideas, people?  I've worked on this for about 6 hours, myself %-(

Thanks for any help,
Erik

--
Erik "Longshot" Green    
longshot@(vax1 | att2.cs | krypton | theory.cs).mankato.msus.edu  
     "Ash nazg durbatuluk, ash nazg gimbatul, ash nazg
       thrakatuluk agh burzum-ishi krimpatul!"
Newsgroups: comp.os.msdos.programmer
From: ts@uwasa.fi (Timo Salmi)
Subject: Re: Another MsDos batch programming challenge
Followup-To: alt.religion.computers
Organization: University of Vaasa, Finland
Date: Mon, 14 Sep 1992 10:23:11 GMT

In article <1992Sep13.225833.1665@cco.caltech.edu> nyet@cco.caltech.edu (n liu) writes:
>Once again, MsDos batch programming is such a challenge ONLY because
>command.com is such a piece of crap.

No disagreement here.

>I have yet to see a batch programming challenge that can't be be done
>in one line with 4dos (usually).

Right on the button.  But can we return to this tack when half, or
at least 10 per cent, of the 50-100 million command.com users have
switched to 4DOS.  The command.com batch programming challenges are
not a gauntlet to 4DOS afficionados.

The followups have been redirected to alt.religion.computers.

..................................................................
Prof. Timo Salmi
Moderating at garbo.uwasa.fi anonymous FTP archives 128.214.87.1
Faculty of Accounting & Industrial Management; University of Vaasa
Internet: ts@uwasa.fi Bitnet: salmi@finfun   ; SF-65101, Finland
Newsgroups: comp.os.msdos.programmer
From: rnichols@cbnewsg.cb.att.com (robert.k.nichols)
Subject: Re: I/O PORTS ???
Summary: Does ANYBODY have any info about C&T 82C710
Keywords: universal peripheral controller
Organization: AT&T
Date: Sat, 12 Sep 1992 05:30:35 GMT

In article <0PBQBTL4@dri.com> frotz@novell.com writes:
>huisjes@cs.vu.nl (Huisjes M) writes:
>
>]Does anybody know where to find a book/article/file on MS-DOS I/O ports?
>]In my DOS manual there is only a short list of which ports there are, but
>]I would like to know exactly WHICH ports there are and HOW to program them.
>]Thanx in advance, everybody!
...

On the same basic topic, does anybody out there have information on
programming the Chips & Technologies 82C710 Universal Peripheral
Controller?  It is used to implement the serial and parallel port
interfaces which my PC provides right on the motherboard.  It is a highly
configurable chip, and I need to know how to configure it (even the
configuration port itself is configurable to a new I/O port address).

I would really prefer not to resort to disassembling my BIOS and the one
other program I have that talks to this chip.

Bob Nichols
rnichols@ihlpm.ih.att.com
From: phys169@csc.canterbury.ac.nz
Newsgroups: comp.os.msdos.programmer
Subject: Sorting extended character sets (was Re: The Box-Drawing Characters
Date: 13 Sep 92 23:30:58 GMT
Organization: University of Canterbury, Christchurch, New Zealand

In article <Bu9Lv8.6pL@ireq.hydro.qc.ca>, beaurega@ireq.hydro.qc.ca (Denis Beauregard) writes:
> There is a "natural" method of sorting according to which language
> (i.e. French, not Basic :-)  ).  DOS sort in recent versions takes care
> of that.  The method is quite simple (no idea if they do that, but I
> do that in my own qsort-based psort program) : if under 0x80, keep it
> as is (lowercase or lowercase if needed), if over, using a table lookup,
> remap the character...

I've always wonderred what the "proper" way is to sort letters with accent
marks (grave, acute, umlaut, etc). Could somebody please explain the order of,
for example, the standard IBM PC extended characters:  131, 132, 133, 134 and
160, which, presumably, come after 97 (a) but before 98 (b)?

I presume all this changes when different country pages are selected, and when
you are running MS-Windows, and when outputting to a variety of printers all
with their own characters sets (and so collating sequences).

Mark Aitchison, University of Canterbury, New Zealand.
Newsgroups: comp.os.msdos.programmer,sci.math.symbolic
From: zappe@mikro.ee.tu-berlin.de (Harald Zappe)
Subject: Re: studying executables
Organization: ZRZ/TU-Berlin
Distribution: comp
Date: Sun, 6 Sep 1992 18:09:22 GMT

One big problem in debugging and/or analyzing executables is self-modifying
code. There are 2 sections were this is done:

1. viruses: some years ago I studied the 1704-Virus, which used a self-
            encryption algorithm.
   copyprotection: ... several encryption & collection technics ...

2. exe-file-compressors: BTW this is an encryption too, but with another
            purpose. There seems to be 4 (or more) popular compressors:

            LINK/e (or EXEPACK) 
            LZEXE  (signature LZ91)
            PKLITE (signature PKLITE Copr. 1990-91 PKWARE Inc. All Rights Reserv
                    ed)
            ???    (signature jr0)

In all cases you must run a part of the program (or just emulate the decoder)
to get the rest of the program/data out of the encoded/packed data. Until now
I always did this with the help of a debugger (and most important: under human
control). 

Harald

#----------------------------------------------------------------------------

zappe@mikro.ee.tu-berlin.de      | |
zappe@sony1.sietec.de            |-+-
zappe@idefix.sietec.de           | |/
                                   /
                                  /__
Newsgroups: comp.os.msdos.programmer
From: rnichols@cbnewsg.cb.att.com (robert.k.nichols)
Subject: Re: Fast floppy writing techniques
Summary: Smartdrv can help -- if you're bold enough to use it
Organization: AT&T
Date: Fri, 11 Sep 1992 19:51:12 GMT

In article <BuF2p7.CBC@DMI.USherb.CA> famus2@DMI.USherb.CA (Projet2 Famus) writes:
>Hi, I was wondering if anyone has C code for fast file writing to floppies.
>The application that I'm writing compresses the data before writing to disk,
>but the bottleneck is the floppy.  I'm currently trying to optimize disk
>writing by using a technique similar to XCOPY, but if I had code that
>resembled XCOPY already written that might help me meet my deadline.
...

Enabling SMARTDRV's write-behind cache for the floppy drive can
give dramatic improvement.  BUT, you have to be brave and bold to
try it, and careful enough not to snatch the floppy from the drive
as soon as you application thinks it's done, because SMARTDRV may
still be writing for a while.

I often do this ("smartdrv a+") when copying a large number of files
to a floppy.  It saves all the seeking back and forth between the
directory and the user data area.  With 2MB of cache (when not in
Windows), the copy operation runs at the speed of the hard drive and
completes; the floppy is still tick, tick, ticking along writing tracks
as fast as possible.  I wait for a "smartdrv /c" to return before
removing the floppy, and all is well.  (I also do a "smartdrv a" to get
back into a safer mode.)

It should be possible to get this behavior from within an application,
but I know of no other way than loading and executing SMARTDRV with
the apropriate parameters, and a large app. probably wouldn't have
enough memory available to do this.

Bob Nichols
rnichols@ihlpm.ih.att.com
Xref: sparky comp.os.msdos.programmer:9252 comp.os.msdos.misc:5166
From: sweh@spuddy.uucp (Stephen Harris)
Newsgroups: comp.os.msdos.programmer,comp.os.msdos.misc
Subject: Re: Disk Drive Purchase?
Date: 10 Sep 92 21:10:38 GMT
Organization: Spuddy's Public Usenet Domain

In article <exuptr.458.716059101@exu.ericsson.se> exuptr@exu.ericsson.se (exuptr@exu.ericsson.se) writes:
>In article <2aab4eed@ralf> Ralf.Brown@B.GP.CS.CMU.EDU writes:
>>are 1024 cyl x 64 heads x 63 sectors/track--a little less than 4G sectors
>Now this one makes sense.  Except that BIOS does not limit you to 1024
>cylinders, that is DOS.  So theoretically you could have 2048 x 64 x 63.

No, originally the *BIOS* only had 10 bits for the cylinder address.
Later more modern Bios's allow 12 bits (4096 cylinders) but since that is
non standard, DOS can not make use of this.

From Ralf's interrupt list....
----------1302-------------------------------
INT 13 - DISK - READ SECTOR(S) INTO MEMORY
	AH = 02h
	AL = number of sectors to read (must be nonzero)
	CH = low eight bits of cylinder number
	CL = sector number (bits 0-5)
	     high two bits of cylinder (bits 6-7, hard disk only)
	DH = head number
	DL = drive number (bit 7 set for hard disk)
	ES:BX -> data buffer
Return: CF set on error
	    if AH = 11h (corrected ECC error), AL = burst length
	CF clear if successful
	AH = status (see AH=01h)
	AL = number of sectors transferred
Notes:	errors on a floppy may be due to the motor failing to spin up quickly
	  enough; the read should be retried at least three times, resetting
	  the disk with AH=00h between attempts
	AWARD AT BIOS extended to handle more than 1024 cylinders by placing
	  bits 10 and 11 of the cylinder number into bits 6 and 7 of DH
SeeAlso: AH=03h,AH=0Ah
-- 
                               Stephen Harris
               sweh@spuddy.uucp    ...!uknet!axion!spuddy!sweh

 * Meeeeow ! Call Spud the Cat on > +44 203 638780 < for free Usenet access *
Newsgroups: comp.os.msdos.programmer
From: pynq@quads.uchicago.edu (George Jetson)
Subject: Re: Rebooting (again... bleh!)
Reply-To: pynq@midway.uchicago.edu
Organization: D. J. Dougherty & Associates
Date: Sat, 5 Sep 1992 00:56:57 GMT

In article <1992Sep5.004058.25572@midway.uchicago.edu> I wrote:

>	I mean, I know I end up sounding like the world's biggest
>	weenie, but its like it would be nice if someone would compile
>	it and put it on an FTP site somewhere.
>
>I did search SIMIBM.IDX, on keyword WARM, and didn't find anything
>particularly recent.

Also, a couple other questions:
	1) The FAQ entry does the INT 15 thing, simulating Ctrl/Alt/Del
	   to flush the cache, but then does the actual boot via the usual
	   call of FFFF:0.  Wouldn't it be better to do the actual boot
	   via the simualated C/A/D?  (I'm thinking of what will happen
	   if I run this program inside a DV window [I'm scared to try
	   it]  Ideally a warm reboot program ought to simply close the
	   window.)
	2) What about the fact that special considerations are often
	   needed to reliably reboot when a V86 program like QEMM is
	   running?  I know for a fact that, at least in assembly,
	   simply jumping to FFFF:0 doesn't always work.

It seems like the FAQ entry could be more complete.  (Not that I'm
complaining, mind you...)

************************************************************************
A note to new readers:  the weasely :-) symbol is frowned upon in this
group.  Any questions, see Phil Gustafson who will gladly rearrange your
diodes for you.
			- From the AFU FAQ -

	- pynq@quads.uchicago.edu, who is still costing the net
	  hundreds, if not thousands, of dollars, every time he posts -
************************************************************************
From: mlevis@ringer.cs.utsa.edu (Mike Levis)
Newsgroups: comp.os.msdos.programmer
Subject: Re: UNZIP'ing Borland's ".CA1" files
Date: 14 Sep 92 04:19:33 GMT
Organization: University of Texas at San Antonio

In article <1992Sep14.025407.29256@monu6.cc.monash.edu.au> enu321d@barney.eng.monash.edu.au (A. Walker) writes:
>A friend of mine is wonderring how to combine and unzip the 
>'file.ca1 file.ca2 ...' files
>supplied in Borland C++ 3.0(+App frame works) distribution disks.  
>Quote 'Its a real pain
>to go thru the whole installation procedure (12 disks!) just to install
>some extra part of BC++. There is no option to avoid installation of
>the main binaries....."
>	I suggested he 'copy file.ca1+file.ca2 file.zip /b' but unzip
>reports a CRC error about mid-way ie the join was unsuccessful.
>
>	Thanks
>	Junaid

You need to remove the first four bytes from each "*.ca?" file before
you concatenate it.  After you do this, the resulting file will be
normal.  I guess you will have to write a program to strip off the
first four bytes.

-- 
====== Mike Levis   mlevis@ringer.cs.utsa.edu ======
"I believed what I was told, I thought it was a good   .--.
life, I thought I was happy.  Then I found something  (OS/2)
that changed it all..."  --  Anonymous, 2112  [Rush]   ~--~
From: vincent@datmuc.UUCP (vincent)
Newsgroups: comp.os.msdos.programmer
Subject: C700 streams
Date: 7 Sep 92 15:22:12 GMT



//////////////////////  cut here /////////////////////////////////

#include	<fstream.h>
#include	<iomanip.h>

main (int argc, char **argv)
{
	fstream ci;
	char s [3];

	ci. open (argv [1], ios::in | ios::binary);
	ci. unsetf (ios::skipws);

	s [1] = '_';
	s [2] = '\0';

	while (ci. good ()) {
		ci >> s [0];
		if (ci. eof ())
			break;
		cout << s;
	}
}

//////////////////////  cut here /////////////////////////////////


Looks benign, well it is. BUT I've got a problem with it.

My input file contains "Hello World!"

My output is:

__e_l_l_o _W_o_r_l_d_!_
_


If I remove ios::binary from my open input file it works as expected.

A N Y   I D E A S   ? ? ?

P.S. Of course I played with this piece of code for a while and found
some solutions (i.e. replace the string whith a char) but I would
like to know more about this. I've also used CodeView but it didn't
help me. I know now that the string is correctly passed to the cout
manipulator. And that it affect only the first charater of that string
funy it looks like the second char ('_') is duplicated in the first
position; ?????

             }8-[] 

vincent@datmuc.dat.de
From: rwed@hal.gnu.ai.mit.edu (N7YVM)
Newsgroups: comp.os.msdos.programmer
Subject: Re: malloc overhead?
Date: 9 Sep 92 02:21:23 GMT
Organization: /etc/organization

In article <DAVIS.92Sep8201040@pacific.mps.ohio-state.edu> davis@pacific.mps.ohio-state.edu  (John E. Davis) writes:

>important. If I malloc some space of length size, how much additional overhead

I wondered about this too.. without trying to remember too many details,
I noticed all my mallocs in TurboC were displayed as pointers in the form
segment:0008.. The word at segment:0000 was the size of my block+8,
the word at segment:2 looked like a pointer to another block.. the others
I couldnt determine.. 

Id be interested in finding out what this information is..
From: frampton@vicuna.ocunix.on.ca (Steve Frampton)
Newsgroups: comp.os.msdos.programmer
Subject: Strange problems with Borland C++ 3.0
Date: 9 Sep 92 02:35:22 GMT
Reply-To: frampton@vicuna.ocunix.on.ca
Followup-To: poster
Organization: Vicuna Systems, Kingston, ON (613) 547-5066

Hi everyone:

I have three questions I am hoping someone will be able to enlighten me 
on.

(1) Everybody knows about the "sticky shift" problem with the Borland 
editor.  Thing is, I've tried all the suggestions (IGNOREA20 and 
UNUSUAL8042 as switches to QEMM, as well as a device driver called 
KBDFIX.SYS that apparently works wonders with WordPerfect) but the 
problem remains.  Has anyone come up with a fix for this yet?

(2) Here's a neat bug:  Y'know how you can hold down the ALT key and type 
a 3-digit ASCII code to generate a special character?  Great for line 
drawing, etc., isn't it!  However, try typing ALT-224 and your computer 
will freeze up!!  Cute bug, Borland, I lost over an hour of work the 
first time that happened!  How about timed-backups for the next version?  
:-)

(3) Has anybody been able to get ungetch() to work?  I am using the DOS 
int 0x21 function to check keyboard status (ah=0x0b on entry, al=0xff on 
exit if key is ready) and to read in a key (ah=0x07 on entry, al=char on
exit) and yet pushing a key to the buffer with ungetch() doesn't seem to
work!  I believe I have gotten it to work with getch() but I really have
a need to use these DOS int 0x21 functions.  Help!

Well, that's about it.  Any information you can provide on any of these
problems would be most appreciated!

Please respond via e-mail as I don't have read-access to this group.  I
will be more than happy to follow-up with a summary, as these problems
are probably oft-encountered and are certainly interesting.

Thanks in advance!

+-----------------------------------------------+--------------------+
| Steve Frampton - frampton@vicuna.ocunix.on.ca | Steve Frampton     |
| I collect postcards!  If you send me one from | 501-A Princess St. |
| your area, I'll send one in return.  Send to >| Kingston, Ontario  |
| (Don't forget both email and mailing address) | CANADA   K7L 1C3   |
+-----------------------------------------------+--------------------+
Newsgroups: comp.os.msdos.programmer,alt.msdos.programmer
From: mcastle@cs.umr.edu (Michael R Castle)
Subject: Turbo C++--forcing vars into CSEG
Date: Tue, 8 Sep 1992 19:59:18 GMT
Organization: University of Missouri - Rolla
Originator: mcastle@mcs213d.cs.umr.edu


I'm trying to use Turbo C++ 1.0 to compile the GNU swapping-spawn library.

The library was originally designed for MSC 6.0 and uses a construct that 
forces data to be stored in the code segment.

Is there any similiar directive for Turbo??  I was hoping that using something
like 

int _cs var1; 

would do that, but the compiler doesn't like it.  I'm wondering if just 
replacing _cs with near would do the trick, but I'm not sure that that just
doen't fool with the data segment.

Anyone know of a way to accomplish this (w/o going into assembler)??

all help appreciated,
mrc

also: anyone know what the typedef/struct  off_t  is, in MSC???
From: rozin@cs.pitt.edu (Roman Rozin)
Newsgroups: comp.os.msdos.programmer
Subject: IBM 8516 Touch Screen Device Driver
Date: 12 Sep 92 23:41:42 GMT
Organization: Univ. of Pittsburgh Computer Science


I am writing a program in which I need to set user-defined subroutine
(function 14) of the device driver.  

The array of device driver function pointers I declared as:
    int (__far __pascal *(*touch_func)[])(int far *, int far *);

I obtain the address of the array (ax = 0xabcd, bx = 0, int 0x7f), and
all other functions seem to be working right except 14..

I set the call flag to 0x20, and the call to
	(*touch_func)[14](...)  returns 0 (ok status), but my
subroutine does not get called when the screen is touched.  Anyone have
any ideas on what I could be doing wrong, or if I'm missing something?
Thanks in advance (I hope it's the right newsgoup for the question).

Roman Rozin
Newsgroups: comp.os.msdos.programmer
From: wagner@main.mndly.umn.edu (Rick Wagner)
Subject: Borland C++ 3.1 - Store data like MARK/RELEASE
Organization: the Minnesota Daily (U of MN Student Newspaper)
Date: Wed, 9 Sep 1992 21:12:56 GMT


I need to have a C program allocate memory at the top of conventional 
mem, and exit the program leaving this data intact.  Later I need to run a 
different program that reads this data and then frees it.  I've looked at 
Ralf Browns ASMI stuff but can't figure out how to get it to do that.  
I've alse looked at the source code for MARK/RELEASE but I've had great 
difficulty reading and translating the pascal source.

Any suggestions (English or Code) would be most appreciated.


Thanks...
Rick Wagner

----------------------------------------------------------------------------
  			WAGNER@MAIN.MNDLY.UMN.EDU	
----------------------------------------------------------------------------
Newsgroups: comp.os.msdos.programmer
From: etxerus@james16.jamesdom (Hans Beckerus LG/THB)
Subject: Help! Interrupt for graphics adapter detection
Followup-To: comp.os.msdos.programmer
Reply-To: etxerus@james16.jamesdom
Organization: Ericsson Telecom, Stockholm, Sweden
Date: Tue, 15 Sep 1992 07:00:24 GMT

Hi Folks,
     I'm writing a program in which I need to know which type
of hardware graphics adapter being used. I'm only interested
in if it's VGA, EGA, CGA or other. So my question is which
interrupt to use for this purpose. Looking forward to here 
from you. All answers are welcome either here to COMP or
by email.

Cheers!
                                 /Hans


_______________________________________________________
Hans Beckerus                            Voice    : +46 8 719 59 60
TN/ETX/LG/THB                   Memo    : ETX.ETXERUS  
Ericsson Telecom AB            Internet  : etxerus@james.ericsson.se 
AXE System Design                                : etxerus@erigate.ericsson.se 
126 25 Stockholm   
SWEDEN
From: bx304@cleveland.Freenet.Edu (Jeff Epler)
Newsgroups: comp.os.msdos.programmer
Subject: Setting VGA palette
Date: 7 Sep 1992 14:37:59 GMT
Organization: Case Western Reserve University, Cleveland, OH (USA)
Reply-To: bx304@cleveland.Freenet.Edu (Jeff Epler)
NNTP-Posting-Host: slc5.ins.cwru.edu


Could someone mail me short code (Preferrable TC, not TC++ or ASM) for
setting the VGA palette?  I'm using the VGAKIT code in a program of
mine, but I'd like to change the palette.

(PS Is there a later version that offers this ability?  I think I may
be using an older copy.)
-- 
|Jeff Epler               Additions Welcome           c(-8 ;-) >{8-) |
| :) (=( =-] (-= Celebrating the variety of faces =-> :^) {-= |-) (: |
| >X^P 8-[                                       __ Lincoln, Nebraska|
|   						 \/ IRC Synger       |
Newsgroups: comp.os.msdos.programmer
From: enu321d@barney.eng.monash.edu.au (A. Walker)
Subject: UNZIP'ing Borland's ".CA1" files
Organization: Monash University
Date: Mon, 14 Sep 1992 02:54:07 GMT

A friend of mine is wonderring how to combine and unzip the 
'file.ca1 file.ca2 ...' files
supplied in Borland C++ 3.0(+App frame works) distribution disks.  
Quote 'Its a real pain
to go thru the whole installation procedure (12 disks!) just to install
some extra part of BC++. There is no option to avoid installation of
the main binaries....."
	I suggested he 'copy file.ca1+file.ca2 file.zip /b' but unzip
reports a CRC error about mid-way ie the join was unsuccessful.

	Thanks
	Junaid
Newsgroups: comp.os.msdos.programmer
From: yawei@bronze.ucs.indiana.edu (~{QG9p~})
Subject: Re: fclose() messes up heap
Organization: Indiana University
Date: Sun, 6 Sep 1992 18:38:05 GMT

In article <1992Sep3.210532.22036@tc.cornell.edu> elan@tasha.cheme.cornell.edu (Elan Feingold) writes:
>
>In a program I'm writing, after I fclose() a file, it seems to mess up the free space of the core, and I'm really not sure why.  It seems that this sequence of events messes up the memory.
>
>1. Open file
>2. Allocate and deallocate memory
>3. Close file

Not sure if this is the case here, but doing "fclose" after an "open",
or a "close" after a "fopen" frequently crash the system with some 
compilers. It's a good idea to get into a habit of always using one
pair and never the other.

Also closing a NULL file ptr (probably after a failed open) could
be problematic as well.

 Ya-Gui Wei


Xref: sparky comp.os.msdos.programmer:9186 comp.os.msdos.misc:5108