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

Re: The ports (was: Re: LAN port)



>I am not yet programming under MiNT; actually I don't even yet have
>it...BTW: can you tell me what is the bare minimum I need to say "I am
>running MiNT", and which is the best place to get

I would go to src.doc.ic.ac.uk - its has a mirror of atari.archive.umich.edu
among other things, I think its /pub/atari/umich.edu/Mint.  You should be
able to get a binary of freemint-1.12.5 in there.  The kernel is good
enough to make use of the features.

>Well, I cannot really say that I am programming either. But ca
>all the device numbers, just to let me start to practice...Another BTW: I

OK, BIOS device numbers -

 BIOS	NAME				GEMDOS	
-----------------------------------------------
  0	PRN:,/dev/prn			 -3 
  1	AUX:,/dev/aux			 -2
  2	CON:,/dev/con			 -1
  3	MIDI:,/dev/midi			-4 (IN), -5 (OUT)
  4	KYD:,/dev/kbd
  5     console in raw mode 
  6     modem1
  7     modem2 (SCC channel B)
  8     TT (MFP2, SERIAL1),
        Falcon (SCC A)
  9     SCC A (SERIAL 2)
        Falcon (not used)

 GEMDOS handles 0 and 1 (stdin and stdout) are mapped to -1, which
 is the same as BIOS 2 (but you can change where -1 points, which 
 will in turn affect where BIOS 2 points).  GEMDOS 2 is normally
 mapped to -2, BIOS 1, but is normally reopened to -1 (by redirecting
 handle 2, which does NOT affect handle -2 or BIOS device 1).  Gemdos
 handle 3 is normally open to GEMDOS -3, or BIOS device 0, but it
 is rarely used.  GEMDOS 4 and 5 are unused, but I think MiNT still
 passes them to children.  MS-DOS uses 0,1 for stdin, 2 for stderr,
 3 for aux:, and 4 for prn: - a bit better than our mess.  Unix is
 normally 0 for stdin, 1 for stdout, and 2 for stderr (like DOS, or
 the modified atari scheme with 2 reopened from aux to stderr), and
 3-5 are not special.

 Note:  AUX, device 1, is normally mapped to Device 6.
 TOS < 2.00 did not have BIOS numbers > 5, and you could
 not change the mappings, BIOS 1 was always modem1.

 Are you confused yet?  Let's say that you have standard GEMDOS handles,
 0-5, most of which are pre-opened by the OS to point to certain BIOS
 devices, and they are inherited by child processes.  MiNT adds negative
 GEMDOS handles that change where these BIOS devices, and therefore,
 any newly opened GEMDOS files, point to.  MiNT provides devices that
 are openable as U:\dev\ that are the same as GEMDOS names AUX:,CON:,
 PRN:, etc, as well as non-redirectable devices /dev/modem1, /dev/console,
 /dev/centr (for PRN:), etc, that the other devices are normally connected
 to.

>use the Lattice C compiler from HiSoft: if I ever start going MiNT, is this
>compiler OK to build projects?

Yeah, you might wanna get the MiNT-LIB though as many Unix function calls
will not make use of MiNT features without the MiNT-LIB.