home *** CD-ROM | disk | FTP | other *** search
- /**********************************************
- * Programm SHOWCOM. Zeigt die Parameter aller
- * verfügbaren seriellen Schnittstellen an.
- ***********************************************/
-
- #include <dos.h>
- #include <stdio.h>
- #include <conio.h>
-
- #include "getcom.c"
-
- /*=======================================================================*/
-
- int main()
- {
- char *VersionString="SHOWCOM V2.3 (C) 1990 Richard Franz/c't";
- int i; /* Laufvariablen für Schleifen */
- int getcom(); /* Deklaration Funktion getcom */
- int ret;
- unsigned char far *maxcom;
- int commax;
-
- FP_SEG(maxcom) = 0x0040;
- FP_OFF(maxcom) = 0x0011; /* Anzahl COM-Schnittstellen */
- commax = (*maxcom & 0x0e) >> 1; /* aus Equipmentword isolieren */
-
- printf("%s\n",VersionString);
- for (i=1 ; i<=commax ; i++)
- {
- ret = getcom(i);
- if (ret) /* Abbruch bei Fehler in GETCOM */
- break;
- }
- return(ret); /* Errorlevel aus dem letzten */
- } /* Aufruf von GETCOM */
-