home *** CD-ROM | disk | FTP | other *** search
- /**
- *
- * Name qymodel -- Report IBM model code
- *
- * Synopsis model = qymodel();
- *
- * char model IBM model code:
- * IBM_PC (0xff) if IBM PC
- * IBM_XT (0xfe) if IBM PC-XT
- * or Portable PC
- * IBM_JR (0xfd) if IBM PCjr
- * IBM_AT (0xfc) if IBM PC-AT
- * IBM_CV (0xf9) if IBM PC Convertible
- *
- * Description This function returns a code indicating which IBM PC
- * model the program is running on. The value is also
- * saved in the global variable b_pcmodel declared in
- * BQUERY.H.
- *
- * Returns model IBM model code
- *
- * Version 3.0 (C)Copyright Blaise Computing Inc. 1986
- *
- **/
-
- #include <bquery.h>
-
- char b_pcmodel = 0; /* IBM PC Model Code */
-
- char qymodel()
- {
- static ADS model_ads = {0x000e,0xffff};
- ADS flag_ads;
-
- utabsptr(&b_pcmodel,&flag_ads);
- utslmove(&model_ads,&flag_ads,1); /* Fetch model code */
-
- return b_pcmodel;
- }