Diff for /np2/generic/np2info.c between versions 1.3 and 1.7

version 1.3, 2004/02/19 11:32:12 version 1.7, 2004/06/04 16:11:03
Line 4 Line 4
 #include        "cpucore.h"  #include        "cpucore.h"
 #include        "pccore.h"  #include        "pccore.h"
 #include        "iocore.h"  #include        "iocore.h"
 #include        "bios.h"  
 #include        "sound.h"  #include        "sound.h"
 #include        "fmboard.h"  #include        "fmboard.h"
 #include        "np2info.h"  #include        "np2info.h"
Line 17  static const char str_8MHz[] = "8MHz"; Line 16  static const char str_8MHz[] = "8MHz";
 static const char str_notexist[] = "not exist";  static const char str_notexist[] = "not exist";
 static const char str_disable[] = "disable";  static const char str_disable[] = "disable";
   
   static const char str_cpu[] =
                                                   "8086-2\0"                                      \
                                                   "70116\0"                                       \
                                                   "80286\0"                                       \
                                                   "80386\0"                                       \
                                                   "80486\0"                                       \
                                                   "Pentium\0"                                     \
                                                   "PentiumPro";
 static const char str_winclr[] =  static const char str_winclr[] =
                                                 "256-colors\065536-colors\0full color\0true color";                                                  "256-colors\0"                          \
                                                   "65536-colors\0"                        \
                                                   "full color\0"                          \
                                                   "true color";
 static const char str_winmode[] =  static const char str_winmode[] =
                                                 " (window)\0 (fullscreen)";                                                  " (window)\0"                           \
                                                   " (fullscreen)";
 static const char str_grcgchip[] =  static const char str_grcgchip[] =
                                                 "\0GRCG \0GRCG CG-Window \0EGC CG-Window ";                                                  "\0"                                            \
 static const char str_clrmode[] =                                                  "GRCG \0"                                       \
                                                 "(Digital)\0(Analog)";                                                  "GRCG CG-Window \0"                     \
                                                   "EGC CG-Window ";
   static const char str_vrammode[] =
                                                   "Digital\0"                                     \
                                                   "Analog\0"                                      \
                                                   "256colors";
   static const char str_vrampage[] =
                                                   " page-0\0"                                     \
                                                   " page-1\0"                                     \
                                                   " page-all";
 static const char str_chpan[] =  static const char str_chpan[] =
                                                 "none\0Mono-R\0Mono-L\0Stereo";                                                  "none\0"                                        \
                                                   "Mono-R\0"                                      \
                                                   "Mono-L\0"                                      \
                                                   "Stereo";
 static const char str_fmboard[] =  static const char str_fmboard[] =
                                                 "none\0PC-9801-14\0PC-9801-26\0PC-9801-86\0"    \                                                  "none\0"                                        \
                                                 "PC-9801-26 + 86\0PC-9801-118\0"                                \                                                  "PC-9801-14\0"                          \
                                                 "PC-9801-86 + Chibi-oto\0"                                              \                                                  "PC-9801-26\0"                          \
                                                 "Speak board\0Spark board\0AMD-98";                                                  "PC-9801-86\0"                          \
                                                   "PC-9801-26 + 86\0"                     \
                                                   "PC-9801-118\0"                         \
 static const char str_V30[] = "V30";                                                  "PC-9801-86 + Chibi-oto\0"      \
 static const char str_i286[] = "i286";                                                  "Speak board\0"                         \
                                                   "Spark board\0"                         \
                                                   "AMD-98";
   
 static const char str_clockfmt[] = "%d.%1dMHz";  static const char str_clockfmt[] = "%d.%1dMHz";
 static const char str_memfmt[] = "%3uKB";  static const char str_memfmt[] = "%3uKB";
 static const char str_memfmt2[] = "%3uKB + %uKB";  static const char str_memfmt2[] = "%3uKB + %uKB";
 static const char str_memfmt3[] = "%d.%1dMB";  static const char str_memfmt3[] = "%d.%1dMB";
 static const char str_width[] = "width-%u";  static const char str_width[] = "width-%u";
 static const char str_gdcpage[] = "page-%u %s";  static const char str_dispclock[] = "%u.%.2ukHz / %u.%uHz";
   
 static const char str_pcm86a[] = "   PCM: %dHz %dbit %s";  static const char str_pcm86a[] = "   PCM: %dHz %dbit %s";
 static const char str_pcm86b[] = "        %d / %d / 32768";  static const char str_pcm86b[] = "        %d / %d / 32768";
