home *** CD-ROM | disk | FTP | other *** search
/ DOS/V Power Report 1997 July / VPR9707B.ISO / DRIVER / CANOPUS / winnt / PWNT_117 / PWNT_117.LZH / OEMSETUP.INF next >
INI File  |  1996-10-02  |  18KB  |  500 lines

  1. ;-----------------------------------------------------------------------
  2. [Identification]
  3.     OptionType = VIDEO
  4. ;-----------------------------------------------------------------------
  5. [LanguagesSupported]
  6.     ENG
  7.  
  8. ;-----------------------------------------------------------------------
  9. [Options]
  10.     "Canopus S3DV 640x480x8, 60 Hz"   = PW3D,   8,   640,  480, 60, ""
  11.     "Canopus S3AT 640x480x8, 60 Hz"   = PW,     8,   640,  480, 60, ""
  12.     "Canopus S3AT 640x480x8, 6O Hz"   = PW,     8,   640,  480, 60, ""
  13.     "Canopus S3CB 640x480x8, 60 Hz"   = PW,     8,   640,  480, 60,  0
  14.     "Canopus S3LB 640x480x8, 60 Hz"   = PW,     8,   640,  480, 60,  1
  15.     "Canopus S3T2 640x480x8, 60 Hz"   = PW,     8,   640,  480, 60,  3
  16.     "Canopus PM   640x480x8, 60 Hz"   = PW,     8,   640,  480, 60,  4
  17.     "Canopus PW9100 640x480x8, 60 Hz" = PW9100, 8,   640,  480, 60, ""
  18.  
  19. ;-----------------------------------------------------------------------
  20. [MiniportDrivers]
  21.     PW     = !SERVICE_KERNEL_DRIVER, Video, !SERVICE_ERROR_IGNORE, 33, {PW},     0, %SystemRoot%\System32\IoLogMsg.dll , 7
  22.     PW3D   = !SERVICE_KERNEL_DRIVER, Video, !SERVICE_ERROR_IGNORE, 33, {PW3D},   0, %SystemRoot%\System32\IoLogMsg.dll , 7
  23.     PW9100 = !SERVICE_KERNEL_DRIVER, Video, !SERVICE_ERROR_IGNORE, 33, {PW9100}, 0, %SystemRoot%\System32\IoLogMsg.dll , 7
  24.  
  25. ;-----------------------------------------------------------------------
  26. [OptionsTextENG]
  27.     "Canopus S3DV 640x480x8, 60 Hz"   = "Power Window 3DV"
  28.     "Canopus S3AT 640x480x8, 60 Hz"   = "Power Window 928II/V, 928II/VLB, 864PCI/VLB"
  29.     "Canopus S3AT 640x480x8, 6O Hz"   = "Power Window 868PCI/VLB, 968PCI, T64V"
  30.     "Canopus S3CB 640x480x8, 60 Hz"   = "Power Window 801, 801+, 801G, 928, 928G, 928II, 805i"
  31.     "Canopus S3LB 640x480x8, 60 Hz"   = "Power Window 928GLB, 928IILB, 964LB"
  32.     "Canopus S3T2 640x480x8, 60 Hz"   = "Power Window T64S, 968"
  33.     "Canopus PM   640x480x8, 60 Hz"   = "Power Window 6410VA"
  34.     "Canopus PW9100 640x480x8, 60 Hz" = "Power Window 9100/9130C"
  35.  
  36. ;---------------------------------------------------------------------------
  37. [Identify]
  38.     ;
  39.     ;
  40.     read-syms Identification
  41.  
  42.     set Status     = STATUS_SUCCESSFUL
  43.     set Identifier = $(OptionType)
  44.     set Media      = #("Source Media Descriptions", 1, 1)
  45.  
  46.     Return $(Status) $(Identifier) $(Media)
  47.  
  48. ;------------------------------------------------------------------------
  49. ; 2. ReturnOptions:
  50. ;
  51. ; DESCRIPTION:   To return the option list supported by this INF and the
  52. ;                localised text list representing the options.
  53. ;
  54. ;
  55. ; INPUT:         $($0):  Language used. ( ENG | FRN | ... )
  56. ;
  57. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL |
  58. ;                                STATUS_NOLANGUAGE
  59. ;                                STATUS_FAILED
  60. ;
  61. ;                $($R1): Option List
  62. ;                $($R2): Option Text List
  63. ;------------------------------------------------------------------------
  64.  
  65. [ReturnOptions]
  66.     ;
  67.     ;
  68.     set Status        = STATUS_FAILED
  69.     set OptionList     = {}
  70.     set OptionTextList = {}
  71.  
  72.     ;
  73.     ; Check if the language requested is supported
  74.     ;
  75.     set LanguageList = ^(LanguagesSupported, 1)
  76.     Ifcontains(i) $($0) in $(LanguageList)
  77.         goto returnoptions
  78.     else
  79.         set Status = STATUS_NOLANGUAGE
  80.         goto finish_ReturnOptions
  81.     endif
  82.  
  83.     ;
  84.     ; form a list of all the options and another of the text representing
  85.     ;
  86.  
  87. returnoptions = +
  88.     set OptionList     = ^(Options, 0)
  89.     set OptionTextList = ^(OptionsText$($0), 1)
  90.     set Status         = STATUS_SUCCESSFUL
  91.  
  92. finish_ReturnOptions = +
  93.     Return $(Status) $(OptionList) $(OptionTextList)
  94.  
  95.  
  96.  
  97. ;---------------------------------------------------------------------------
  98. ; MapToSupportedOption
  99. ;
  100. ; DESCRIPTION:   To map a hardware detected option to the NT Supported
  101. ;                option which represents it.
  102. ;
  103. ; INPUT:         $($0): Option
  104. ;
  105. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL
  106. ;                $($R1): Mapped Option
  107. ;
  108. ;---------------------------------------------------------------------------
  109.  
  110. [MapToSupportedOption]
  111.     ;
  112.     set Status = STATUS_FAILED
  113.     set MappedOption = $($0)
  114.  
  115.     ;
  116.     ; If the option is one we can support using one of our standard options
  117.     ; then map it to the standard option else map it to the default option
  118.     ; which is VGA.
  119.     ;
  120.  
  121.     set OptionList = ^(MapOfOptions, 0)
  122.     ifcontains $($0) in $(OptionList)
  123.         set MappedOption = #(MapOfOptions, $($0), 1)
  124.     else
  125.         set MappedOption = "VGA"
  126.     endif
  127.  
  128.     set Status = STATUS_SUCCESSFUL
  129.     Return $(Status) $(MappedOption)
  130.  
  131.  
  132.  
  133. [ServicesEntry]
  134.     CurrentEntry = "" ? $(!LIBHANDLE) GetDevicemapValue Video \Device\Video0
  135.  
  136.  
  137. ;
  138. ; InstallOption:
  139. ;
  140. ; FUNCTION:  To copy files representing Options
  141. ;            To configure the installed option
  142. ;            To update the registry for the installed option
  143. ;
  144. ; INPUT:     $($0):  Language to use
  145. ;            $($1):  OptionID to install
  146. ;            $($2):  SourceDirectory
  147. ;            $($3):  AddCopy  (YES | NO)
  148. ;            $($4):  DoCopy   (YES | NO)
  149. ;            $($5):  DoConfig (YES | NO)
  150. ;
  151. ; OUTPUT:    $($R0): STATUS: STATUS_SUCCESSFUL |
  152. ;                            STATUS_NOLANGUAGE |
  153. ;                            STATUS_USERCANCEL |
  154. ;                            STATUS_FAILED
  155. ;
  156.  
  157. [InstallOption]
  158.  
  159.     ;
  160.     ; Set default values for
  161.     ;
  162.     set Status       = STATUS_FAILED
  163.     set DrivesToFree = {}
  164.  
  165.     ;
  166.     ; extract parameters
  167.     ;
  168.     set Option   = $($1)
  169.     set SrcDir   = $($2)
  170.     set AddCopy  = $($3)
  171.     set DoCopy   = $($4)
  172.     set DoConfig = $($5)
  173.  
  174.     ;
  175.     ; Check if the language requested is supported
  176.     ;
  177.     set LanguageList = ^(LanguagesSupported, 1)
  178.     Ifcontains(i) $($0) in $(LanguageList)
  179.     else
  180.         set Status = STATUS_NOLANGUAGE
  181.         goto finish_InstallOption
  182.     endif
  183.     read-syms Strings$($0)
  184.  
  185.     ;
  186.     ; check to see if Option is supported.
  187.     ;
  188.  
  189.     set OptionList = ^(Options, 0)
  190.     ifcontains $(Option) in $(OptionList)
  191.     else
  192.         goto finish_InstallOption
  193.     endif
  194.     set OptionList = ""
  195.  
  196.     ;
  197.     ; Option has been defined already
  198.     ;
  199.     set MiniportDriver    = #(Options, $(Option), 1)
  200.     set BitsPerPel        = #(Options, $(Option), 2)
  201.     set XResolution       = #(Options, $(Option), 3)
  202.     set YResolution       = #(Options, $(Option), 4)
  203.     set VRefresh          = #(Options, $(Option), 5)
  204.     set BoardType         = #(Options, $(Option), 6)
  205.  
  206.     set Type              = $(#(MiniportDrivers, $(MiniportDriver), 1))
  207.     set Group             =   #(MiniportDrivers, $(MiniportDriver), 2)
  208.     set ErrorControl      = $(#(MiniportDrivers, $(MiniportDriver), 3))
  209.     set Tag               =   #(MiniportDrivers, $(MiniportDriver), 4)
  210.     set InstalledDisplays =   #(MiniportDrivers, $(MiniportDriver), 5)
  211.     set VgaCompatible     =   #(MiniportDrivers, $(MiniportDriver), 6)
  212.     set EventMessageFile  =   #(MiniportDrivers, $(MiniportDriver), 7)
  213.     set TypesSupported    =   #(MiniportDrivers, $(MiniportDriver), 8)
  214.  
  215.     read-syms ServicesEntry
  216.     detect    ServicesEntry
  217.  
  218. installtheoption = +
  219.  
  220.     ;
  221.     ; Code to add files to copy list
  222.     ;
  223.  
  224.     ifstr(i) $(AddCopy) == "YES"
  225.         set DoActualCopy = NO
  226.         set FileToCheck = #(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  227.         LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\drivers\"$(FileToCheck)
  228.         ifstr(i) $(STATUS) == NO
  229.             set DoActualCopy = YES
  230.             goto addfiles
  231.         endif
  232.         ForListDo $(InstalledDisplays)
  233.             set FileToCheck = #(Files-DisplayDLLs, $($), 2)
  234.             LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\"$(FileToCheck)
  235.             ifstr(i) $(STATUS) == NO
  236.                 set DoActualCopy = YES
  237.             endif
  238.         EndForListDo
  239.  
  240. addfiles = +
  241.         ifstr(i) $(DoActualCopy) == NO
  242.             shell "subroutn.inf" DriversExist $($0) $(String1)
  243.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  244.                 Debug-Output "VIDEO.INF: shelling DriversExist failed"
  245.                 goto finish_InstallOption
  246.             endif
  247.  
  248.             ifstr(i) $($R0) == STATUS_CURRENT
  249.             else-ifstr(i) $($R0) == STATUS_NEW
  250.                 set DoActualCopy = YES
  251.             else-ifstr(i) $($R0) == STATUS_USERCANCEL
  252.                 Debug-Output "VIDEO.INF: User cancelled video installation"
  253.                 goto finish_InstallOption
  254.             else
  255.                 Debug-Output "VIDEO.INF: Error reported in DriversExist routine in SUBROUTN.INF"
  256.                 goto finish_InstallOption
  257.             endif
  258.         endif
  259.  
  260.         ifstr(i) $(DoActualCopy) == YES
  261.  
  262.             shell "subroutn.inf" DoAskSourceEx $(SrcDir) $(String2)
  263.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  264.                 Debug-Output "VIDEO.INF: shelling DoAskSourceEx failed"
  265.                 goto finish_InstallOption
  266.             endif
  267.  
  268.             ifstr(i) $($R0) == STATUS_SUCCESSFUL
  269.                 set SrcDir = $($R1)
  270.                 ifstr(i) $($R2) != ""
  271.                     set DrivesToFree = >($(DrivesToFree), $($R2))
  272.                 endif
  273.             else
  274.                 Debug-Output "VIDEO.INF: User cancelled asking source."
  275.                 goto finish_InstallOption
  276.             endif
  277.  
  278.             install Install-AddCopyOption
  279.             ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  280.                 Debug-Output "VIDEO.INF: Adding video files to copy list failed"
  281.                 goto finish_InstallOption
  282.             endif
  283.         else
  284.             set DoCopy = NO
  285.         endif
  286.  
  287.     endif
  288.  
  289.     ifstr(i) $(DoCopy) == "YES"
  290.         read-syms ProgressCopy$($0)
  291.         install Install-DoCopyOption
  292.         ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_FAILURE"
  293.             Debug-Output "Copying files failed"
  294.             goto finish_InstallOption
  295.         else-ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_USERQUIT"
  296.             set Status = STATUS_USERCANCEL
  297.             goto finish_InstallOption
  298.         endif
  299.     endif
  300.  
  301.     ifstr(i) $(DoConfig) == "YES"
  302.  
  303.         ;
  304.         ; first run a privilege check on modifying the setup node
  305.         ;
  306.  
  307.         shell "registry.inf" CheckSetupModify
  308.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  309.             goto finish_InstallOption
  310.         endif
  311.  
  312.         ifstr(i) $($R0) != STATUS_SUCCESSFUL
  313.             goto finish_InstallOption
  314.         endif
  315.  
  316.         ;
  317.         ; first make a new video entry, the entry is created automatically
  318.         ; enabled
  319.         ;
  320.  
  321.         set ServiceNode   = $(MiniportDriver)
  322.         set ServiceBinary = %SystemRoot%\System32\drivers\#(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  323.  
  324.         set ServicesValues   = { +
  325.                 {Type,           0, $(!REG_VT_DWORD),     $(Type)                  }, +
  326.                 {Start,          0, $(!REG_VT_DWORD),     $(!SERVICE_SYSTEM_START) }, +
  327.                 {Group,          0, $(!REG_VT_SZ),        $(Group)                 }, +
  328.                 {ErrorControl,   0, $(!REG_VT_DWORD),     $(ErrorControl)          }, +
  329.                 {Tag,            0, $(!REG_VT_DWORD),     $(Tag)                   }, +
  330.                 {BinaryPathName, 0, $(!REG_VT_EXPAND_SZ), $(ServiceBinary)         }  +
  331.                 }
  332.  
  333.         set ParametersValues = { +
  334.                 {InstalledDisplayDrivers,     0, $(!REG_VT_MULTI_SZ), $(InstalledDisplays) }, +
  335.                 {VgaCompatible,               0, $(!REG_VT_DWORD),    $(VgaCompatible)     }, +
  336.                 {DefaultSettings.BitsPerPel,  0, $(!REG_VT_DWORD),    $(BitsPerPel)        }, +
  337.                 {DefaultSettings.XResolution, 0, $(!REG_VT_DWORD),    $(XResolution)       }, +
  338.                 {DefaultSettings.YResolution, 0, $(!REG_VT_DWORD),    $(YResolution)       }  +
  339.                 }
  340.  
  341.         ifstr(i) $(VRefresh) != ""
  342.             set VRefreshValue = {DefaultSettings.VRefresh, 0, $(!REG_VT_DWORD), $(VRefresh)}
  343.             set ParametersValues = >($(ParametersValues), $(VRefreshValue))
  344.         endif
  345.  
  346.         ifstr(i) $(BoardType) != ""
  347.             set PC98BoardTypeValue = {PC98, 0, $(!REG_VT_DWORD), $(BoardType)}
  348.             set ParametersValues = >($(ParametersValues), $(PC98BoardTypeValue))
  349.         endif
  350.  
  351.         set DeviceValues     = {}
  352.         set EventLogValues   = { +
  353.                 {EventMessageFile, 0, $(!REG_VT_EXPAND_SZ), $(EventMessageFile) }, +
  354.                 {TypesSupported,   0, $(!REG_VT_DWORD),     $(TypesSupported)   }  +
  355.                 }
  356.  
  357.         shell "registry.inf"  MakeServicesEntry $(ServiceNode)      +
  358.                                                 $(ServicesValues)   +
  359.                                                 $(ParametersValues) +
  360.                                                 $(DeviceValues)     +
  361.                                                 $(EventLogValues)   +
  362.                                                 Device0
  363.  
  364.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  365.             Debug-Output "Couldn't execute MakeServicesEntry in registry.inf"
  366.             goto finish_InstallOption
  367.         endif
  368.  
  369.         ifstr(i) $($R0) != STATUS_SUCCESSFUL
  370.             Debug-Output "MakeServicesEntry failed for video"
  371.             goto finish_InstallOption
  372.         endif
  373.  
  374.         ;
  375.         ;
  376.         ; then disable the previous video entry
  377.         ;
  378.  
  379.         ifstr(i) $(CurrentEntry) != $(MiniportDriver)
  380.             ifstr(i) $(CurrentEntry) != VGA
  381.                 ifstr(i) $(CurrentEntry) != ""
  382.                     shell "registry.inf" ModifyServicesEntry $(CurrentEntry) $(!SERVICE_DISABLED)
  383.  
  384.                     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  385.                         Debug-Output "Couldn't find DisableServicesEntry in registry.inf"
  386.                         goto errorconfig
  387.                     endif
  388.  
  389.                     ifstr(i) $($R0) != STATUS_SUCCESSFUL
  390.                         Debug-Output "DisableServices entry failed"
  391.                     endif
  392.                 endif
  393.             endif
  394.         endif
  395.  
  396.         goto configdone
  397.  
  398. errorconfig = +
  399.         ifstr(i) $(CurrentEntry) != $(MiniportDriver)
  400.             shell "registry.inf" ModifyServicesEntry $(MiniportDriver) $(!SERVICE_DISABLED)
  401.             ifstr(i) $(CurrentEntry) != ""
  402.                 shell "registry.inf" ModifyServicesEntry $(CurrentEntry) $(!SERVICE_SYSTEM_START)
  403.             endif
  404.         endif
  405.         goto finish_InstallOption
  406.  
  407. configdone = +
  408.  
  409.     endif
  410.  
  411.     set Status = STATUS_SUCCESSFUL
  412.  
  413. finish_InstallOption = +
  414.     ForListDo $(DrivesToFree)
  415.         LibraryProcedure STATUS,$(!LIBHANDLE), DeleteNetConnection $($) "TRUE"
  416.     EndForListDo
  417.  
  418.     Return $(Status)
  419.  
  420.  
  421. [Install-AddCopyOption]
  422.  
  423.     set STF_VITAL = ""
  424.     ;
  425.     ; Add the files to the copy list
  426.     ;
  427.     AddSectionKeyFileToCopyList   Files-DisplayMiniportDrivers   +
  428.                                   $(MiniportDriver)              +
  429.                                   $(SrcDir)                      +
  430.                                   $(!STF_WINDOWSSYSPATH)\drivers
  431.  
  432.     ForListDo $(InstalledDisplays)
  433.         AddSectionKeyFileToCopyList   Files-DisplayDLLs          +
  434.                                       $($)                       +
  435.                                       $(SrcDir)                  +
  436.                                       $(!STF_WINDOWSSYSPATH)
  437.  
  438.     EndForListDo
  439.  
  440.     exit
  441.  
  442.  
  443. [Install-DoCopyOption]
  444.  
  445.     ;
  446.     ; Copy files in the copy list
  447.     ;
  448.     CopyFilesInCopyList
  449.     exit
  450.  
  451. ;**************************************************************************
  452. ; PROGRESS GUAGE VARIABLES
  453. ;**************************************************************************
  454.  
  455. [ProgressCopyENG]
  456.     ProCaption   = "Windows NT セットアップ"
  457.     ProCancel    = "キャンセル"
  458.     ProCancelMsg = "Windows NT は正しく組み込まれていません。"+
  459.                    "ファイルのコピーを中止しますか?"
  460.     ProCancelCap = "セットアップ メッセージ"
  461.     ProText1     = "コピー元:"
  462.     ProText2     = "コピー先:"
  463.  
  464. [StringsENG]
  465.     String1 = "ディスプレイ"
  466.     String2 = "Windows NT ディスプレイ ドライバ ファイルへのフル パスを入力してくだ"+
  467.               "さい。セットアップ フロッピー ディスクからファイルを組み込む場合は、"+
  468.               "ドライブ パス (A:\ など) を入力してください。"+
  469.               "入力したら[続行]ボタンをクリックしてください。"
  470.  
  471. ;-----------------------------------------------------------------------
  472. ; SOURCE MEDIA DESCRIPTIONS
  473. ; -------------------------
  474. ; The OEM should list all the diskette labels here.  The source media
  475. ; description is used during copy to prompt the user for a diskette
  476. ; if the source is diskettes.
  477. ;
  478. ; Use 1 = "Diskette 1 Label" , TAGFILE = disk1
  479. ;     2 = "Diskette 2 Label" , TAGFILE = disk2
  480. ;     ...
  481. ;-----------------------------------------------------------------------
  482.  
  483. ;--------------------------------------------------------------------
  484. ; THE SECTIONS BELOW SHOULD BE AUTOMATICALLY GENERATED BY THE EXCEL
  485. ; SPREAD SHEETS
  486. ;--------------------------------------------------------------------
  487.  
  488. [Source Media Descriptions]
  489.     1  = "", TAGFILE = disk1
  490.  
  491. [Files-DisplayDLLs]
  492. PW = 1, PW.DLL, SIZE=156160
  493. PW3D = 1, PW3D.DLL, SIZE=98816
  494. PW9100 = 1, PW9100.dll, SIZE=59392
  495.  
  496. [Files-DisplayMiniportDrivers]
  497. PW = 1, PW.SYS, SIZE=94176
  498. PW3D = 1, PW3D.SYS, SIZE=57568
  499. PW9100 = 1, PW9100.sys, SIZE=15456
  500.