TW201333690A - Method and system for testing LED based on BMC automatically - Google Patents

Method and system for testing LED based on BMC automatically Download PDF

Info

Publication number
TW201333690A
TW201333690A TW101105375A TW101105375A TW201333690A TW 201333690 A TW201333690 A TW 201333690A TW 101105375 A TW101105375 A TW 101105375A TW 101105375 A TW101105375 A TW 101105375A TW 201333690 A TW201333690 A TW 201333690A
Authority
TW
Taiwan
Prior art keywords
led
event
bmc
array element
management table
Prior art date
Application number
TW101105375A
Other languages
Chinese (zh)
Inventor
jia-qing Huang
Original Assignee
Hon Hai Prec Ind Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hon Hai Prec Ind Co Ltd filed Critical Hon Hai Prec Ind Co Ltd
Publication of TW201333690A publication Critical patent/TW201333690A/en

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The present invention provides a method and system for testing the LED based on BMC automatically. The method includes: reading all information of LED management form from database; simulating an event of the form in accordance with a default order; acquiring the current state of the LED after a preset time interval; inquiring the ideal lighting state of the LED in the form; determining whether the current state of the LED is the same with the ideal lighting state of the LED; if it isn't, giving a prompt that test fails; if it is, determining whether all the events are simulated; if they aren't, simulating the next event of the form in accordance with a default order; if they are, giving a prompt of all testing information.

Description

基於BMC的LED自動化測試方法及系統LED automatic test method and system based on BMC

本發明涉及一種基於BMC的LED自動化測試方法及系統,尤其涉及一種伺服器中的基於BMC的LED自動化測試方法及系統。The invention relates to a BMC-based LED automatic test method and system, in particular to a BMC-based LED automatic test method and system in a server.

基板管理控制器(Baseboard Management Controller,BMC)作為伺服器的管理者,負責監控伺服器的運行狀況。當伺服器發生各種不良狀況(例如風扇轉速過低導致散熱不足、電壓過高等),這些不良狀況在下文中將稱為事件,BMC會記錄這些事件。同時,為了引起伺服器管理者的注意,通常BMC還會根據不同的事件點亮對應的發光二極體(Light Emitting Diode,LED)。目前BMC通常根據事件的輕重緩急來決定LED亮燈情況,LED亮燈情況由顏色和頻率組成。例如嚴重事件為黃色LED閃爍,不嚴重事件為黃色LED常亮。The Baseboard Management Controller (BMC) acts as the administrator of the server and monitors the health of the server. When the server has various adverse conditions (such as low fan speed resulting in insufficient heat dissipation, high voltage, etc.), these undesirable conditions will be referred to as events in the following, and the BMC will record these events. At the same time, in order to attract the attention of the server manager, the BMC usually lights up the corresponding Light Emitting Diode (LED) according to different events. At present, BMC usually determines the LED lighting condition according to the priority of the event. The LED lighting condition is composed of color and frequency. For example, the serious event is a yellow LED flashing, and the non-serious event is that the yellow LED is always on.

在工廠的生產過程中,需要測試伺服器的不同事件所對應的LED亮燈情況是否正確,此時均採用人工測試。由於導致不良狀況發生的事件繁多,並且LED的顏色和頻率多種多樣,兩者組合起來給人工測試帶來很大的困難,浪費時間並且容易有所遺漏。因此,有必要提供一種基於BMC的LED自動化測試方法,能夠全面且快速地進行測試。In the production process of the factory, it is necessary to test whether the LED lighting conditions corresponding to different events of the server are correct, and manual testing is used at this time. Due to the numerous events that lead to bad conditions, and the variety of LED colors and frequencies, the combination of the two brings great difficulties to manual testing, wasting time and is easy to miss. Therefore, it is necessary to provide a BMC-based LED automated test method that can be tested comprehensively and quickly.

鑒於以上內容,有必要提供一種基於BMC的LED自動化測試方法及系統,以實現伺服器的不同事件所對應的LED亮燈情況的測試。In view of the above, it is necessary to provide a BMC-based LED automatic test method and system to achieve the LED lighting condition corresponding to different events of the server.

所述基於BMC的LED自動化測試方法,該方法包括以下步驟:從資料庫中讀取LED管理表格中的所有資料;類比步驟一:按照一個預設順序類比LED管理表格中的一個事件,在類比過程中BMC控制LED的顏色和頻率;獲取步驟:在一個預設的時間間隔後獲取LED的當前狀態;查詢步驟:在LED管理表格中查詢理想的LED亮燈情況;判斷步驟一:判斷LED的當前狀態與查詢到的LED亮燈情況是否相同,當LED的當前狀態與查詢到的LED亮燈情況相同時,執行判斷步驟二,否則,提示該事件對應的LED亮燈情況測試失敗;判斷步驟二:判斷所有事件是否均已類比完成,當還有事件未類比時,執行類比步驟二,否則,給出所有事件對應的LED亮燈情況的測試資訊提示;類比步驟二:按照預設順序類比LED管理表格中的下一個事件,並返回執行獲取步驟。The BMC-based LED automated test method includes the following steps: reading all the data in the LED management table from the database; analogy step 1: analogizing an event in the LED management table according to a preset order, in analogy During the process, the BMC controls the color and frequency of the LED; the obtaining step: obtaining the current state of the LED after a preset time interval; the query step: querying the ideal LED lighting condition in the LED management table; determining step 1: determining the LED The current state is the same as the LED lighting condition that is queried. When the current state of the LED is the same as the illuminating LED, the judgment step 2 is performed. Otherwise, the LED lighting condition corresponding to the event is failed. Second: judge whether all events have been analogously completed. When there are still events that are not analogous, perform analogy step two. Otherwise, give test information prompts for LED lighting conditions corresponding to all events; analog step 2: analogy according to preset order The LED manages the next event in the form and returns to the execution acquisition step.