Line 60  static void info_ver(char *str, int maxl Line 84  static void info_ver(char *str, int maxl
   
 static void info_cpu(char *str, int maxlen, NP2INFOEX *ex) {  static void info_cpu(char *str, int maxlen, NP2INFOEX *ex) {
   
         milstr_ncpy(str, (CPU_TYPE & CPUTYPE_V30)?str_V30:str_i286, maxlen);          UINT    family;
   
   #if defined(CPU_FAMILY)
           family = min(CPU_FAMILY, 6);
   #else
           family = (CPU_TYPE & CPUTYPE_V30)?1:2;
   #endif
           milstr_ncpy(str, milstr_list(str_cpu, family), maxlen);
         (void)ex;          (void)ex;
 }  }
   
Line 151  static void info_gdc(char *str, int maxl Line 182  static void info_gdc(char *str, int maxl
         (void)ex;          (void)ex;
 }  }
   
   static void info_gdc2(char *str, int maxlen, NP2INFOEX *ex) {
   
           char    textstr[32];
   
           SPRINTF(textstr, str_dispclock,
                                                   gdc.hclock / 1000, (gdc.hclock / 10) % 100,
                                                   gdc.vclock / 10, gdc.vclock % 10);
           milstr_ncpy(str, textstr, maxlen);
           (void)ex;
   }
   
 static void info_text(char *str, int maxlen, NP2INFOEX *ex) {  static void info_text(char *str, int maxlen, NP2INFOEX *ex) {
   
 const char      *p;  const char      *p;
Line 170  const char *p; Line 212  const char *p;
 static void info_grph(char *str, int maxlen, NP2INFOEX *ex) {  static void info_grph(char *str, int maxlen, NP2INFOEX *ex) {
   
 const char      *p;  const char      *p;
           UINT    md;
           UINT    pg;
         char    grphstr[32];          char    grphstr[32];
   
         if (!(gdcs.grphdisp & GDCSCRN_ENABLE)) {          if (!(gdcs.grphdisp & GDCSCRN_ENABLE)) {
                 p = str_disable;                  p = str_disable;
         }          }
         else {          else {
                 SPRINTF(grphstr, str_gdcpage, gdcs.access,                  md = (gdc.analog & (1 << GDCANALOG_16))?1:0;
                                                                 milstr_list(str_clrmode, (gdc.analog)?1:0));                  pg = gdcs.access;
   #if defined(SUPPORT_PC9821)
                   if (gdc.analog & (1 << (GDCANALOG_256))) {
                           md = 2;
                           if (gdc.analog & (1 << (GDCANALOG_256E))) {
                                   pg = 2;
                           }
                   }
   #endif
                   milstr_ncpy(grphstr, milstr_list(str_vrammode, md), sizeof(grphstr));
                   milstr_ncat(grphstr, milstr_list(str_vrampage, pg), sizeof(grphstr));
                 p = grphstr;                  p = grphstr;
         }          }
         milstr_ncpy(str, p, maxlen);          milstr_ncpy(str, p, maxlen);
Line 251  static void info_extsnd(char *str, int m Line 305  static void info_extsnd(char *str, int m
 static void info_bios(char *str, int maxlen, NP2INFOEX *ex) {  static void info_bios(char *str, int maxlen, NP2INFOEX *ex) {
   
         str[0] = '\0';          str[0] = '\0';
         if (biosrom) {          if (pccore.rom & PCROM_BIOS) {
                 milstr_ncat(str, str_biosrom, maxlen);                  milstr_ncat(str, str_biosrom, maxlen);
         }          }
         if (soundrom.name[0]) {          if (soundrom.name[0]) {
Line 311  static const INFOPROC infoproc[] = { Line 365  static const INFOPROC infoproc[] = {
                         {"MEM2",                info_mem2},                          {"MEM2",                info_mem2},
                         {"MEM3",                info_mem3},                          {"MEM3",                info_mem3},
                         {"GDC",                 info_gdc},                          {"GDC",                 info_gdc},
                           {"GDC2",                info_gdc2},
                         {"TEXT",                info_text},                          {"TEXT",                info_text},
                         {"GRPH",                info_grph},                          {"GRPH",                info_grph},
                         {"SND",                 info_sound},                          {"SND",                 info_sound},

Removed from v.1.3  
changed lines
  Added in v.1.7


RetroPC.NET-CVS <cvs@retropc.net>