TWI227856B - System for displaying waveforms of data signals and method thereof - Google Patents

System for displaying waveforms of data signals and method thereof Download PDF

Info

Publication number
TWI227856B
TWI227856B TW92118327A TW92118327A TWI227856B TW I227856 B TWI227856 B TW I227856B TW 92118327 A TW92118327 A TW 92118327A TW 92118327 A TW92118327 A TW 92118327A TW I227856 B TWI227856 B TW I227856B
Authority
TW
Taiwan
Prior art keywords
data
display
module
displayed
acquisition
Prior art date
Application number
TW92118327A
Other languages
Chinese (zh)
Other versions
TW200502853A (en
Inventor
Win-Harn Liu
Jeff Song
Tung-Ruei Jang
Original Assignee
Inventec Corp
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 Inventec Corp filed Critical Inventec Corp
Priority to TW92118327A priority Critical patent/TWI227856B/en
Publication of TW200502853A publication Critical patent/TW200502853A/en
Application granted granted Critical
Publication of TWI227856B publication Critical patent/TWI227856B/en

Links

Landscapes

  • Controls And Circuits For Display Device (AREA)
  • Digital Computer Display Output (AREA)

Abstract

The present invention relates to a system for displaying waveforms of data signals and a method thereof. The invented system is used to display collected data signals on a computer display. The invented method comprises identifying display parameters and a data initial position of the current display; identifying the total amount of displayable data based on the display parameters and reading a to-be-displayed datum based on the data initial position; separating the datum into eight independent data channel values; converting the datum of each channel into a digital waveform based on the display parameters; and terminating the display when the total amount of displayable data has been reached.

Description

1227856 五、發明說明(1) 【發明所屬之技術領域】 本發明為一種用電腦軟體實現的對待測資料信號進行 分析顯示的系統及方法,特別是一種用軟體實現的邏輯分 斫儀系統及方法。 【先前技術1 在電腦的硬體測試領域’為了更有效的對電腦及其介 面裝置進行測試,需要將待測硬體系統的資料信號採集出 來進行各種顯示分析。有時也需要製作一些測試治具來配 合測試程式進行測試工作,例如對電腦的串行埠、平行 埠、PCMC I A或者CRT埠進行測試時,經常需要將從這些已 經裝置中採集到資料顯示出來,進行進一步的分析處理。 但是,在先前技術中,一般都是依靠特殊的專業設備 來完成信號的採集、顯示與分析工作,例如邏輯分析儀, 雖然這些設備功能強大而齊備,但這種專業設備的造價也 非常昂貴,往往需要幾萬元甚至更多。 而另一方面,目前的計算機具有很強的運算處理能 力,自身又擁有很多通訊埠可以利用,這些通訊埠都具有 基本的輸入/輸出功能,因此,能否利用電腦的強大處理 能力來對採集到的待測硬體資料訊號進行顯示分析,以軟 體程式來取代昂貴的邏輯分析儀設備,遂成為一亟待解決 的問題。 【發明内容】 本發明乃為解決上述問題而提供一種軟體實現的邏輯 分析儀系統及方法,透過普通電腦來完成對採集到的信號1227856 V. Description of the invention (1) [Technical field to which the invention belongs] The present invention is a system and method for analyzing and displaying data signals to be measured using computer software, and more particularly, a logic analyzer system and method using software . [Prior Art 1 In the field of computer hardware testing 'In order to test the computer and its interface devices more effectively, it is necessary to collect the data signals of the hardware system under test for various display analysis. Sometimes it is necessary to make some test fixtures to cooperate with the test program for testing. For example, when testing the serial port, parallel port, PCMC IA or CRT port of the computer, it is often necessary to display the data collected from these existing devices and display them. For further analysis. However, in the previous technology, special professional equipment was generally used to complete the signal acquisition, display, and analysis, such as logic analyzers. Although these devices are powerful and complete, the cost of such professional equipment is also very expensive. It often takes tens of thousands of yuan or more. On the other hand, current computers have very strong computing capabilities, and they have many communication ports that can be used. These communication ports have basic input / output functions. Therefore, can you use the computer's powerful processing capabilities to collect data? Displaying and analyzing the data signals of the hardware under test and replacing expensive logic analyzer equipment with software programs have become an urgent problem. [Summary of the Invention] The present invention is to provide a software-implemented logic analyzer system and method for solving the above problems.

第4頁 1227856 資料信號透 ,總量計算 顯示模組, 計算模組用 料讀取模組 用以將該言買 ’貢料顯不 形。 發明,可以 再依靠專用 也容易使用 非常低廉, 資料獲取, 可滿足大多 料訊5虎的 腦顯示器 料起始位 根據資料 料分離為 通道的資 時停止顯 種資料訊 過電腦顯 模組,資 其中,參 以根據顯 用以從資 取的待顯 模組用以 五、發明說明(2) 進行顯示與分析。 本發明提供一種資 集到的資料信號透過電 參數以及當前顯示的資 定可顯示的資料總量, 待顯示資料,再將該資 根據該顯示參數將每個 到該可顯示的資料總量 本發明進而提供一 將採集到的 數採集模組 組以及資料 參數,總量 料總量,資 料分離模組 道的獨立值 換為數位波 應用本 來,而不用 成本,並且 硬體成本也 就可以進行 中的需求, 的0 波形顯示方法,用以將採 顯示出來,首先確定顯示 置,然後根據顯示參數確 起始位置從資料區讀取一 8個資料通道的獨立值, 料轉換為數位波形,當達 示。 號的波形顯示系統,用以 不恭顯不出來’包括·麥 料讀取模組,資料分離模 數收集模組用以收集顯示 示參數計算出可顯示的資 料區Ί買取待顯不貪料’貧 示資料分離為8個資料通 將該每個通道的獨立值轉 將資料訊號透過電腦顯示器顯示出 的信號分析設備,而從大大節約了 ,如果需要採集資料,採集資料的 只需一個通訊埠介面,幾根電纜線 簡單實用,充分考慮一般硬體開發 數開發的需要,而且性能也是可靠Page 4 1227856 The data signal is transparent, the total amount calculation display module, and the material reading module for the calculation module are used to buy the word ‘tribute material. Invented, it can be relied on special purpose and easy to use. Very low-cost, data acquisition, which can meet most of the information 5 Tiger's brain display material starting position according to the data material is separated into channels when the data is stopped. Among them, the module to be displayed, which is obtained from the fund according to the display, is used for display and analysis in V. Invention Description (2). The invention provides a total amount of data signals that can be displayed through the electrical parameters and the currently displayed data. After the data is displayed, the data is converted to the total amount of data that can be displayed according to the display parameters. The invention further provides a collection of the digital acquisition module group and data parameters, the total amount of materials, and the independent value of the data separation module channel for digital wave applications without cost, and hardware costs can be carried out. The 0 waveform display method is used to display the acquisition, first determine the display position, and then read an independent value of 8 data channels from the data area according to the display parameters to determine the starting position. The data is converted into a digital waveform. Dash. Waveform display system to display it inconspicuously. 'Includes the wheat material reading module, and the data separation module collection module is used to collect the display parameters and calculate the displayable data area. 'The poor display data is separated into 8 data channels. The independent value of each channel is transferred to the signal analysis equipment displayed by the computer display, which greatly saves. If you need to collect data, you only need one communication to collect data. Port interface, several cables are simple and practical, fully consider the needs of general hardware development, and the performance is also reliable

第5頁 Ϊ227856 五、發明說明(3) 【貫施方式】 |$本發明提供一種資料訊號的波形顯示方法,用以將採 | ^的貧料信號透過電腦顯示器顯示出來,參閱第1圖, ^ 確定顯示參數以及當前顯示的資料起始位置(步驟 ^ ’顯示參數包括顯示器的當前解析度以及用戶設定 | j,形/資料顯示比例等,然後根據顯示參數確定可顯示 |的M料總量(步驟1 0 2),根據資料起始位置從資料區讀 |、:待顯示資料(步驟1 0 3),再將該資料分離? 8個資料 | ^道的獨立值(步驟1 0 4),例如:一個b y t e為4 5 Η,分離 為8位元,從低位元到高位依次? 1,〇,1,〇,〇,〇,1, 77 別代表 channelO,channell,....(:1181111617的資 丨料’根據該顯示參數將每個通道的資料轉換為數位波形 (步驟1 0 5),當達到該可顯示的資料總量時停止顯示 (步驟106) 〇 對於顯示圖形的展開與壓縮,實際上就是每圖元代表 多少資料量的問題,因為電腦螢幕寬度一般是1 〇 2 4圖元, |故需確定多少個圖元對應多少個資料。比如圖形/資料的 比例為1 : 2,則每圖元代表2個資料,若資料總量為 32 kbyte,則為了顯示這些資料需要3 2 * 1 0 2 4 / 2 = 1 6 * 1 0 2 4個 |圖元的寬度。如圖形/資料的比例改為1 : 4,則只需3 2 * 1 0 2 4 / 4 = 8 * 1 0 2 4個圖元的寬度。相反的情況,如圖形/資 |料的比例為2 : 1,即兩個圖元表示一個資料,則這時這兩 1個圖元代表的資料肯定是相同的,也就是要重復顯示若干 ^欠相同的資料。Page 5Ϊ227856 V. Description of the invention (3) [Performance method] | The present invention provides a waveform display method for data signals, which is used to display the lean material signal collected by ^ through a computer monitor. Refer to Figure 1, ^ Determine the display parameters and the starting position of the currently displayed data (step ^ 'The display parameters include the current resolution of the display and the user settings | j, shape / data display ratio, etc., and then determine the total amount of M materials that can be displayed according to the display parameters (Step 1 0 2), read the data from the data area according to the starting position of the data, and then display the data (step 10 3), and then separate the data? 8 data | ^ independent values of the channel (step 1 0 4) For example: a byte is 4 5 Η, separated into 8 bits, from low to high order? 1, 〇, 1, 〇, 〇, 〇, 1, 77 Don't represent channelO, channell, ... (: The data of 1181111617 'converts the data of each channel into a digital waveform according to the display parameters (step 105), and stops displaying when the total amount of displayable data is reached (step 106). Compression is actually per image The question of how much data represents, because the width of the computer screen is generally 104 pixels, so you need to determine how many graphics correspond to how many data. For example, the ratio of graphics / data is 1: 2, each pixel represents 2 Data, if the total data is 32 kbyte, in order to display these data, 3 2 * 1 0 2 4/2 = 1 6 * 1 0 2 4 | the width of the element. For example, if the figure / data ratio is changed to 1 : 4, you only need 3 2 * 1 0 2 4/4 = 8 * 1 0 2 4 element width. In the opposite case, if the ratio of graphics / materials is 2: 1, that is, two elements Indicates a piece of data, then the data represented by these two elements must be the same, that is, several pieces of data that are not the same must be repeatedly displayed.

1227856 五、發明說明(4) 這些待顯示資料可以是事先已經存儲在硬碟中的資 料,也可以是在應用程式的資料存儲區的資料,或者是即 時的經由資料獲取程式採集到的資料,例如,本發明還可 以包括一資料獲取過程,參閱第2圖,將待測硬體與電腦 通訊埠相連(步驟2 01),設置資料獲取量與採集觸發條 件(步驟2 0 2),根據資料獲取量從内核分配相應數量的 記憶體空間(步驟2 0 3),遮罩作業系統的多執行緒切換 功能(步驟2 0 4),根據採集觸發條件連續從通訊埠讀入 待測硬體貢料(步驟2 0 5) ^將採集到的貧料存入内核分 配的記憶體空間直至存滿(步驟2 0 6):恢復作業系統的 多執行緒切換功能(步驟2 0 7),將採集到的資料從内核 分配的記憶體空間轉存入資料存儲區(步驟2 0 8),釋放 該内核分配的記憶體空間(步驟2 0 9)。 其中該遮罩/恢復作業系統的多執行緒切換功能之步 驟,是透過關閉/重啟系統中斷來實現的。所述内核分配 的記憶體空間為不可交換的記憶體空間。 本發明進而提供一種資料訊號的波形顯示系統,用以 將採集到的資料信號透過電腦顯示器顯示出來,參閱第3 圖,該系統包括:參數收集模組3 0 1,總量計算模組3 0 2, 資料讀取模組3 0 3,資料分離模組3 0 4,資料顯示模組 3 0 5 〇 其中,參數收集模組3 0 1用以收集顯示參數,總量計 算模組3 0 2用以根據顯示參數計算出可顯示的資料總量, 貢料讀取模組3 0 3用以從貢料區讀取待顯示貢料’資料分 1227856 五、發明說明(5) 離模組3 0 4用以將該讀取的待顯示資料分離為8個資料通道 的獨立值,資料顯示模組3 0 5用以將該每個通道的獨立值 蹲換為數位波形。 同樣,如果需要採集資料時,本發明更包括一訊號採 集裝置,參閱第4圖,包括通訊埠介面裝置4 0 1,遮罩控制 壤組4 0 2,配置模組4 0 3,採集模組4 0 4,儲存模組4 0 5。 其中,通訊埠介面裝置4 0 1用於連接待測硬體並傳輸 測試資料,遮罩控制模組4 0 2用於遮罩或恢復作業系統的 多執行緒切換功能,配置模組4 0 3用於設置資料獲取量以 及採集觸發條件,採集模組4 0 4用於根據採集觸發條件採 集資料,儲存模組4 0 5用於用於儲存由該採集模組採集到 的資料。 對於類似w i ndows等的保護模式作業系統,還需要一 暫存模組,用於臨時儲存採集到的資料並在該遮罩恢復後 將資料轉存入該存儲模組。 其中該通訊埠介面裝置包括一訊號傳輸線,一端連接 於通訊埠的資料線與地線,另一端與待測硬體系統的相應 訊號端相連。 對於不同的通訊埠,其外部輸入電壓不同,因此,介 面裝置還可以包括一電壓轉換電路,用於匹配待測硬體的 輸出電壓與通訊埠的外部輸入電壓。 下面舉一具體實施例來說明本發明,在本實施例中, 首先經過了資料獲取過程,再對採集到的資料加以顯示分 析,但本發明並不限於此實施例,對於任何已經獲得的資1227856 V. Description of the invention (4) The data to be displayed can be the data that has been stored in the hard disk beforehand, the data in the data storage area of the application, or the data collected by the data acquisition program in real time. For example, the present invention may also include a data acquisition process. Referring to FIG. 2, the hardware to be tested is connected to the computer communication port (step 2 01), the data acquisition amount and acquisition trigger conditions are set (step 2 0 2), and according to the data The acquisition amount allocates a corresponding amount of memory space from the kernel (step 203), masks the multi-thread switching function of the operating system (step 203), and continuously reads the hardware to be tested from the communication port according to the acquisition trigger condition (Step 2 0 5) ^ Save the collected lean material into the memory space allocated by the kernel until it is full (Step 2 6): Restore the multi-thread switching function of the operating system (Step 2 0 7), and collect The obtained data is transferred from the memory space allocated by the kernel into the data storage area (step 208), and the memory space allocated by the kernel is released (step 209). The step of the multi-thread switching function of the mask / recovery operating system is realized by shutting down / restarting the system interrupt. The memory space allocated by the kernel is a non-exchangeable memory space. The invention further provides a waveform display system for data signals, which is used to display the collected data signals through a computer display. Referring to FIG. 3, the system includes a parameter collection module 3 0 1 and a total calculation module 3 0 2. Data reading module 3 0 3, data separation module 3 0 4, data display module 3 0 5 〇 Among them, the parameter collection module 3 0 1 is used to collect and display parameters, the total calculation module 3 0 2 Used to calculate the total amount of data that can be displayed according to the display parameters. Tribute reading module 3 0 3 is used to read the tributary materials to be displayed from the tributary area. Data points 1227856 V. Description of the invention (5) Off module 3 0 4 is used to separate the read data to be displayed into independent values of 8 data channels, and data display module 3 0 5 is used to squat the independent value of each channel into a digital waveform. Similarly, if data needs to be collected, the present invention further includes a signal acquisition device, see FIG. 4, including a communication port interface device 401, a mask control soil group 402, a configuration module 403, and an acquisition module. 4 0 4, storage module 4 05. Among them, the communication port interface device 4 0 1 is used to connect the hardware under test and transmit test data, and the mask control module 4 0 2 is used to mask or restore the multi-thread switching function of the operating system. The configuration module 4 0 3 It is used to set the data acquisition amount and acquisition trigger conditions. The acquisition module 404 is used to collect data according to the acquisition trigger conditions, and the storage module 405 is used to store the data collected by the acquisition module. For protected-mode operating systems such as Windows, a temporary storage module is needed to temporarily store the collected data and transfer the data to the storage module after the mask is restored. The communication port interface device includes a signal transmission line. One end is connected to the data line and ground line of the communication port, and the other end is connected to the corresponding signal end of the hardware system under test. For different communication ports, the external input voltage is different. Therefore, the interface device can also include a voltage conversion circuit to match the output voltage of the hardware under test with the external input voltage of the communication port. The following describes a specific embodiment to illustrate the present invention. In this embodiment, the data acquisition process is first performed, and then the collected data is displayed and analyzed. However, the present invention is not limited to this embodiment.

第8頁 1227856 五、發明說明(6) 料,都可以應用本發明進行波形顯示。 以平行璋為例,我們知道,電腦的平行庳除了連接印 表機外,還可做一般的通訊埠使用,具有普通的 I / 0功 能,這就提示我們,可以使用平行埠作為資料獲取通道, 充分利用PC機強大的運算控制能力實現資料獲取功能。 八 請參閱第5圖,在本發明的平行埠實施例中,為實現 資料獲取功能而要製作的通訊埠介面裝置,結構非常簡 單,利用一個普通的平行埠插頭,9條細的硬芯線,分別 焊接在平行埠接頭的資料線和地線,然後將平行埠接頭插 在電腦的平行埠即可,使用時將地線與被測系統的地線接 好,將其他信號線接在需要採集資料的信號端即可。 需要注意的是,平行埠的外部輸入電平為TTL電平, 範圍是0〜5 V,如待測電路的電壓高於此範圍,必須增加電 壓轉換電路,以免造成平行埠損壞。 一般情況下,電腦的平行埠有四種工作方式: SPP模式(Standard Parallel Port):最普通的平 行埠模式,用於控制平行埠印表機,可透過平行埠的控制 端發出控制命令,透過狀態端讀取印表機狀態,資料端為 單向輸出,用於向印表機輸出資料。 EPP模式(Extended Parallel Port):此模式支援 資料的高速(最高2Mb/s)雙向傳輸,並可定址多個 (2 5 6)設備。 ECP模式(Enhanced Capability Port):與 EPP模式 類似,但增加了資料壓縮,F I F 0 (快取記憶體)等功能。Page 8 1227856 V. Description of the invention (6) It is possible to apply the present invention to waveform display. Taking the parallel port as an example, we know that the parallel port of a computer can be used as a general communication port in addition to a printer. It has ordinary I / 0 functions, which reminds us that we can use the parallel port as a data acquisition channel. , Make full use of the PC's powerful computing control capabilities to achieve data acquisition functions. Please refer to FIG. 5. In the parallel port embodiment of the present invention, the communication port interface device to be made in order to realize the data acquisition function has a very simple structure. It uses a common parallel port plug and 9 thin hard core wires. Weld the data and ground wires of the parallel port connector separately, and then plug the parallel port connector into the parallel port of the computer. When in use, connect the ground wire to the ground wire of the system under test, and connect other signal wires to the acquisition The signal end of the data is sufficient. It should be noted that the external input level of the parallel port is TTL level, and the range is 0 ~ 5 V. If the voltage of the circuit under test is higher than this range, a voltage conversion circuit must be added to avoid damage to the parallel port. In general, the computer's parallel port has four working modes: SPP mode (Standard Parallel Port): The most common parallel port mode is used to control the parallel port printer. It can send control commands through the control port of the parallel port. The status terminal reads the printer status, and the data terminal is a unidirectional output, which is used to output data to the printer. EPP mode (Extended Parallel Port): This mode supports high-speed (up to 2Mb / s) bidirectional transmission of data, and can address multiple (2 5 6) devices. ECP mode (Enhanced Capability Port): Similar to EPP mode, but adds data compression, F I F 0 (cache memory) and other functions.

第9頁 1227856 五、發明說明(7) 平 b 示 61(1丨]:6(^丨〇1^1模式(或稱1^2模式):在此模式下, 行埠不僅能實現SPP下的功能,而且透過控制寄存器的’ U5,可選擇資料線工作於輸入或輸出模式:bit5 = 〇,表 輸出,M t 5二1,則表示輸入。本發明可採用此模式。^ 於要採集外部信號,因此要求將平行埠置於輸入狀能, bit5=l。 ’Page 9 of 1227856 V. Description of the invention (7) Flat b shows 61 (1 丨): 6 (^ 丨 〇1 ^ 1 mode (or 1 ^ 2 mode): In this mode, the port can not only achieve the SPP Function, and through the control register 'U5, the data line can be selected to work in input or output mode: bit5 = 〇, table output, M t 5 2 1 means input. The present invention can use this mode. ^ To be collected External signal, so it is required to set the parallel port to the input state, bit5 = l. '

雖然平打埠的原理並不複雜,但如何在w丨〇〇心環 下貫現貧料獲取仍是問題。在|)〇鴻境下讀取平行埠狀離 並無困難,用C語言簡單的import命令即可,但D〇s下的。 戶介面|難做的友好,同時現在絕大多數是工作在 WINDOWS環境,因此必須解決WIND〇ws下平行埠資料讀寫的 現在廣泛使用的WINDOWS系統按基本原理可分 類:\^100界898系列和|10(^820〇〇系列。前者包括 WINDOWS9 5/9 8/ME ’對底層操作採用VxD的方 WUD⑽S-NT/ 2 0 0 0 /XP,對底層操作則需採用的技^^實# 現。适兩種技術在具體實現上是完全不同、 理則是一樣的。 彳-他們的原Although the principle of Pingdabu is not complicated, it is still a problem how to achieve poor material acquisition under the heart. It is not difficult to read the parallel port-shaped separation under the |) 〇 Hongjing, you can use the simple import command of C language, but it is under Dos. User interface | Friendly difficult to do, and currently most of them work in the Windows environment, so we must solve the parallel port data read and write under WIND〇ws Now widely used Windows system can be classified according to basic principles: \ ^ 100 界 898 series And | 10 (^ 82000 series. The former includes WINDOWS9 5/9 8 / ME 'WUDxS-NT / 2 0 0 / XP using VxD for low-level operations, and techniques required for low-level operations ^^ 实 # Now, the two technologies are completely different in concrete implementation, and the principles are the same. 彳-their original

WINDOWS系統對硬體及1/〇埠的保護是透過“。丨 L列丨:的^模式機制實現的’要想獲得對硬體通訊蟬WINDOWS system's protection of hardware and port 1 / 〇 is realized through ". 丨 L column 丨: ^ mode mechanism '

勺紅作冻可柄,必須使程式運行於RING_權級。wDM 工^在RING〇級,在這種狀態下,可以象在DO 中樣對糸統執行任何操作,但特權級的切換需要消耗 量的CPU時間,嚴.重影響埠資料的讀取速度,造成資料^Spoon red can be frozen, you must make the program run at RING_ weight level. The wDM tool is at the level of RING0. In this state, you can perform any operation on the system as in DO, but the switching of privilege levels requires CPU time, which seriously affects the reading speed of port data. Cause information ^

12278561227856

五、發明說明(8) i部本發明需要一直工作在一〇級,直到採集完 信號!:二Π訊號的採集特點在於將某個採集點的數位 即使連續性。1然而WINDQws是—個多工系統, 機制。=tRI_別的程式’也要遵守執行緒調度的 資料,=有可能發生這種情況:程式正在從平行埠讀取 ,1部被系統將控制權切換到其他執行緒,顯缺這將、皮 成貝料丟失。而如何關閉系統的執行緒調度制,、、' 力= ==術:段來實現,但我們可以分析系;:程= 二ΐ: ί顯然是基於pc系統的時鐘及中斷系統,只要 關閉糸統中斷,就可以遮罩執行緒切換功能。 由上面的分析,我們知道在資料獲取期間,本發明 閉了糸統的中斷以防止資料丟失,但這隨之帶來一個 題··採集到的資料存放在那裏呢?如果按照一般的編程方 法,申請一塊記憶體,則由於Windows系統虛擬記憶體的 機制,申請到的記憶體不一定真的在ram裏,可能在交換 文件中’這樣在使用時必須進行讀寫硬碟的操作,但是系 統的中斷卻已經被關閉了 ,硬碟中斷無法回應,這樣—> ' 來,顯然系統將會崩潰。因此,我們必須使用1丨11(1〇”函 數:new(N〇nPagedPool)UCHAR[bufsize],即可分配到 b u f s i z e位元組的R A Μ,而且保證不會被交換到硬碟上去。 這樣我們可以將採集到的貧料存放在這個b u f f e r裏並且不 會觸發硬碟的操作。V. Description of the invention (8) The present invention needs to work at level 10 until the signal is collected! : The characteristics of the two Π signal collection are that the digits of a certain collection point are continuous. 1 However WINDQws is a multiplexing system and mechanism. = tRI_Other programs' must also observe the thread scheduling data. = This may happen: the program is reading from the parallel port, and one system is switched to other threads by the system. The shell material is lost. And how to turn off the system's thread scheduling, force, force = == surgery: segment to achieve, but we can analyze the system;: 程 = 二 ΐ: ί is obviously based on the PC system clock and interrupt system, as long as you turn off 糸If the system is interrupted, the thread switching function can be masked. From the above analysis, we know that during the data acquisition period, the present invention shuts down the system to prevent data loss, but this brings a problem. Where is the collected data stored? If you apply for a piece of memory according to the general programming method, due to the mechanism of the virtual memory of the Windows system, the applied memory may not be actually in the ram. It may be in the exchange file. Disk operation, but the system interruption has been turned off, and the hard disk interruption cannot respond, so-> ', obviously the system will crash. Therefore, we must use the 1 丨 11 (1〇 ”function: new (N0nPagedPool) UCHAR [bufsize] to assign the RA Μ to the bufsize byte, and ensure that it will not be swapped to the hard disk. This way we The collected lean material can be stored in this buffer and will not trigger the operation of the hard disk.

1227856 五、發明說明 在資 :刀貢料’ 時機。因 件,只有 終顯示的 條件的配 不1¾電平 表示在通 料。 存儲 數位信號 問題,只 形即可。 由於 盡可能多 料的比例 無論〇或 形/資料, 按比例抽 形的嚴重 於1 : 2的 果按上面 位元 失真,因 (9) 料獲取過程中,如果只是簡單地記錄平行埠的一 那麼資料就沒有什麼用了,因為無法控制採集的 此用戶必須可以在介面中設定資料獲取的觸發條 當條件滿足時才開始紀錄貢料,這樣就可保證最 是用戶真正需要的資料。請參閱第6圖,為觸發 置介面示意圖,選擇0表示低電平觸發,選擇1表 觸發,X表示任意電平觸發◦因此,如圖中所示 道0為低電平且通道1為高電平時,開始採集資 于存儲區中的,或是經過採集到的資料為純粹的 ,即0或1,因此這裏不涉及信號的放大或縮小的 需根據預先設定的顯示比例將資料轉換?數位波 一次採集到的資料量可能比較大,用戶為了觀察 的資料,希望對顯示的波形進行縮放。圖形/資 大於1 : 1的情況比較簡單,只要對每一個資料, [,重復顯示若干次相同的資料即可。但對於圖 丨、於1 ·· 1的比例的情況則不能採取從原始資料中 取部分貢料顯不的方法。因為這樣會造成顯不波 失真,誤導用戶作出錯誤的邏輯分析。例如:對 比例’假設有如下貧料序列· 001101011000’如 的錯誤方法,我們將會取序列中的1,3,5,7 資料進行顯示,則資料變為〇 1 〇 〇 1 〇波形顯示就會 此在這種情況下仍應採取與圖形/資料大於1 : 11227856 V. Description of the invention Because of this, only the 1½ level of the condition shown at the end is indicated in the material. The problem of storing digital signals is simple. Since the ratio of as many materials as possible is 0 or shape / data, the results of proportion drawing are more serious than 1: 2. According to (9) during the material acquisition process, if only one of the parallel ports is simply recorded, Then the data is useless, because the user who cannot control the collection must set the trigger of data acquisition in the interface and start recording the tribute when the conditions are met, so that the most important data the user really needs can be guaranteed. Please refer to Figure 6 for the trigger interface diagram. Select 0 for low-level trigger, 1 for table trigger, and X for arbitrary level trigger. Therefore, as shown in the figure, channel 0 is low and channel 1 is high. When the level is set, the data collected in the storage area starts to be collected, or the collected data is pure, that is, 0 or 1, so here does not involve signal amplification or reduction. Need to convert the data according to the preset display ratio? Digital Wave The amount of data collected at one time may be relatively large. In order to observe the data, the user wants to zoom the displayed waveform. The situation where the graph / data is greater than 1: 1 is relatively simple, as long as for each data, [, repeatedly display the same data several times. However, for the case where the ratio of the figure to 1 ·· 1 cannot be taken, the method of taking part of the tribute from the original data and displaying it inconspicuously cannot be adopted. Because this will cause obvious wave distortion, misleading users to make wrong logic analysis. For example: the comparative example 'assumes the following lean material sequence · 001101011000' such as the wrong method, we will take the 1, 3, 5, 7 data in the sequence for display, then the data will become 〇1 〇〇1 〇 waveform display will Will this in this case should still be taken with graphics / data greater than 1: 1

1227856 五、發明說明(ίο) 的比例相同的方法處理。 本發明可以應用於各種硬體系統的測試,例如,在有 的專案開發過程中,需要準確地暸解電腦 CRT介面的輸 出信號,主要是行同步信號及場同步信號的具體波形及它 們的時序關係,利用本發明就可以收集CRT介面的資料訊 號,然後再加以分析,如第7圖所示,Channe 1 0為行同 步脈衝,C h a η n e 1 1為場同步脈衝。 再例如,單板機的串列通訊程式如發生錯誤,要找出 原因是很麻煩的,因為既可能是串行埠設定的問題,又可 能是線路斷線,也可能是串列傳輸速率不匹配,甚至串列 設備損壞,這就需要收集串列設備的資料訊號,觀察線路 上的信號波形,迅速確定故障原因。我們知道,串行埠線 路平時的狀態為高電平,發送資料時起始位元用0表示, 為了捕捉串行埠資料線上的有效資料,可以設定相應的捕 捉觸發條件,如第8— 1圖所示,採用這種設定採集到的串 列埠發送資料波形如第8— 2圖所示,結合串列埠通訊協定 分析可知,該資料為0x55,Oxaa。 以上所述者,僅為本發明其中的較佳實施例而已,並 非用來限定本發明的實施範圍;即凡依本創作申請專利範 圍所作的均等變化與修飾,皆為本創作專利範圍所涵蓋。1227856 Fifth, the invention description (ίο) of the same proportion. The invention can be applied to the testing of various hardware systems. For example, during the development of some projects, it is necessary to accurately understand the output signals of the computer CRT interface, mainly the specific waveforms of the line synchronization signal and the field synchronization signal and their timing relationship. By using the present invention, the data signals of the CRT interface can be collected and then analyzed. As shown in FIG. 7, Channe 10 is a line synchronization pulse, and C ha η ne 1 1 is a field synchronization pulse. For another example, if an error occurs in the serial communication program of a single board computer, it is very troublesome to find out the reason, because it may be a problem with the serial port setting, it may be a line disconnection, or it may be a serial transmission rate. Match, or even the serial equipment is damaged, it is necessary to collect the data signals of the serial equipment, observe the signal waveform on the line, and quickly determine the cause of the failure. We know that the normal state of the serial port line is high, and the start bit is represented by 0 when sending data. In order to capture valid data on the serial port data line, you can set the corresponding capture trigger conditions, such as Section 8-1 As shown in the figure, the waveform of the serial port sent data collected with this setting is shown in Figure 8-2. According to the analysis of the serial port protocol, the data is 0x55, Oxaa. The above are only the preferred embodiments of the present invention, and are not intended to limit the scope of implementation of the present invention; that is, all equivalent changes and modifications made in accordance with the scope of the patent application for this creation are covered by the scope of the creation patent .

第13頁 1227856 圖式簡單說明 第1圖:為本發明之資料訊號的波形顯示方法之流程圖; 第2圖:為本發明所提之資料訊號的採集方法流程圖; 第3圖:為本發明之資料訊號的波形顯示系統之模組架構 J], 第4圖:為本發明所提之資料訊號的採集系統模組架構 圖; 第5圖:為本發明所提之平行埠介面示意圖; 第6圖:為本發明所提之觸發條件配置介面示意圖; 第7圖:為應用本發明收集CRT介面的資料訊號顯示示意 示 件 發 觸 的 料 資 路 線 列 串 捉 捕 明 發 本 用 應 為 圖 1X I ; 8 圖第 顯 形 波 的 號 訊 料 資 路 線 列 串 捉 捕 明 發 本 用 應 為 • · ο 及圖圖 2 •, 意 圖8 示 意第示 置 位 始 起 料 資 的 示 顯 前 當 及 以 數 參 示 η顯 明t L定 說S # 符1 ο 式1 圖驟 t步 驟驟驟驟 步步步步 料 資 示 顯 量待 總一 料取 資讀 的區 示料 顯資 可從 定置 確位 數始 參起 示料 顯資 據據 根根 將 為數 離參 分示 料顯 資該 該據 將根 值 立 獨 的 道 通 料 資 個' 位 數 為 換 轉 料 資 的 道 通 個 每 形驟驟驟 波步步步 示 顯 止 停 件 時連條 量相發 總埠觸 料訊集 資通採 的腦與 示電量 顯與取 可體獲 該硬料 到測資 達待置 當將設1227856 on page 13 Brief description of the diagram Figure 1: This is a flowchart of the method of displaying the data signal waveform of the present invention; Figure 2: This is a flowchart of the method of collecting the data signal of the present invention; Figure 3: This is Module structure of the waveform display system of the data signal of the invention J], FIG. 4 is a block diagram of the data signal acquisition system module of the invention; FIG. 5 is a schematic diagram of the parallel port interface of the invention; Figure 6: Schematic diagram of the triggering condition configuration interface provided by the present invention; Figure 7: The application of the present invention to collect the data signal display of the CRT interface shows the schematic diagram of the material route triggering the capture of the original application should be Figure 1X I; Figure 8 shows the signal line of the tangential wave. The material route is to capture the clear hair. The application should be • · ο and Figure 2 •. Intent 8 indicates the display of the material from the beginning of the display. And the numerical reference shows η to show t L set to say S # 符 1 ο Formula 1 Figure t t step step step step step by step step by step material information display the amount of material to be a total of the material to read the area display material information can be determined from the set Number of parameters According to the data display, the data display will be based on the data display. The data display will be based on the number of road materials. The number of digits is the number of steps to change the material. Display step-by-step display of stoppages and continuous shipments. Total port contact information. Collected brain and display of electricity. Display and acquisition can obtain the hard material.

第14頁 1227856 圖式簡單說明 步驟2 0 3 空間 步驟204 步驟2 0 5 資料 步驟2 0 6 至存滿 步驟2 0 7 步驟2 0 8 根據資料獲取量從内核分配相應數量的記憶體 遮罩作業系統的多執行緒切換功能 根據採集觸發條件連續從通訊埠讀入待測硬體 將採集到的資料存入内核分配的記憶體空間直 恢復作業系統的多執行緒切換功能 將採集到的資料從内核分配的記憶體空間轉存 入貧料存儲區 步驟2 0 9 釋放該内核分配的記憶體空間 3 0 1參數採集模組 3 0 3資料讀取模組 3 0 5資料顯示模組 4 0 2遮罩控制模組 4 0 4採集模組 3 0 2總量計算模組 3 0 4資料分離模組 401通訊埠介面裝置 4 0 3配置模組 4 0 5儲存模組Page 14 1227856 Schematic description step 2 0 3 space step 204 step 2 0 5 data step 2 0 6 to full step 2 0 7 step 2 0 8 allocate the corresponding amount of memory mask operation from the kernel according to the amount of data acquired The system's multi-thread switching function continuously reads in the hardware under test from the communication port according to the acquisition trigger conditions and stores the collected data into the memory space allocated by the kernel. The multi-thread switching function of the operating system restores the collected data from The memory space allocated by the kernel is transferred to the lean storage area Step 2 0 9 The memory space allocated by the kernel is released 3 0 1 parameter acquisition module 3 0 3 data reading module 3 0 5 data display module 4 0 2 Mask control module 4 0 4 Acquisition module 3 0 2 Total calculation module 3 0 4 Data separation module 401 Communication port interface device 4 0 3 Configuration module 4 0 5 Storage module

第15頁Page 15

Claims (1)

1227856 六、申請專利範圍 1、 一種資料訊號的波形顯示方法,用以將採集到的資料 信號透過電腦顯示器顯示出來,該方法包括: 確定顯示參數以及當前顯示的資料起始位置; 根據顯示參數確定可顯示的資料總量; 根據資料起始位置從資料區讀取一待顯示資料; 將該資料分離為8個資料通道的獨立值; 根據該顯示參數將每個通道的資料轉換為數位波形;及 當達到該可顯示的資料總量時停止顯示。 2、 如申請專利範圍第1項所述之資料訊號的波形顯示方 法,其中該顯示參數包括:顯示器的當前解析度以及用戶 設定的圖形/資料顯示比例。 3、 如申請專利範圍第1項所述之資料訊號的波形顯示方 法,其中該從資料區讀取一待顯示資料之步驟,是從硬碟 存儲區讀取。 4、 如申請專利範圍第1項所述之資料訊號的波形顯示方 法,其中該從資料區讀取一待顯示資料之步驟,是從應用 程式·的資料存儲區讀取。 5、 如申請專利範圍第1項所述之資料訊號的波形顯示方 法,其中更包括一資料獲取過程,包括: 將待測硬體與電腦通訊埠相連; 設置資料獲取量與採集觸發條件; 根據資料獲取量從内核分配相應數量的記憶體空間; 遮罩作業系統的多執行緒切換功能; 根據採集觸發條件連續從通訊埠讀入待測硬體資料;1227856 VI. Application for Patent Scope 1. A waveform display method of data signals for displaying the collected data signals through a computer monitor. The method includes: determining display parameters and the starting position of the currently displayed data; determining according to the display parameters The total amount of data that can be displayed; read a data to be displayed from the data area according to the starting position of the data; separate the data into independent values of 8 data channels; convert the data of each channel into a digital waveform according to the display parameters; And stop displaying when the total amount of displayable data is reached. 2. The waveform display method of the data signal as described in item 1 of the scope of patent application, wherein the display parameters include: the current resolution of the display and the graphic / data display ratio set by the user. 3. The waveform display method of the data signal as described in item 1 of the scope of patent application, wherein the step of reading a data to be displayed from the data area is from the hard disk storage area. 4. The waveform display method of the data signal as described in item 1 of the scope of patent application, wherein the step of reading a data to be displayed from the data area is to read from the data storage area of the application program. 5. The waveform display method of the data signal as described in item 1 of the scope of patent application, which further includes a data acquisition process, including: connecting the hardware under test to a computer communication port; setting the data acquisition amount and acquisition trigger conditions; The data acquisition amount allocates a corresponding amount of memory space from the kernel; the multi-thread switching function of the mask operating system; continuously reads in the hardware data to be tested from the communication port according to the acquisition trigger condition; 第16頁 1227856 六、申請專利範圍 將採集到的資料存入内核分配的記憶體空間直至存滿; 恢復作業系統的多執行緒切換功能; 將採集到的資料從内核分配的記憶體空間轉存入資料存儲 益,及 釋放該内核分配的記憶體空間。 6、 如申請專利範圍第5項所述之資料訊號的波形顯示方 法,其中該遮罩/恢復作業系統的多執行緒切換功能之步 驟,是透過關閉/重啟系統中斷來實現的。 7、 一種資料訊號的波形顯示系統,用以將採集到的資料 信號透過電腦顯示器顯示出來,該系統包括: 參數收集模組,用以收集顯示參數; 總量計算模組,用以根據顯示參數計算出可顯示的資料總 量; 資料讀取模組,用以從資料區讀取待顯示資料; 貧料分離板組’用以將该謂取的待顯不貢料分離為8個貢 料通道的獨立值;及 資料顯示模組,用以將該每個通道的獨立值轉換為數位波 形。 8、 如申請專利範圍第7項所述之資料訊號的波形顯示系 統,其中該顯示參數包括:顯示器的當前解析度以及用戶 設定的圖形/資料顯示比例。 9、 如申請專利範圍第7項所述之資料訊號的波形顯示系 統,其中更包括一訊號採集裝置,包括: 一通訊埠介面裝置,用於連接待測硬體並傳輸測試資料;Page 16 1227856 VI. Patent application scope Store the collected data into the memory space allocated by the kernel until it is full; restore the multi-thread switching function of the operating system; transfer the collected data from the memory space allocated by the kernel Data storage benefits, and free up memory space allocated by the kernel. 6. The waveform display method of the data signal as described in item 5 of the scope of patent application, wherein the step of the multi-thread switching function of the mask / recovery operating system is realized by shutting down / restarting the system interrupt. 7. A waveform display system for data signals, which is used to display the collected data signals through a computer monitor. The system includes: a parameter collection module to collect display parameters; a total amount calculation module to use the display parameters Calculate the total amount of data that can be displayed; The data reading module is used to read the data to be displayed from the data area; the lean material separation board group is used to separate the pre-displayed materials into 8 tribute materials. Independent values of channels; and a data display module for converting the independent values of each channel into a digital waveform. 8. The waveform display system of the data signal as described in item 7 of the scope of patent application, wherein the display parameters include the current resolution of the display and the graphic / data display ratio set by the user. 9. The waveform display system of the data signal as described in item 7 of the scope of patent application, which further includes a signal acquisition device, including: a communication port interface device for connecting the hardware under test and transmitting test data; 第17頁 1227856 六、申請專利範圍 -遮罩控制模 換功能; 酉己置 一採集 -儲存 10、如 統,其 存採集 組。 1 1、如 統,其 於通訊 訊號端 1 2、如 統’其 匹配待 模組, 模組, 模組, 申請專 中該訊 到的資 申請專 中該通 埠的資 相連。 申請專 中該通 測硬體 用於設置 用於根據 用於儲存 利範圍第 號採集裝 料並在該 利範圍第 訊埠介面 料線與地 利範圍第 訊埠介面 的輸出電 組,用於遮罩或恢復作業系統的多執行緒切 資料獲取量以及採集觸發條件; 採集觸發條件採集資料;及 由該採集模組採集到的資料。 9項所述之資料訊號的波形顯示系 置更包括一暫存模組,用於臨時儲 遮罩恢復後將貪料轉存入該存儲模 9項所述之資料訊號的波形顯示系 裝置包括一訊號傳輸線,一端連接 線,另一端與待測硬體系統的相應 9項所述之資料訊號的波形顯示系 裝置還包括一電壓轉換電路,用於 壓與通訊埠的外部輸入電壓.◦ 〇Page 17 1227856 VI. Scope of patent application-mask control module conversion function; 酉 have set up a collection-storage 10. If the system, it stores the collection group. 1 1. If the system, it is at the communication signal terminal 1 2. If the system ’s, it matches the module, module, and module to be applied for the information of the application. The general test hardware used in the application school is used to set the output power set for collecting and loading materials according to the number of storage areas and the interface between the fabric line of the area and the interface of the area. Cover or recover the multi-threaded data acquisition and recovery trigger conditions of the operating system; collect trigger conditions to collect data; and data collected by the acquisition module. The waveform display system of the data signal described in item 9 further includes a temporary storage module for transferring temporary data into the storage module after the recovery of the temporary storage mask. The waveform display system of the data signal described in item 9 includes: A signal transmission line, one end of the connection line, and the other end of the waveform display system of the data signal described in the corresponding 9 items of the hardware system under test also include a voltage conversion circuit for voltage and external input voltage of the communication port. ◦ 〇 第18頁Page 18
TW92118327A 2003-07-04 2003-07-04 System for displaying waveforms of data signals and method thereof TWI227856B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW92118327A TWI227856B (en) 2003-07-04 2003-07-04 System for displaying waveforms of data signals and method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW92118327A TWI227856B (en) 2003-07-04 2003-07-04 System for displaying waveforms of data signals and method thereof

Publications (2)

Publication Number Publication Date
TW200502853A TW200502853A (en) 2005-01-16
TWI227856B true TWI227856B (en) 2005-02-11

Family

ID=35667164

Family Applications (1)

Application Number Title Priority Date Filing Date
TW92118327A TWI227856B (en) 2003-07-04 2003-07-04 System for displaying waveforms of data signals and method thereof

Country Status (1)

Country Link
TW (1) TWI227856B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI493860B (en) * 2011-01-18 2015-07-21 Hon Hai Prec Ind Co Ltd Waveform/data converter

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI493860B (en) * 2011-01-18 2015-07-21 Hon Hai Prec Ind Co Ltd Waveform/data converter

Also Published As

Publication number Publication date
TW200502853A (en) 2005-01-16

Similar Documents

Publication Publication Date Title
CN108009065B (en) Method and apparatus for monitoring AXI bus
CN107133011B (en) Multichannel data storage method of oscillograph
CN110109853B (en) Data acquisition and processing device and method
US9639447B2 (en) Trace data export to remote memory using remotely generated reads
US9684583B2 (en) Trace data export to remote memory using memory mapped write transactions
WO2012171304A1 (en) Tty test method and system of mobile terminal
TWI278636B (en) Integrated circuit, diagnostic device for receiving diagnostic data in integrated circuit and method for generating diagnostic data
US20090070502A1 (en) Data Modification Module
TWI452465B (en) Method of arranging and processing the electronic measuring device and its tandem parallel data
CN103399830A (en) Equipment and method for reading computer physical memory through PCI Express bus
US6484273B1 (en) Integrated EJTAG external bus interface
TW201423413A (en) Apparatus and method for monitoring signals transmitted in bus
CN100385787C (en) DSP Chip-based excitation controller communication system and its method for realizing USB protocol
JP7252830B2 (en) test equipment
TWI604303B (en) Inout/output expander chip and verification method therefor
CN104485962A (en) Portable data acquisition system and acquisition method thereof
TW201424295A (en) Apparatus and method for monitoring signals transmitted in bus
JP2020193900A (en) Test device
TWI227856B (en) System for displaying waveforms of data signals and method thereof
US11882038B2 (en) Transaction analyzer for communication bus traffic
CN107144751B (en) Multi-channel vector network parameter analysis system and method
WO2004083879A1 (en) Test device and setting method
CN115687012A (en) Bus monitoring module, monitoring method and related equipment
JP7316818B2 (en) Waveform data acquisition module and test equipment
CN101625704B (en) Analog signal data compression processor