所述基於BMC的LED自動化測試系統,該系統包括:讀取模組,用於從資料庫中讀取LED管理表格中的所有資料;類比模組,用於按照一個預設順序類比LED管理表格中的一個事件,在類比過程中BMC控制LED的顏色和頻率;獲取模組,用於在一個預設的時間間隔後獲取LED的當前狀態;查詢模組,用於在LED管理表格中查詢理想的LED亮燈情況;判斷模組,用於判斷LED的當前狀態與查詢到的LED亮燈情況是否相同;提示模組,用於當LED的當前狀態與查詢到的LED亮燈情況不同時,提示該事件對應的LED亮燈情況測試失敗;所述判斷模組,還用於當LED的當前狀態與查詢到的LED亮燈情況相同時,判斷所有事件是否均已類比完成;所述類比模組,還用於當還有事件未類比時,按照預設順序類比LED管理表格中的下一個事件;所述提示模組,還用於當所有事件均已類比時,給出所有事件對應的LED亮燈情況的測試資訊提示。The BMC-based LED automated test system includes: a read module for reading all data in the LED management table from the database; an analog module for analogizing the LED management table according to a preset order In an event, the BMC controls the color and frequency of the LED during the analogy process; the acquisition module is used to obtain the current state of the LED after a preset time interval; the query module is used to query the ideal in the LED management table. The LED lighting condition; the determining module is configured to determine whether the current state of the LED is the same as the queried LED lighting condition; and the prompting module is configured to: when the current state of the LED is different from the queried LED lighting condition, Prompting that the LED lighting condition corresponding to the event fails; the determining module is further configured to determine whether all events have been analogized when the current state of the LED is the same as the queried LED lighting condition; The group is also used to manage the next event in the table according to the preset order when the event is not analogous; the prompt module is also used to give all the events when all the events have been analogized. LED lighting member corresponding to the case where the test information tips.

相較於習知技術,本發明所述之基於BMC的LED自動化測試方法及系統,通過該方法能夠測試伺服器的不同事件所對應的LED亮燈情況是否正確,提升測試的覆蓋率以及產品的品質。Compared with the prior art, the BMC-based LED automatic test method and system of the present invention can test whether the LED lighting conditions corresponding to different events of the server are correct, improve the test coverage and the product. quality.

如圖1所示,係為本發明基於BMC的LED自動化測試系統較佳實施例之架構圖。FIG. 1 is an architectural diagram of a preferred embodiment of a BMC-based LED automated test system of the present invention.

基於BMC的LED自動化測試系統10運行於伺服器1中,所述伺服器1中還包括存儲設備20、BMC30。所述存儲設備20既可為伺服器1內置的硬碟、記憶體等存儲介質,亦可為外接於伺服器1的硬碟、快閃記憶體等存儲介質。本較佳實施例以存儲設備20為伺服器1內置的存儲介質為例進行介紹。The BMC-based LED automated test system 10 runs in the server 1, and the server 1 further includes a storage device 20 and a BMC 30. The storage device 20 may be a storage medium such as a hard disk or a memory built in the server 1 or a storage medium such as a hard disk or a flash memory externally connected to the server 1. The preferred embodiment of the present invention is described by taking the storage device 20 as a storage medium built in the server 1.

所述存儲設備20中包括一個資料庫200,該資料庫200中存儲有一個LED管理表格,該LED管理表格用於描述事件和LED亮燈情況的對應關係。所述事件為伺服器1發生的各種不良狀況,例如風扇轉速過低導致散熱不足、前面板溫度過高等。每個事件均對應有一個感測器在監測,每個感測器可監測一個或多個事件。所述LED管理表格中包括多個參數資訊,所述參數資訊包括:優先順序(priority)、顏色(color)、頻率(frequency)、感測器記憶體(sensor owner)、感測器識別碼(sensor number)、事件原因(offset)、類型(mask)及測試標誌等。所述LED管理表格的每列均為一個參數資訊,所述LED管理表格的每行均表示一個事件,每行的內容均反映一個事件的資訊及該事件對應的LED亮燈情況。該LED管理表格根據伺服器1的配置不同,其內容也相應地不同。如圖4所示,係為本發明中LED管理表格的一個示例圖。The storage device 20 includes a database 200, and the database 200 stores an LED management table for describing the correspondence between the event and the LED lighting condition. The event is a variety of undesirable conditions that occur in the server 1, such as a low fan speed resulting in insufficient heat dissipation, a high front panel temperature, and the like. Each event corresponds to a sensor being monitored, and each sensor can monitor one or more events. The LED management table includes a plurality of parameter information, including: priority, color, frequency, sensor owner, sensor identifier ( Sensor number), event reason (offset), type (mask) and test flags. Each column of the LED management table is a parameter information, and each row of the LED management table represents an event, and the content of each row reflects the information of one event and the LED lighting condition corresponding to the event. The LED management table differs depending on the configuration of the server 1, and its contents are also different. As shown in FIG. 4, it is an exemplary diagram of the LED management table in the present invention.

