201217963 六、發明說明: 【發明所屬之技術頜域】 [0001] 本發明涉及一種測試系統及方法,尤其關於一種PXE測竦 裝置及其PXE測試方法。 【先前技術】 [0002] 目前,大部分電腦的網路卡都附帶了 PXE (preb〇〇t ex ecute environment,預啟動執行環境)功能。執行謗 PXE功能,電腦可以透過網路從遠端設備下載遠端啟動鏡 像,以實現作業系統的啟動。 [00〇3]在對電腦中的網路卡進行PXE功能測試時,傳統的測試方 法需要另外架設一台與電腦相連接的ρχΕ/f司服器,該PXE 伺服器需要安裝DHCP(Dynamic H〇st c〇nfigurati〇n201217963 VI. Description of the Invention: [Technical Jaw Domain of the Invention] [0001] The present invention relates to a test system and method, and more particularly to a PXE test device and a PXE test method thereof. [Prior Art] [0002] Currently, most computer network cards come with a PXE (preb〇〇t ex ecute environment) function. Executing 谤 PXE function, the computer can download the remote boot image from the remote device through the network to start the operating system. [00〇3] When performing PXE function test on the network card in the computer, the traditional test method needs to set up another ρχΕ/f server connected to the computer. The PXE server needs to install DHCP (Dynamic H). 〇st c〇nfigurati〇n
Protocol,動態主機設置協定)服務,由於安裝了 DHcp 服務,為了不和電腦原屬網路相衝突,需要另外組建— 個網路。然而,架設PXE伺嚴器及組建網路的成本都很高 〇 【發明内容】 剛鑒於以上内容,有必要提供一種PXE測試裝置及利用上述 PXE測試襄置對電腦中的網路卡進行ρχΕ功能測試的方法 ,能夠以低成本實現網路卡的ρχΕ功能測試。 [0005]-種ΡΧΕ測試裝置’該ρχΕ測試裝置包括第一儲存器、第 一儲存器、微控制器、網路介面、網路控制器、電源連 接器、電源控制器、第一指示器及第二指示器,其中: 所述第—儲存器用於儲存微控制器的引導程式、敌入式 作業系、、先、DHCP服務程式、Β〇〇τ服務程式、TFTp服務程 099136965 表單編號 Α01〇ι « , ^ 第 4 頁/共 17 頁 0992064518-0 201217963 式及電腦的遠端啟動鏡像,所述電腦透過網路介面與pXE 錢裂置相連,该電腦包括帶有ΡΧΕ功能的網路卡;所述 第〜儲存器用於提供微控制器的程式運行空間與緩存資 料,所述微控制器連接於第一儲存器與第二儲存器,用 於從第一儲存器載入並執行/啟動所述引導裎式、嵌入式 作業系統、DHCP服務程式、boot服務程式、服務程 弋基於所述DHCP服務程式、boot服務程式、TFTP服務 程式對網路卡的PXE功能進行測試;所述網路介面用於連 接電腦;所述網路控制器連接於微控制器與網路介面, 用於經由網路介面在微控制器與網路卡之間傳送資料; 所述電源連接器用於連接外部電源;所述電源控制器連 接於第一儲存器、第二儲存器、微控制,:器、網路控制器 及電源連接器,用於將經由電源連接器揍入的外部電源 轉換為第一儲存器、第二儲存器、微控制器及網路控制 器所需的直流穩壓電源;所述第一指示器連接於微控制 器,用於顯示微控制器是否供電正常;及所述第二指示 器連接於微控制器’甩於顯示微控制器是否啟動就緒。 [0006]—種利用上述PXE測試裝置對電腦中的網路卡進行ρχΕ功 能測試的方法’該方法包括步驟:將ΡΧΕ測試裴置透過網 路介面與電腦相連;將電源連接器接上外部電源,電源 控制器將該外部電源轉換為微控制器、第二儲存器、第 一儲存器及網路控制器所需的直流穩壓電源;第一指示 器顯示微控制器是否供電正常;若供電正常,微护?制器 從第一儲存器載入引導程式;微控制器透過第二儲存器 執行所述引導程式,根據該引導程式進行硬體初始化並 099136965 表單編號Α0101 第5頁/共17頁 0992064518-0 201217963 從第一儲存器載入嵌入式作業系統、DHCP服務程式、 BOOT服務程式及TFTP服務程式;微控制器透過第二儲存 器啟動所述嵌入式作業系統、DHCP服務程式,BOOT服務 程式及TFTP服務程式;第二指示器顯示微控制器是否啟 動就緒;若啟動就緒,基於所述DHCP服務程式、BOOT服 務程式、TFTP服務程式,微控制器對網路卡的ΡΧΕ功能進 行測試。 [0007] [0008] [0009] 相較於習知技術,本發明提供的ΡΧΕ測試裝置及利用該 ΡΧΕ測試裝置進行網路卡ρχΕ功能測試的方法不需要另外 架設ΡΧΕ伺服器,方法簡單且節約了測試成本。 【實施方式】 參閱圖1所示,係本發明ΡΧΕ測試裝置較佳實施例的應用 環境示意圖。所述ΡΧΕ測試裝置10與電腦u透過網路12 (内部網路或者外部網路)連接。所述電腦丨丨包括一個 f 有PXE (preboot execute environment,預啟動執 行環境)功能的網路卡13。所述ρχΕ功能使得電腦u可以 透過網路(例如網路12)從壤端設備(例如遠端飼服器 )下載遠端啟動鏡像,執行該遠端啟動鏡像以實現電腦 11作業系統的啟動。 參閱圖2所示’係圖1中PXE測試裝置的結構示意圖。所述 PXE測崎置1G包括第—儲存器綱、第二儲存器21〇、 微控制器220、網路介面23〇、網路控制器24〇 '電源連 接器250、電源控制器26〇、第一指示器27〇及第二指示 器 280。 [0010] 099136965 ==存器=讀儲存器(例如快閃儲存器) 第6頁/共17頁 0992064518-0 201217963 [0011] ο [0012] Ο [0013] [0014] [0015] [0016] 099136965 0992064518-0 用於儲存微控制器220的引導程式、嵌入式作業系統(例 如嵌入式Linux作業系統)、DHCP服務程式、BOOT服務 程式、TFTP服務程式與電腦丨丨的遠端啟動鏡像(例如啟 動Dos鏡像)。在本實施例中,所述第一儲存器2〇〇還儲 存電腦11的配置文檔、系統維護工具及測試工具。所述 配置文檔用於對電腦1丨進行系統配置,所述系統維護工 具用於在電腦11出現故障時進行系統維護,所述測試工 具用於測试電腦1 1的硬體性能β 所述第二儲存器210是隨機存取儲存器(例如SDRAM), 用於提供微控制器2 2 〇的程式運行空間與緩存資料。 所述微控制器220連接於第一,儲存器,200與第二儲存器 210 ’用於從第一儲存器200載入並執行/啟動所述引導程 式、嵌入式作業系統、DHCP服務程式、BOOT服務程式、 TFTP服務程式。基於所述DHCP服務程式、BOOT服務程式 、TFTP服務程式,微控制器22〇對網路卡13的!>奵功能進 行測試。在本實施例中,所述微控制器22〇還用於將第一 儲存器2 0 0中的配置文檔、系統維護工具及測試工具經由 網路控制器240與網路介面230映射到電腦11。 所述網路介面230用於連接電腦Π。 所述網路控制器240連接於微控制器220與網路介面230 ’用於經由網路介面230在微控制器220與網路卡13之間 傳送資料。 所述電源連接器250用於連接外部電源。 所述電源控制器260連接於第一儲存器200、第二儲存器 表單編號A0101 第7頁/共17頁 201217963 [0017] [0018] [0019] [0020] [0021] 210、微控制器220、網路控制器240及電源連接器25〇, 用於將由a源連接H 2 5 Q接人的外部電源轉換為第一儲存 器200、第二儲存11210、微控制H22G及網路控制器24〇 所需的直流穩壓電源。 所述第-指示器270連接於微控制器22Q,用於顯示微控 制器220疋否供電正常。在本實施例中所述第—指示器 270是一個指示燈,該指示燈在微控制器22〇供電正常時 點亮。所述第-指示器270還可以是其他的指示設備例 如蜂鳴器’該蜂鳴料以在_彻供電異常時鳴叫 : ... .... v ' 〇 ...... . 所述第二指示H28()連接於微控制器咖,驗顯示微控 制器220是否啟動就緒。在本實施例中,所述第二指示器 280是一個指示燈,該指示燈在微控制器22〇啟動就緒時 點亮。所述第二指示器28G還可以是其他的指示設備,例 如蜂鳴器,該蜂鳴器可以在微控彻物啟動#常時鳴叫 〇 . . :: ..... 參閱圖3所示’係利用圖1中的PXE測試裝置對電腦丨】中的 網路卡13進行PXE功能測試較佳實施例的流程圖。 步驟S300,將PXE測試裝置1〇透過網路介面23〇與電腦^ 相連。 步驟S3(H,將電源連接器25〇接上外部電源,電源控卿 260將該外部電源轉換為第一儲存器2〇〇、第二儲存器 210、微控制器220及網路控制器24〇所需的直流穩壓電 源。 099136965 表單編號A0101 第8頁/共17頁 0992064518-0 201217963 [0022] [0023] [0024] Ο [0025] [0026] [0027] 〇 步驟S302 ’第一指示器270顯示微控制器220是否供電正 常。若微控制器220供電異常,則流程結束。 若微控制器220供電正常’步驟S303,微控制器22〇從第 —儲存器200載入引導程式。 步驟S304,微控制器220透過第二儲存器210執行所述引 導程式’根據該引導程式進行硬體初始化並從第一儲存 器200載入嵌入式作業系統、DHCP服務程式、BOOT服務 程式及TFTP服務程式》 步驟S305,微控制器220透過禁二儲存器21〇啟動所述嵌 入式作業系統、DHCP服務程式、BOOT服務程式及TFTP服 務程式。 步驟S306,第二指示器280顯示微控制器220是否啟動就 緒。若微控制器220啟動異常,則流程結束。 若微控制器220啟動就緒,步驟S307,基於所述DHCP服 .-r" 務程式、BOOT服務程式、TFTP服務程式,微控制器220 對網路卡13的PXE功能進行測試。具體地,基於所述 DHCP服務程式,微控制器220回應網路卡13發送的DHCP Discover資料包而返回DHCP OFFER資料包,以提供ip 位址與啟動伺服器列表;基於所述6001'服務程式,微控 制器220回應網路卡13發送的DHCP REQUREST資料包而 返回包含遠端啟動鏡像檔案名及^邝配置參數的DHCp ACK資料包;基於所述^^服務程式,微控制器22〇回應 網路卡13發送的下載鏡像請求資料包而建立一個基於 MTFTP協定或者TFTP協定的連接,以供電腦11透過該連 099136965 表單編號A0101 第9頁/共17頁 0992064518-0 201217963 接從第—儲存器200下載遠端啟動鏡像。網路卡13在下載 凡成後執行所述遠端啟動鏡像,以完成電腦11的作業系 統啟動。在本實施例中’測試結果從電腦n上進行觀測 。右電腦11作業系統啟動正常,則網路卡13的PXE功能正 常。 [0028] [0029] 右網路卡13的PXE功能正常,步驟S308,微控制器220將 第—儲存器200中的配置文檔、系統維護工具及測試工具 經由網路控制器240與網路介面230映射到電腦11。 表丁、上所述,本發明符合發明專利要件麦依法提出專利 日^^,以上㈣者僅為本發^_實施例,本發 月之範圍並不以上述實施例為限,舉 人Ia 平凡熟悉本案技藝之 麦依本發明之精神所作之等效修 蓋於以下申請專利範圍内。 _或變化,皆應涵 【圖式簡單說明】 [0030] 圖1係本發明PXE測試裝 置較佳實施例環境示意圖 [0031] [0032] 圖2係圖1中PXE測試裝置的結構示意圖。 圖3係利用圖1中的Pxe測試裝置對電 ΡΧΕ功能測絲佳實施例的流程圖。的網路卡進行 【主要元件符號說明】 [0033] ΡΧΕ測試裝置:10 [_]電腦:11 [0035]網路:1 2 099136965 表單編號Α0101 第10頁/共17頁 0992064518-0 201217963 [0036] 網路卡:13 [0037] 第一儲存器:200 [0038] 第二儲存器:210 [0039] 微控制器:220 [0040] 網路介面:230 [0041] 網路控制器:240 [0042] 電源連接器:250 〇 闺 電源控制器:260 [0044] 第一指示器:270 [0045] 第二指示器:280 099136965 表單編號A0101 第11頁/共17頁 0992064518-0Protocol, Dynamic Host Setup Protocol service, because the DHcp service is installed, in order to not conflict with the original network of the computer, another network needs to be set up. However, the cost of setting up a PXE server and building a network is very high. [Inventive content] In view of the above, it is necessary to provide a PXE test device and perform the function of the network card in the computer by using the above PXE test device. The test method can realize the function test of the network card at low cost. [0005] - a test device of the type "the first memory, a first memory, a microcontroller, a network interface, a network controller, a power connector, a power controller, a first indicator and a second indicator, wherein: the first storage is used to store a boot program of the microcontroller, an enemy operating system, a first, a DHCP service program, a service program, a TFTp service program 099136965, a form number Α01〇 ι « , ^ Page 4 of 17 0992064518-0 201217963 and the remote start image of the computer, the computer is connected to the pXE money through the network interface, the computer includes a network card with a ΡΧΕ function; The first storage is used to provide a program running space and cache data of the microcontroller, and the microcontroller is connected to the first storage and the second storage for loading and executing/starting from the first storage. The boot mode, the embedded operating system, the DHCP service program, the boot service program, and the service program test the PXE function of the network card based on the DHCP service program, the boot service program, and the TFTP service program; The network interface is used for connecting to a computer; the network controller is connected to the microcontroller and the network interface for transmitting data between the microcontroller and the network card via the network interface; Connecting an external power source; the power controller is connected to the first storage, the second storage, the micro control, the:, the network controller, and the power connector for converting the external power input through the power connector a DC regulated power supply required for the first storage, the second storage, the microcontroller, and the network controller; the first indicator is coupled to the microcontroller to indicate whether the microcontroller is powered normally; and The second indicator is coupled to the microcontroller' to indicate whether the microcontroller is ready for startup. [0006] A method for performing a ρχΕ function test on a network card in a computer by using the above PXE test device. The method includes the steps of: connecting a ΡΧΕ test device to a computer through a network interface; and connecting the power connector to an external power source The power controller converts the external power source into a DC regulated power supply required by the microcontroller, the second storage, the first storage, and the network controller; the first indicator indicates whether the microcontroller is powered normally; Normally, the micro-protector loads the boot program from the first storage; the microcontroller executes the boot program through the second storage, and performs hardware initialization according to the boot program and 099136965 Form No. 1010101 Page 5 of 17 Page 0992064518-0 201217963 Load embedded operating system, DHCP service program, BOOT service program and TFTP service program from the first storage; the microcontroller starts the embedded operating system, DHCP service program through the second storage, BOOT a service program and a TFTP service program; a second indicator indicating whether the microcontroller is ready to be ready; if the boot is ready, based on the DHCP service program BOOT service program, TFTP service program, microcontroller ΡΧΕ function network card to carry out the test. [0008] [0008] Compared with the prior art, the ΡΧΕ test device provided by the present invention and the method for performing the network card χΕ function test by using the ΡΧΕ test device do not need to be additionally set up with a server, and the method is simple and economical. The cost of testing. [Embodiment] Referring to Figure 1, there is shown a schematic diagram of an application environment of a preferred embodiment of the flaw test apparatus of the present invention. The UI test device 10 is connected to the computer u via a network 12 (internal network or external network). The computer 丨丨 includes a network card 13 having a PXE (preboot execute environment) function. The χΕ function enables the computer u to download a remote boot image from a soil end device (e.g., a remote feeder) via a network (e.g., network 12), and execute the remote boot image to enable booting of the computer 11 operating system. Referring to Figure 2, the structure of the PXE test apparatus of Figure 1 is shown. The PXE Senses 1G includes a first storage unit, a second storage unit 21, a microcontroller 220, a network interface 23, a network controller 24 〇 'power connector 250, a power controller 26 〇, The first indicator 27 and the second indicator 280. [0010] 099136965 == Storing = Read Storage (eg, Flash Storage) Page 6 of 17 0992064518-0 201217963 [0011] [ [0012] [0014] [0016] [0016] 099136965 0992064518-0 is used to store the boot program of the microcontroller 220, the embedded operating system (such as the embedded Linux operating system), the DHCP service program, the BOOT service program, the TFTP service program and the remote boot image of the computer (for example Start the Dos image). In this embodiment, the first storage unit 2 stores a configuration file of the computer 11, a system maintenance tool, and a test tool. The configuration document is used for system configuration of a computer maintenance tool for performing system maintenance when a failure occurs in the computer 11 for testing the hardware performance of the computer 11 The second storage 210 is a random access storage (such as SDRAM) for providing program running space and cache data of the microcontroller 2 2 . The microcontroller 220 is coupled to the first, storage, 200 and second storage 210' for loading and executing/starting the boot program, the embedded operating system, the DHCP service program, and the booting from the first storage 200. BOOT service program, TFTP service program. Based on the DHCP service program, the BOOT service program, and the TFTP service program, the microcontroller 22 tests the !> function of the network card 13. In this embodiment, the microcontroller 22 is further configured to map the configuration file, the system maintenance tool, and the test tool in the first storage device 2000 to the computer 11 via the network controller 240 and the network interface 230. . The network interface 230 is used to connect to a computer. The network controller 240 is coupled to the microcontroller 220 and the network interface 230' for communicating data between the microcontroller 220 and the network card 13 via the network interface 230. The power connector 250 is used to connect an external power source. The power controller 260 is connected to the first memory 200, the second memory form number A0101, page 7 / 17 pages, 201217963 [0018] [0020] [0021] 210, the microcontroller 220 The network controller 240 and the power connector 25 are configured to convert the external power source connected by the source connection H 2 5 Q into the first storage 200, the second storage 11210, the micro control H22G, and the network controller 24 〇The required DC regulated power supply. The first indicator 270 is connected to the microcontroller 22Q for indicating whether the micro controller 220 is powered normally. In the present embodiment, the first indicator 270 is an indicator light that illuminates when the microcontroller 22 is powered normally. The first indicator 270 may also be another indicating device such as a buzzer 'the buzzer to scream when the power supply is abnormal: ..... v ' 〇. The second indication H28() is connected to the microcontroller, and it is checked whether the microcontroller 220 is ready to be started. In the present embodiment, the second indicator 280 is an indicator light that illuminates when the microcontroller 22 is ready to start. The second indicator 28G may also be another pointing device, such as a buzzer, which can be called during the micro-control start # 常. . :: ..... A flow chart of a preferred embodiment of the PXE function test of the network card 13 in the computer using the PXE test apparatus of FIG. In step S300, the PXE test device is connected to the computer through the network interface 23A. Step S3 (H, the power connector 25 is connected to the external power source, and the power control 260 converts the external power source into the first storage device 2, the second storage device 210, the microcontroller 220, and the network controller 24 〇Required DC regulated power supply 099136965 Form No. A0101 Page 8 of 17 0992064518-0 201217963 [0023] [0024] [0025] [0026] [0027] Step S302 'First indication The controller 270 displays whether the microcontroller 220 is powered normally. If the microcontroller 220 is powered abnormally, the flow ends. If the microcontroller 220 is powered normally 'Step S303, the microcontroller 22 loads the boot program from the first storage 200. Step S304, the microcontroller 220 executes the boot program through the second storage 210 to perform hardware initialization according to the boot program and load the embedded operating system, the DHCP service program, the BOOT service program, and the TFTP from the first storage 200. In step S305, the microcontroller 220 activates the embedded operating system, the DHCP service program, the BOOT service program and the TFTP service program through the banned storage 21. In step S306, the second indicator 280 displays the micro control. Whether the device 220 is ready to start. If the microcontroller 220 starts abnormality, the process ends. If the microcontroller 220 is ready to start, step S307, based on the DHCP service.-r" program, BOOT service program, TFTP service program, micro The controller 220 tests the PXE function of the network card 13. Specifically, based on the DHCP service program, the microcontroller 220 returns a DHCP OFFER packet in response to the DHCP Discover packet sent by the network card 13 to provide an ip bit. Addressing and starting the server list; based on the 6001' service program, the microcontroller 220 returns a DHCp ACK packet containing the remote boot image file name and the configuration parameter in response to the DHCP REQUREST data packet sent by the network card 13; Based on the ^^ service program, the microcontroller 22 responds to the download image request packet sent by the network card 13 to establish a connection based on the MTFTP protocol or the TFTP protocol for the computer 11 to pass through the serial number 099136965. Page 17 of 0992064518-0 201217963 The remote boot image is downloaded from the first storage unit 200. The network card 13 executes the remote boot image after downloading the file. The operation of the computer 11 is completed. In the present embodiment, the test result is observed from the computer n. The right computer 11 operating system is started normally, and the PXE function of the network card 13 is normal. [0028] [0029] Right network The PXE function of the card 13 is normal. In step S308, the microcontroller 220 maps the configuration file, the system maintenance tool and the test tool in the first storage unit 200 to the computer 11 via the network controller 240 and the network interface 230. In the above description, the present invention complies with the invention patent requirement, and the patent date is ^^, and the above (4) is only the embodiment of the present invention. The scope of the present month is not limited to the above embodiment, and the person Ia is ordinary. Equivalent to the spirit of the present invention, which is familiar with the skill of the present invention, is within the scope of the following claims. BRIEF DESCRIPTION OF THE DRAWINGS [0030] FIG. 2 is a schematic view showing the structure of a PXE test apparatus of FIG. 1 [0032] FIG. Fig. 3 is a flow chart showing an embodiment of the electric function measuring wire using the Pxe test apparatus of Fig. 1. Network card [Main component symbol description] [0033] ΡΧΕ Test device: 10 [_] Computer: 11 [0035] Network: 1 2 099136965 Form number Α 0101 Page 10 / Total 17 page 0992064518-0 201217963 [0036 Network card: 13 [0037] First memory: 200 [0038] Second memory: 210 [0039] Microcontroller: 220 [0040] Network interface: 230 [0041] Network controller: 240 [ 0042] Power connector: 250 〇闺 Power controller: 260 [0044] First indicator: 270 [0045] Second indicator: 280 099136965 Form number A0101 Page 11 of 17 0992064518-0