所述優先順序用於表徵事件的優先順序,從0開始(0表示伺服器1正常,即優先順序為0的事件為伺服器1正常的事件),優先順序的數值越大,則事件也越緊急。所述顏色與頻率用於描述LED的顏色與頻率。所述感測器記憶體用於記錄感測器的變化,可為BMC30或基本輸入輸出系統(Basic Input Output System,BIOS)或作業系統等。所述感測器標識碼用於定位監測該事件的感測器。所述事件原因用於表明事件發生的原因,如電壓過高還是電壓過低等。所述類型用於標誌事件的方向,如警報(assert)還是解除警報。所述測試標誌用於標識事件是否已完成測試,0表示該事件為未測試狀態,1表示該事件為已測試狀態。The priority order is used to represent the priority order of the event, starting from 0 (0 means that the server 1 is normal, that is, the event with the priority order of 0 is the normal event of the server 1), and the larger the priority value, the more the event urgent. The color and frequency are used to describe the color and frequency of the LED. The sensor memory is used to record changes of the sensor, and may be a BMC 30 or a Basic Input Output System (BIOS) or an operating system. The sensor identification code is used to locate a sensor that monitors the event. The cause of the event is used to indicate the cause of the event, such as excessive voltage or low voltage. The type is used to flag the direction of the event, such as an alert or an alert. The test flag is used to identify whether the event has completed the test, 0 indicates that the event is an untested state, and 1 indicates that the event is a tested state.

所述LED管理表格中的每個優先順序下可包括多個事件,在同一優先順序下的事件的顏色和頻率相同。每個類型為警報的事件,在同一優先順序下均會對應有一個類型為解除警報的事件。所述類型為警報的事件對應伺服器1的不良狀況,所述類型為解除警報的事件將類型為警報的事件所對應的伺服器1的不良狀況恢復正常。如圖4所示,優先順序為0表示伺服器1正常,LED亮燈情況為綠色常亮,其他的參數資訊均為空值;優先順序為1的事件有四個,LED50的顏色、頻率均為綠色、1Hz,優先順序為1的每個類型為警報的事件,均對應有一個優先順序為1的類型為解除警報的事件。Each of the priority orders in the LED management table may include a plurality of events, and the events and colors in the same priority order have the same color and frequency. Each event of type alert will have an event of the type that is de-alarmed in the same priority order. The event of the type of alarm corresponds to the fault condition of the server 1, and the event of the type of canceling the alarm restores the fault condition of the server 1 corresponding to the event of the type of the alarm to normal. As shown in FIG. 4, the priority order is 0, indicating that the server 1 is normal, the LED is lit, the green light is always on, and the other parameter information is null; the priority order is one, and the color and frequency of the LED 50 are both For each type of alarm that is green, 1 Hz, and priority order is 1, there is an event with the priority order of 1 being the alarm.

需要說明的是,當多個類型為警報的事件接連發生時,伺服器1中可能同時存在多個事件,此時,LED亮燈情況顯示的是優先順序最高的事件對應的LED50的顏色和頻率。如圖4中,當參數資訊為“冗餘丟失、警報”的事件發生後,再接連發生參數資訊為“超過嚴重閾值、警報”的事件時,此時LED亮燈情況應為參數資訊為“超過嚴重閾值、警報”的事件所對應的顏色和頻率:黃色、1Hz。It should be noted that when multiple types of events with alarms occur one after another, there may be multiple events in the server 1. At this time, the LED lighting condition displays the color and frequency of the LED 50 corresponding to the event with the highest priority. . As shown in Figure 4, when the parameter information is "redundant loss, alarm" occurs, and then the parameter information is "exceeding the critical threshold, alarm" event, the LED lighting should be parameter information as " The color and frequency corresponding to the event that exceeds the critical threshold, alarm: yellow, 1 Hz.

所述伺服器1還與顯示設備40、LED50連接。所述顯示設備40用於進行測試結果的輸出顯示。所述顯示設備40既可是外接於伺服器1的顯示器,也可以是伺服器1的顯示螢幕,本較佳實施例以顯示設備40是外接於伺服器1的顯示器為例進行介紹。所述BMC30通過多條匯流排擴展器(General Purpose Input Output,GPIO)與LED50連接(圖中畫出三條)。每條GPIO對應一種顏色,所述BMC30通過相應的GPIO發送控制信號來實現對LED50的頻率的控制。The server 1 is also connected to the display device 40 and the LED 50. The display device 40 is configured to perform an output display of test results. The display device 40 can be either a display externally connected to the server 1 or a display screen of the server 1. The preferred embodiment of the present invention is described by taking the display device 40 as a display externally connected to the server 1. The BMC 30 is connected to the LED 50 through a plurality of General Purpose Input Outputs (GPIOs) (three are drawn in the figure). Each GPIO corresponds to one color, and the BMC 30 controls the frequency of the LED 50 by transmitting a control signal through the corresponding GPIO.

如圖2所示,係為本發明基於BMC的LED自動化測試系統較佳實施例之功能模組圖。As shown in FIG. 2, it is a functional module diagram of a preferred embodiment of the BMC-based LED automated test system of the present invention.

所述基於BMC的LED自動化測試系統10包括讀取模組100、類比模組101、獲取模組102、查詢模組103、判斷模組104及提示模組105。各模組的功能將結合圖3之流程圖進行詳細介紹。The BMC-based LED automated test system 10 includes a read module 100, an analog module 101, an acquisition module 102, an inquiry module 103, a determination module 104, and a prompt module 105. The function of each module will be described in detail in conjunction with the flowchart of FIG.

如圖3所示,係為本發明基於BMC的LED自動化測試方法較佳實施例之流程圖。FIG. 3 is a flow chart of a preferred embodiment of the BMC-based LED automated test method of the present invention.

步驟S10,所述讀取模組100從資料庫200中讀取LED管理表格中的所有資料。In step S10, the reading module 100 reads all the materials in the LED management table from the database 200.

在該步驟中由類比模組101創建一個一維的優先權整型陣列。該優先權陣列中的陣列元素的下標值按從小到大的順序與LED管理表格中的優先順序一一對應,每個事件均對應一個陣列元素。需要說明的是,每個陣列元素的下標值均對應LED管理表格中的一個優先順序,同一優先順序下可能有多個事件,此時,所述多個事件對應同一個陣列元素。例如優先權陣列priority【N+1】,其中N為LED管理表格中優先順序的最大值,假設N為3,則優先權陣列中有四個陣列元素,分別為priority【0】、priority【1】、priority【2】、priority【3】,則priority【0】、priority【1】、priority【2】、priority【3】分別對應優先順序為0、優先順序為1、優先順序為2、優先順序為3的事件。類比模組101將優先權陣列中的第一個陣列元素(即priority【0】)的初始值置為1,其餘的每個陣列元素的初始值均置為0。A one-dimensional priority integer array is created by the analog module 101 in this step. The index values of the array elements in the priority array are in one-to-one correspondence with the priority order in the LED management table in ascending order, and each event corresponds to one array element. It should be noted that the subscript values of each array element correspond to a priority order in the LED management table, and there may be multiple events in the same priority order. In this case, the multiple events correspond to the same array element. For example, the priority array priority [N+1], where N is the maximum value of the priority order in the LED management table. If N is 3, there are four array elements in the priority array, respectively, priority [0], priority [1] 】, priority [2], priority [3], then priority [0], priority [1], priority [2], priority [3] respectively correspond to the priority order is 0, the priority order is 1, the priority order is 2, priority An event with a sequence of 3. The analog module 101 sets the initial value of the first array element (i.e., priority [0]) in the priority array to 1, and the initial value of each of the remaining array elements is set to zero.

步驟S12,所述類比模組101按照一個預設順序類比LED管理表格中的一個事件。In step S12, the analog module 101 manages an event in the table according to a preset order analog LED.

所述預設順序由用戶進行隨機設置,但應保證類型為解除警報的事件應在對應的類型為警報的事件之後執行,並且LED管理表格中的所有事件均被執行。如圖4所示,所述預設順序可為:將LED管理表格中的事件按照從上往下的順序依次執行,或其他的順序。The preset order is randomly set by the user, but it should be ensured that the event of the type de-alarm should be executed after the corresponding event of the type of alarm, and all events in the LED management table are executed. As shown in FIG. 4, the preset sequence may be: sequentially executing events in the LED management table in order from top to bottom, or other order.

需要說明的是,在沒有本發明之前,原始的工作方式為:當伺服器1有事件發生時,監測該事件的感測器偵測到該事件時該感測器會改變自身的值。在本發明中,採用軟體的方法來類比改變感測器的值的過程。當類比模組101類比LED管理表格中的一個事件時,類比的是伺服器1發生的不良狀況。所述類比過程如下:類比模組101利用感測器事件設置命令(set sensor reading and event command,是IPMI規範規定的一個命令)來設定監測該事件的感測器的值,所述感測器事件設置命令根據參數資訊:感測器標識碼、事件原因和類型,來決定感測器的值。之後,伺服器1根據該感測器的值進行判斷(如溫度是否正常、風扇轉速是否正常等)而得到一個判斷結果;BMC30根據該判斷結果得到該事件對應的優先順序,並確定伺服器1中存在的優先順序最高的事件,並得到該優先順序最高的事件對應的LED50的顏色和頻率,並根據該LED50的顏色和頻率確定控制信號,並將該控制信號發送至LED50。It should be noted that, before the invention is invented, the original working mode is that when the server 1 has an event, the sensor that monitors the event detects the event and the sensor changes its value. In the present invention, a software method is used to analogously change the value of the sensor. When the analog module 101 is compared to an event in the LED management table, the analogy is the bad condition that occurs in the server 1. The analogy process is as follows: the analog module 101 uses a set sensor reading and event command (a command specified by the IPMI specification) to set a value of a sensor that monitors the event, the sensor The event setup command determines the value of the sensor based on the parameter information: the sensor identification code, the cause and type of the event. After that, the server 1 determines whether the temperature is normal according to the value of the sensor (such as whether the temperature is normal, whether the fan speed is normal, etc.) to obtain a determination result; the BMC 30 obtains the priority order corresponding to the event according to the determination result, and determines the server 1 The highest priority event exists in the middle, and the color and frequency of the LED 50 corresponding to the event with the highest priority is obtained, and the control signal is determined according to the color and frequency of the LED 50, and the control signal is sent to the LED 50.

步驟S14,所述獲取模組102在一個預設的時間間隔後獲取LED50的當前狀態。所述預設的時間間隔由伺服器1的性能決定。In step S14, the acquisition module 102 acquires the current state of the LED 50 after a preset time interval. The preset time interval is determined by the performance of the server 1.

獲取模組102通過偵測BMC30來獲取LED50的當前狀態。當類比模組101類比一個事件後,獲取模組102讀取BMC30通過GPIO發送至LED50的控制信號,並根據該控制信號確定LED50的當前狀態。需要說明的是,同時獲取模組102將所述類比的事件的測試標誌更新為已測試狀態,即將測試標誌由0變為1。The acquisition module 102 acquires the current state of the LED 50 by detecting the BMC 30. When the analog module 101 is analogous to an event, the acquisition module 102 reads the control signal sent by the BMC 30 to the LED 50 through the GPIO, and determines the current state of the LED 50 according to the control signal. It should be noted that the acquisition module 102 updates the test flag of the analog event to the tested state, that is, the test flag is changed from 0 to 1.

當類比模組101該次類比的事件(假設該事件在LED管理表格中對應的priority為m)類型為警報時,獲取模組102將該事件對應的陣列元素的初始值(即priority【m】)做加1操作,當類比模組101該次類比的事件類型為解除警報時,則獲取模組102將該事件對應的陣列元素的初始值(即priority【m】)做減1操作。When the analogy module 101 is analogous to the event (assuming that the event corresponds to a priority of m in the LED management table), the acquisition module 102 initializes the array element corresponding to the event (ie, priority [m] The operation of adding 1 is performed. When the event type of the analogy module 101 is the release alarm, the acquisition module 102 decrements the initial value of the array element corresponding to the event (ie, priority [m]).

步驟S16,所述查詢模組103在LED管理表格中查詢理想的LED亮燈情況。In step S16, the query module 103 queries the LED management table for an ideal LED lighting condition.

查詢模組103按照陣列元素的下標值從大到小地讀取優先權陣列中陣列元素的初始值,直至讀到陣列元素的初始值為非0,並獲得該非0陣列元素的下標值。此時,查詢模組103在LED管理表格中查詢優先順序為該非0陣列元素的下標值(如優先順序為3)的事件所對應的顏色和頻率(如為黃色、0),該顏色和頻率即為理想的LED亮燈情況。The query module 103 reads the initial values of the array elements in the priority array from large to small according to the index value of the array elements until the initial value of the read array elements is non-zero, and obtains the subscript value of the non-zero array elements. . At this time, the query module 103 queries, in the LED management table, the color and frequency (such as yellow, 0) corresponding to the event whose priority order is the subscript value of the non-zero array element (eg, the priority order is 3), and the color and The frequency is the ideal LED lighting condition.

步驟S18,所述判斷模組104判斷LED50的當前狀態與查詢到的LED亮燈情況是否相同。當LED50的當前狀態與查詢到的LED亮燈情況不同時,執行步驟S20,否則,執行步驟S22。In step S18, the determining module 104 determines whether the current state of the LED 50 is the same as the queried LED lighting condition. When the current state of the LED 50 is different from the queried LED lighting condition, step S20 is performed; otherwise, step S22 is performed.

步驟S20,所述提示模組105提示該事件對應的LED亮燈情況測試失敗。In step S20, the prompting module 105 prompts that the LED lighting condition corresponding to the event fails.

所述事件對應的LED亮燈情況測試失敗的資訊提示包括:查詢到的LED亮燈情況、LED50的當前狀態、該事件對應的感測器、測試失敗的提示等。The information prompts of the LED lighting condition test failure corresponding to the event include: the queried LED lighting condition, the current state of the LED 50, the sensor corresponding to the event, and the prompt of the test failure.

步驟S22,所述判斷模組104判斷所有事件是否均已類比完成。當還有事件沒有類比時,執行步驟S24,否則,執行步驟S26。In step S22, the determining module 104 determines whether all events have been analogized. When there is still no analogy of the event, step S24 is performed, otherwise, step S26 is performed.

判斷模組104判斷是否LED管理表格中所有事件的測試標誌均為已測試狀態。當所有事件的測試標誌均為已測試狀態時,判斷模組104判定所有事件均類比完成,否則,判斷模組104判定還有事件沒有類比。The determining module 104 determines whether the test flags of all events in the LED management table are in a tested state. When all the test flags of the event are in the tested state, the determining module 104 determines that all events are analogously completed. Otherwise, the determining module 104 determines that there are still no analogies.

步驟S24,所述類比模組101按照預設順序類比LED管理表格中的下一個事件,並返回執行步驟S14。In step S24, the analog module 101 compares the next event in the table with the LEDs in a preset order, and returns to step S14.

步驟S26,所述提示模組105給出所有事件對應的LED亮燈情況的測試資訊提示。In step S26, the prompting module 105 gives a test information prompt for the LED lighting condition corresponding to all events.

所有事件對應的LED亮燈情況的測試資訊提示包括:每個事件測試是否成功,事件測試成功時查詢到的LED亮燈情況、LED50的當前狀態,事件測試失敗時的資訊提示,事件測試失敗的個數,事件測試成功的個數等。The test information prompts for LED lighting conditions corresponding to all events include: whether each event test is successful, the LED lighting condition that is queried when the event test is successful, the current status of LED50, the information prompt when the event test fails, and the event test fails. The number, the number of successful event tests, and so on.

綜上所述,本發明符合發明專利要件,爰依法提出專利申請。惟,以上所述者僅爲本發明之較佳實施例,本發明之範圍並不以上述實施例爲限,舉凡熟悉本案技藝之人士援依本發明之精神所作之等效修飾或變化,皆應涵蓋於以下申請專利範圍內。In summary, the present invention complies with the requirements of the invention patent and submits a patent application according to law. The above is only the preferred embodiment of the present invention, and the scope of the present invention is not limited to the above-described embodiments, and equivalent modifications or variations made by those skilled in the art in light of the spirit of the present invention are It should be covered by the following patent application.

1...伺服器1. . . server

10...基於BMC的LED自動化測試系統10. . . BMC-based LED automated test system

20...存儲設備20. . . Storage device

200...資料庫200. . . database

30...BMC30. . . BMC

40...顯示設備40. . . display screen

50...LED50. . . led

100...讀取模組100. . . Read module

101...類比模組101. . . Analog module

102...獲取模組102. . . Get module

103...查詢模組103. . . Query module

104...判斷模組104. . . Judging module

105...提示模組105. . . Prompt module

S10...從資料庫中讀取LED管理表格中的所有資料S10. . . Read all the data in the LED management form from the database

S12...按照一個預設順序類比LED管理表格中的一個事件S12. . . An event in the spreadsheet management table in a preset order

S14...在一個預設的時間間隔後獲取LED的當前狀態S14. . . Get the current state of the LED after a preset time interval

S16...在LED管理表格中查詢理想的LED亮燈情況S16. . . Query the ideal LED lighting situation in the LED management form

S18...LED的當前狀態與LED亮燈情況是否相同S18. . . Is the current state of the LED the same as the LED lighting?

S20...提示該事件對應的LED亮燈情況測試失敗S20. . . Prompt that the LED lighting condition corresponding to the event failed.

S22...所有事件是否均類比完成S22. . . Whether all events are analogous

S24...按照預設順序類比LED管理表格中的下一個事件S24. . . Analog to the next event in the LED management table in a preset order

S26...給出所有事件對應的LED亮燈情況的測試資訊提示S26. . . Give test information prompts for LED lighting conditions corresponding to all events

圖1係為本發明基於BMC的LED自動化測試系統較佳實施例之架構圖。1 is a block diagram of a preferred embodiment of a BMC-based LED automated test system of the present invention.

圖2係為本發明基於BMC的LED自動化測試系統較佳實施例之功能模組圖。2 is a functional block diagram of a preferred embodiment of the BMC-based LED automated test system of the present invention.

圖3係為本發明基於BMC的LED自動化測試方法較佳實施例之流程圖。3 is a flow chart of a preferred embodiment of the BMC-based LED automated test method of the present invention.

圖4係為本發明中LED管理表格的一個示例圖。Fig. 4 is a view showing an example of an LED management table in the present invention.

S10...從資料庫中讀取LED管理表格中的所有資料S10. . . Read all the data in the LED management form from the database

S12...按照一個預設順序類比LED管理表格中的一個事件S12. . . An event in the spreadsheet management table in a preset order

S14...在一個預設的時間間隔後獲取LED的當前狀態S14. . . Get the current state of the LED after a preset time interval

S16...在LED管理表格中查詢理想的LED亮燈情況S16. . . Query the ideal LED lighting situation in the LED management form

S18...LED的當前狀態與LED亮燈情況是否相同S18. . . Is the current state of the LED the same as the LED lighting?

S20...提示該事件對應的LED亮燈情況測試失敗S20. . . Prompt that the LED lighting condition corresponding to the event failed.

S22...所有事件是否均類比完成S22. . . Whether all events are analogous

S24...按照預設順序類比LED管理表格中的下一個事件S24. . . Analog to the next event in the LED management table in a preset order

S26...給出所有事件對應的LED亮燈情況的測試資訊提示S26. . . Give test information prompts for LED lighting conditions corresponding to all events

Claims (12)

一種基於BMC的LED自動化測試方法,其中,該方法包括以下步驟:
讀取步驟:從資料庫中讀取LED管理表格中的所有資料;
類比步驟一:按照一個預設順序類比LED管理表格中的一個事件,在類比過程中BMC控制LED的顏色和頻率;
獲取步驟:在一個預設的時間間隔後獲取LED的當前狀態;
查詢步驟:在LED管理表格中查詢理想的LED亮燈情況;
判斷步驟一:判斷LED的當前狀態與查詢到的LED亮燈情況是否相同,當LED的當前狀態與查詢到的LED亮燈情況相同時,執行判斷步驟二,否則,提示該事件對應的LED亮燈情況測試失敗;
判斷步驟二:判斷所有事件是否均已類比完成,當還有事件未類比時,執行類比步驟二,否則,給出所有事件對應的LED亮燈情況的測試資訊提示;
類比步驟二:按照預設順序類比LED管理表格中的下一個事件,並返回執行獲取步驟。
A BMC-based LED automated test method, wherein the method comprises the following steps:
Read step: read all the data in the LED management table from the database;
Analog step 1: According to an event in the preset order of the LED management table, the BMC controls the color and frequency of the LED during the analogy process;
Acquisition step: obtaining the current state of the LED after a preset time interval;
Query step: query the LED lighting condition in the LED management form;
Judgment step 1: Determine whether the current state of the LED is the same as the LED illumination condition. When the current state of the LED is the same as the LED illumination of the query, perform the judgment step 2. Otherwise, the LED corresponding to the event is highlighted. Lamp condition test failed;
Judgment Step 2: Determine whether all events have been analogized. When there are still events that are not analogous, perform analogy step two. Otherwise, give test information prompts for LED lighting conditions corresponding to all events;
Analog step 2: The next event in the table is managed analogously to the LEDs in a preset order and returned to the execution acquisition step.
如申請專利範圍第1項所述之基於BMC的LED自動化測試方法,其中,所述LED管理表格的每列均為一個參數資訊,每行均表示一個事件,每行的內容均反映一個事件的資訊及該事件對應的LED亮燈情況。The BMC-based LED automated test method according to claim 1, wherein each column of the LED management table is a parameter information, and each row represents an event, and each row reflects an event. Information and LED lighting corresponding to the event. 如申請專利範圍第2項所述之基於BMC的LED自動化測試方法,其中,所述類比步驟一通過以下步驟實現事件的類比:
利用IPMI規範規定的感測器事件設置命令來設定監測該事件的感測器的值,所述感測器事件設置命令由參數資訊來決定感測器的值,所述參數資訊包括感測器識別碼、事件原因和類型。
The BMC-based LED automated test method as described in claim 2, wherein the analogy step 1 implements an analogy of events by the following steps:
The value of the sensor that monitors the event is set using a sensor event setting command specified by the IPMI specification, the sensor event setting command determining the value of the sensor from the parameter information, the parameter information including the sensor Identification code, event reason and type.
如申請專利範圍第1項所述之基於BMC的LED自動化測試方法,其中,在類比步驟一之前還包括:
創建一個一維的優先權陣列,該優先權陣列中的陣列元素的下標值按從小到大的順序與LED管理表格中的優先順序一一對應,每個事件均對應一個陣列元素;
將優先權陣列中的第一個陣列元素的初始值置為1,其餘的每個陣列元素的初始值均置為0。
The method for automatically testing a BMC-based LED according to claim 1, wherein before the analogy step 1, the method further comprises:
Creating a one-dimensional priority array, the index values of the array elements in the priority array are in one-to-one correspondence with the priority order in the LED management table, and each event corresponds to one array element;
The initial value of the first array element in the priority array is set to 1, and the initial value of each of the remaining array elements is set to zero.
如申請專利範圍第4項所述之基於BMC的LED自動化測試方法,其中,所述獲取步驟還包括:
當類比的事件類型為警報時,將該事件對應的陣列元素的初始值做加1操作;
當類比的事件類型為解除警報時,將該事件對應的陣列元素的初始值做減1操作。
The BMC-based LED automated test method of claim 4, wherein the obtaining step further comprises:
When the analog event type is an alarm, the initial value of the array element corresponding to the event is incremented by one;
When the analog event type is to release the alarm, the initial value of the array element corresponding to the event is decremented by 1.
如申請專利範圍第5項所述之基於BMC的LED自動化測試方法,其中,所述查詢步驟通過以下步驟實現LED亮燈情況的查詢:
按照陣列元素的下標值從大到小地讀取陣列元素的初始值,直至讀到陣列元素的初始值為非0,並獲得該非0陣列元素的下標值;
在LED管理表格中查詢優先順序為該非0陣列元素的下標值的事件所對應的顏色和頻率,該顏色和頻率即為理想的LED亮燈情況。
The method for automatically testing a BMC-based LED according to claim 5, wherein the querying step is performed by querying the LED lighting condition by the following steps:
Reading the initial value of the array element from large to small according to the index value of the array element until the initial value of the read array element is non-zero, and obtaining the subscript value of the non-zero array element;
The LED management table is queried for the color and frequency corresponding to the event whose priority order is the subscript value of the non-zero array element, and the color and frequency are ideal LED lighting conditions.
一種基於BMC的LED自動化測試系統,其中,該系統包括:
讀取模組,用於從資料庫中讀取LED管理表格中的所有資料;
類比模組,用於按照一個預設順序類比LED管理表格中的一個事件,在類比過程中BMC控制LED的顏色和頻率;
獲取模組,用於在一個預設的時間間隔後獲取LED的當前狀態;
查詢模組,用於在LED管理表格中查詢理想的LED亮燈情況;
判斷模組,用於判斷LED的當前狀態與查詢到的LED亮燈情況是否相同;
提示模組,用於當LED的當前狀態與查詢到的LED亮燈情況不同時,提示該事件對應的LED亮燈情況測試失敗;
所述判斷模組,還用於當LED的當前狀態與查詢到的LED亮燈情況相同時,判斷所有事件是否均已類比完成;
所述類比模組,還用於當還有事件未類比時,按照預設順序類比LED管理表格中的下一個事件;
所述提示模組,還用於當所有事件均已類比時,給出所有事件對應的LED亮燈情況的測試資訊提示。
A BMC-based LED automated test system, wherein the system includes:
a reading module for reading all the data in the LED management table from the database;
An analog module for analogizing an event in the LED management table in a preset order, the BMC controls the color and frequency of the LED during the analogy process;
Obtaining a module for acquiring a current state of the LED after a preset time interval;
Query module for querying the ideal LED lighting condition in the LED management table;
The determining module is configured to determine whether the current state of the LED is the same as the queried LED lighting condition;
The prompting module is configured to prompt the LED lighting condition corresponding to the event to fail when the current state of the LED is different from the queried LED lighting condition;
The determining module is further configured to determine whether all events have been analogized when the current state of the LED is the same as the queried LED lighting condition;
The analog module is further configured to compare the next event in the LED management table according to a preset order when there is still an event not analogy;
The prompting module is further configured to give a test information prompt for LED lighting conditions corresponding to all events when all events have been analogized.
如申請專利範圍第7項所述之基於BMC的LED自動化測試系統,其中,所述LED管理表格的每列均為一個參數資訊,每行均表示一個事件,每行的內容均反映一個事件的資訊及該事件對應的LED亮燈情況。The BMC-based LED automated test system according to claim 7, wherein each column of the LED management table is a parameter information, and each row represents an event, and each row reflects an event. Information and LED lighting corresponding to the event. 如申請專利範圍第8項所述之基於BMC的LED自動化測試系統,其中,所述類比模組通過以下步驟實現事件的類比:
利用IPMI規範規定的感測器事件設置命令來設定監測該事件的感測器的值,所述感測器事件設置命令由參數資訊來決定感測器的值,所述參數資訊包括感測器識別碼、事件原因和類型。
The BMC-based LED automated test system according to claim 8, wherein the analog module implements an analogy of events by the following steps:
The value of the sensor that monitors the event is set using a sensor event setting command specified by the IPMI specification, the sensor event setting command determining the value of the sensor from the parameter information, the parameter information including the sensor Identification code, event reason and type.
如申請專利範圍第7項所述之基於BMC的LED自動化測試系統,其中,所述類比模組還用於:
創建一個一維的優先權陣列,該優先權陣列中的陣列元素的下標值按從小到大的順序與LED管理表格中的優先順序一一對應,每個事件均對應一個陣列元素;
將優先權陣列中的第一個陣列元素的初始值置為1,其餘的每個陣列元素的初始值均置為0。
The BMC-based LED automated test system of claim 7, wherein the analog module is further configured to:
Creating a one-dimensional priority array, the index values of the array elements in the priority array are in one-to-one correspondence with the priority order in the LED management table, and each event corresponds to one array element;
The initial value of the first array element in the priority array is set to 1, and the initial value of each of the remaining array elements is set to zero.
如申請專利範圍第10項所述之基於BMC的LED自動化測試系統,其中,所述獲取模組還用於:
當類比的事件類型為警報時,將該事件對應的陣列元素的初始值做加1操作;
當類比的事件類型為解除警報時,將該事件對應的陣列元素的初始值做減1操作。
The BMC-based LED automated test system of claim 10, wherein the acquisition module is further configured to:
When the analog event type is an alarm, the initial value of the array element corresponding to the event is incremented by one;
When the analog event type is to release the alarm, the initial value of the array element corresponding to the event is decremented by 1.
如申請專利範圍第11項所述之基於BMC的LED自動化測試系統,其中,所述查詢模組通過以下步驟實現LED亮燈情況的查詢:
按照陣列元素的下標值從大到小地讀取陣列元素的初始值,直至讀到陣列元素的初始值為非0,並獲得該非0陣列元素的下標值;
在LED管理表格中查詢優先順序為該非0陣列元素的下標值的事件所對應的顏色和頻率,該顏色和頻率即為理想的LED亮燈情況。
The BMC-based LED automated test system of claim 11, wherein the query module performs the query of the LED lighting condition by the following steps:
Reading the initial value of the array element from large to small according to the index value of the array element until the initial value of the read array element is non-zero, and obtaining the subscript value of the non-zero array element;
The LED management table is queried for the color and frequency corresponding to the event whose priority order is the subscript value of the non-zero array element, and the color and frequency are ideal LED lighting conditions.
TW101105375A 2012-02-15 2012-02-17 Method and system for testing LED based on BMC automatically TW201333690A (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201210033648 CN103257909A (en) 2012-02-15 2012-02-15 Baseboard management controller (BMC)-based automated testing method and system for light emitting diode (LED)

Publications (1)

Publication Number Publication Date
TW201333690A true TW201333690A (en) 2013-08-16

Family

ID=48961843

Family Applications (1)

Application Number Title Priority Date Filing Date
TW101105375A TW201333690A (en) 2012-02-15 2012-02-17 Method and system for testing LED based on BMC automatically

Country Status (2)

Country Link
CN (1) CN103257909A (en)
TW (1) TW201333690A (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105677544B (en) * 2015-12-30 2019-09-24 联想(北京)有限公司 Lamplight display method and light display apparatus
CN110441713A (en) * 2019-07-12 2019-11-12 苏州浪潮智能科技有限公司 A method of passing through the automatic testing service device LED light stability of BMC
CN110517629A (en) * 2019-08-30 2019-11-29 苏州浪潮智能科技有限公司 A kind of panel LED control method, device, equipment and readable storage medium storing program for executing
CN110579733A (en) * 2019-09-25 2019-12-17 苏州浪潮智能科技有限公司 indicator lamp health detection device and use method thereof

Also Published As

Publication number Publication date
CN103257909A (en) 2013-08-21

Similar Documents

Publication Publication Date Title
US10237160B2 (en) Distributed monitoring and control of network components
KR101357900B1 (en) Network cable and infra-structure intelligent management system and method thereof
TW201333690A (en) Method and system for testing LED based on BMC automatically
US20170075743A1 (en) Method and apparatus for identifying location related hardware failures
CN203849346U (en) Aging test apparatus
US20130162173A1 (en) Light source circuit boards
JP2020067965A (en) USB device
US20150042356A1 (en) Test system for testing electrostatic tester and method thereof
CN108135052A (en) The status information monitoring method of LED lamp, apparatus and system
CN111372039A (en) Monitoring and early warning method, computer device and computer readable storage medium
CN211061648U (en) Chip burning voltage detection circuit
US7188275B2 (en) Method of verifying a monitoring and responsive infrastructure of a system
US7714604B2 (en) System and method for testing an operating condition of LEDs on a motherboard
JP2021128733A (en) MANY-TO-MANY STATUS IDENTIFICATION SYSTEM OF EQUIPMENT NAME BROADCASTED FROM IoT
CN111010519B (en) Control method of display device, television and storage medium
US20120039188A1 (en) Network conection device and method for testing network ports of the network connection device
JP2012198752A (en) Gas alarm
WO2020001053A1 (en) Detection method and detection system for laser driving
CN113448811B (en) Method, device, equipment and readable medium for lighting fault lamp of server system
CN112986800B (en) POR circuit testing method and device
CN202471102U (en) Transducer with aural prompting device
CN107832201A (en) A kind of diagnostic led information rapid interpretive device and method
TW201839544A (en) Debug device
TWI668572B (en) Method for providing device information of cluster storage system
KR20210137512A (en) Security Appliance Extension