TW452698B - Serial communication method for data - Google Patents

Serial communication method for data Download PDF

Info

Publication number
TW452698B
TW452698B TW87117654A TW87117654A TW452698B TW 452698 B TW452698 B TW 452698B TW 87117654 A TW87117654 A TW 87117654A TW 87117654 A TW87117654 A TW 87117654A TW 452698 B TW452698 B TW 452698B
Authority
TW
Taiwan
Prior art keywords
data
communication
signal line
signal lines
pair
Prior art date
Application number
TW87117654A
Other languages
Chinese (zh)
Inventor
Yu-Chuan Chang
Kingboard Ma
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 TW87117654A priority Critical patent/TW452698B/en
Application granted granted Critical
Publication of TW452698B publication Critical patent/TW452698B/en

Links

Landscapes

  • Communication Control (AREA)

Abstract

The present invention relates to a serial communication method for data that can automatically selects any two unidirectional transmission signal lines in a transmission medium (such as serial port and parallel port) as the data transmission channels. A pair of available signal lines are first selected from the current transmission medium, by means of serial transmission, before data transmission and reception can be carried out. Then, not only data transmission will not be constrained by the hardware communication protocol standards of the transmission medium but also operation will not be affected even when some transmission signal lines are defected.

Description

45269 8 _案號87117654_年月 日 鉻π: 五、發明說明(1) 【發明的應用範圍】 本發明係有關一種資料奉列通訊的方法,特別是一種 不受限於硬體之限制’能於任何硬體協議的通訊環境中, 自動決定任兩條信號線’即可達成資料傳輸的串列通訊方 法0 【發明背景】 目前串列通訊大多採用RS-232 /422等標準,使用時 必須透過符合協議標準的硬體’才能作資料的發送與接收 ,rfrj且在 列或是並 傳輪功能 數據的接 通訊埠中 接收)的 而且無法 此外,在 線只能作 標準下, ’很容易 無法找出 【發明欲 現行的硬體 列的通訊埠 ,例如:串 收’第三條 的任何一條 資料不正確 措由別的信 進行並列i阜 單向的傳輪 在產品的滴J 因測試程序 異常的信號 解決之問題 結構與相應的 ,其内的每條 列埠(COM ) 信號線只用於 信號線發生故 ,甚至整個資 號線來替代原 的功能測試時 ,所以若依現 試中並無法得 的遺漏,或是 線,而造成使 的第二條 數據的發 障時,不 料的通訊 信號線所 ,因並列 行並列埠 知那4b传 t 〇 測試資料 用者的不 下,益 只具有 信號線 送。所 單是所 也隨之 負責的 埠上很 之通訊 號線是 設計的 便。 論是串 固定的 只用於 以一旦 發送( 中斷, 功能。 多信號 協議的 正常的 不當, 因此’就目前的 可以雙向傳輸的信號 ’只能適用於既定的 串列資料傳輸協議的標準而言,需要 線,及相匹配之硬體連接結構的支持 通訊模式,以固定的硬體連結關係進45269 8 _ Case No. 87117654_ Year Cr π: V. Description of the invention (1) [Scope of application of the invention] The present invention relates to a method of data communication, especially a method that is not limited by hardware. ' In any hardware protocol communication environment, it can automatically determine any two signal lines to achieve data transmission. 0 [Background of the Invention] Currently, most serial communication uses standards such as RS-232 / 422. Data must be transmitted and received through hardware that conforms to the protocol standard. Rfrj can be received in the serial or parallel port of the port for data transmission) and cannot be used online. In addition, it can only be used as a standard online. Can't find out the current hardware communication port of the invention. For example, "Serial collection" of any of the third data is incorrect. Use another letter to perform parallel testing. The structure of the problem of the abnormal signal solution is corresponding, and each of the COM signal lines is only used for signal line failures, and even the entire data line replaces the original function. At the time of the test, if the omission or line that is not available in the current test causes the second data to fail, the unexpected communication signal line is located parallel to the port to know that 4b is transmitted t 〇 The users of the test data can not fail, and Yi only has a signal line to send. Therefore, the communication line on the port is also designed to be very convenient. The theory is that the string is only used to send once (interrupt, function. The normal improperness of the multi-signal protocol, so 'the current signals that can be transmitted in both directions' can only be applied to the established standard of serial data transmission protocols , Supports communication mode that requires wires and matching hardware connection structure, and advances with a fixed hardware connection relationship.

4526㈣ 案號 87117654 五、發明說明(2)4526㈣ Case number 87117654 V. Description of the invention (2)

行訊息的傳遞,缺乏通用性和 況下,便不能正常的傳輪資料 用信號線之間的自動篩選出未 的發送與接收。 鼓活性,在信蜣線損壞的情 ’更不可能藉由在多根可使 有損壞的信號線,進行信號 【發明之概述】 本發明之主要目的在於提供一種不須架構專屬硬體, 可於現有的通訊硬體架構中,自動跳過短路、斷路的信號 線不用,僅藉由兩條單向的信號線,不會受現有之通訊硬 體架構的連結關係制肘,仍然進行資料傳輸的一種資料通 訊方法。 根據本發明所揭露之技術,係藉由分次讀取在所有的 輸出彳§號線置於高電位和低電位時,輸入信號線的兩次電 位狀態’並配合邏輯上之或(〇R )的演算方法,篩選出可 用的成對信號線,捨去輸出信號線與輸入信號線短路的信 號線對’以保証資料的輸入不受資料的輸出干擾。在進行 貧料的串列發送/接收時,係將欲傳遞的資料位元组,包 裝成一資料封包,自發送端經輸出信號線將資料封包送出 ’同時並在接收端產生同步脈衝,以檢測傳輸過程中之資 料封包是否正確,並且藉由資料封包中的檢驗位元來檢查 7接收到之資料封包的内容是否與發送端所送出的資料相 付;所以,即使是傳統之通訊硬體架構(如:串列埠、並 歹J阜)中的k號線損壞到僅存兩條為正常,透過上述之方 法亦可將資料自發送端完整地送至接收端。 有關本發明之詳細内容及技術’茲就配合圖式說明如In the absence of universality and transmission of information, it is impossible to transfer information normally. Automatically screen out the unsent transmission and reception by using signal lines. Drum activity, when the signal line is damaged, it is even more impossible to signal by using multiple signal lines that can cause damage. [Summary of the Invention] The main purpose of the present invention is to provide a hardware that does not require exclusive architecture. In the existing communication hardware architecture, the short-circuit and open-circuit signal lines are not used automatically. Only two unidirectional signal lines are used, and data transmission is still not carried out due to the connection relationship of the existing communication hardware architecture. A data communication method. According to the technology disclosed in the present invention, when all the output lines are placed at high and low potentials, the potential state of the input signal line is doubled and logically ORed. ) 'S calculation method, screen out the available paired signal lines, and discard the signal line pairs where the output signal line and the input signal line are short-circuited to ensure that the input of the data is not disturbed by the output of the data. When performing lean serial transmission / reception, the data bytes to be transmitted are packaged into a data packet, and the data packet is sent from the transmitting end via the output signal line. At the same time, a synchronization pulse is generated at the receiving end to detect The data packet during transmission is correct, and the check bit in the data packet is used to check whether the content of the received data packet is compatible with the data sent by the sender; therefore, even the traditional communication hardware architecture (Such as: serial port, parallel Jfu) line k is damaged to only two is normal, through the above method can also completely send data from the sender to the receiver. The detailed content and technology of the present invention are described with reference to the drawings such as

第5頁 45269 8 _案號87117654_年月曰 修正_ 五、發明說明(3) 下: 【發明之詳細說明】 如「第1圖」所示,根據本發明所揭露之通訊硬體架 構’包括有:一具有一第一通訊埠1 〇 1的發送端1 〇 ; 及一具有第二通訊埠1 1 1的接收端1 1 ;並以一具有九 條信號線之通訊匯流排1 2,作為發送端1 0與接收端1 1的通訊路徑;其中通訊匯流排1 2的一端係與第一通訊 埠1 0 1連接,另一端則是連接於第二通訊埠1 1 1 ;而 在通訊匯流排1 2中第一、第三、第四及第七信號線(1 21 、123、124、127)為自發送端10傳送資 料至接收端1 1的輸出信號線;第二、第六、第八及第九 信號線(1 2 2、1 2 6、1 2 8、1 2 9 )為發送端1 0接收來自接收端1 1所送來之資料的輸入信號線;第五 信號線1 2 5則為前述各信號線的共同接地線(即電位參 考線)。Page 5 45269 8 _Case No. 87117654_ Year and month amendment_ V. Description of the invention (3) Next: [Detailed description of the invention] As shown in "Figure 1", the communication hardware architecture disclosed by the present invention ' It includes: a sending end 1 0 having a first communication port 1 01; and a receiving end 1 1 having a second communication port 1 11 1; and a communication bus 12 having nine signal lines 12, As a communication path between the transmitting end 10 and the receiving end 11; one end of the communication bus 12 is connected to the first communication port 101, and the other end is connected to the second communication port 1 1 1; The first, third, fourth and seventh signal lines (1 21, 123, 124, 127) in the bus 12 are output signal lines for transmitting data from the transmitting end 10 to the receiving end 1; the second, sixth The eighth and ninth signal lines (1 2 2, 1 2 6, 1, 2 8, 1 2 9) are input signal lines for the transmitting end 10 to receive data from the receiving end 11; the fifth signal line 1 2 5 is the common ground line (ie, potential reference line) of each of the aforementioned signal lines.

第6頁 45269 8 _案號 87117654_年月日_修正_ 五、發明說明(4) 【實施例一】信號線功能的測試步驟 為了使接收端1 1能完整接收到自發送端所傳來的資 料,在尚未開始傳輸資料前,本發明須先對通訊匯流排1 2中的各信號線進行性能的測試,以在通訊匯流排1 2中 找出可使用之工作性能正常的單向信號線,請參閱「第2 圖」為本發明之信號線測試流程圖,其測試步驟依序為: 步驟1 A :進入信號線測試模式; 步驟1 B :先將使用之通訊埠中的所有輸出信號線( 121、123、124、127)置於 商電位; 步驟1C :讀取目前輸入信號線(122、126、 1 2 8、1 2 9 )的狀態,並將之記錄於 暫存器A (圖中並未揭示)中; 步驟1 D :重新將輸出信號線(1 2 1 、1 2 3、1 24、127)置於低電位; 步驟1 E :讀取目前輸入信號線(1 2 2、1 2 6、 1 2 8、1 2 9 )的狀態,並將之記錄於 暫存器B(圖中並未揭示)中; 步驟1F :比較讀取暫存器A與暫存器B中之前後兩 次讀取輸入信號線(1 2 2、1 2 6、1 28、129)的結果,並逐一把讀取自 同一條輸入信號線的狀態結果以邏輯之或 (OR )的演算方法,倘若經演算所得之結 果為高電位(H i g h ),則表示此一輸入信Page 6 45269 8 _Case No. 87117654_Year_Month_Revision_ V. Description of the Invention (4) [Example 1] The test steps of the signal line function are to enable the receiving end 1 to 1 to completely receive the transmission from the sending end Before transmitting data, the present invention must first perform a performance test on each signal line in the communication bus 12 to find a usable one-way signal with normal working performance in the communication bus 12 Please refer to "Figure 2" for the signal line test flow chart of the present invention. The test steps are as follows: Step 1 A: Enter the signal line test mode; Step 1 B: All the outputs in the communication port used first The signal lines (121, 123, 124, 127) are placed at the quotient potential; Step 1C: Read the current state of the input signal lines (122, 126, 1 2 8, 1 2 9) and record them in the register A (Not shown in the figure); Step 1 D: Set the output signal lines (1 2 1, 1 2 3, 1 24, 127) to low potential again; Step 1 E: Read the current input signal line (1 2 2, 1 2 6, 1 2 8, 1 2 9), and record them in register B (not shown in the figure) Step 1F: Compare the results of reading the input signal line (1 2 2, 1 2 6, 1, 28, 129) two times before and after reading in register A and register B, and read from the same one by one The state result of the input signal line is calculated by logical OR (OR). If the calculated result is high potential (H igh), then this input signal is indicated.

號線與輪出信號線短路, 生短路的輪入信號線與2演算後[將發 掉不用; 勒出k破線短路去 步驟1 G :結束信號線測試。The number line is short-circuited with the round-out signal line. After the short-circuited round-in signal line is calculated with 2 [it will be sent and not used; pull out k to break the line and go to short. Step 1 G: End the signal line test.

. 上述之邏輯或(OR)演算法,其中〇R inclusive OR,是一種-推私$站从 又稱為 定禋—進位系統的邏輯遝| ^ ^ 運异兀有一個為一時,其結果為一,否運t子,當兩個 有在兩個運算元都是零(False)時,其择結果為零。它只 本發明便是利用此種邏輯運算檢知任二=果,會為零》而 發^短路(short) ?本發明在測試的過程^號線彼此是否 的k號線(包含一條輸出信號線與一條 ,對於任—對 們僅會先後改變自輸出信號線發出的邏.信號線),我 次的測試過程將發出兩次的邏輯電位信號,信號(在一 邏輯彳S號h 1 gh,另一次則為低電位邏輯作 —人為高電位 在輸入信號線中加上任何的邏輯電位信^ | 〇w),但不會 因此、在正常沒有短路的情形之下,; 線發出的兩次邏輯電位信號,均不會自輪出信號 (因彼此沒有短路),所以先後兩次自輪=信號線 .輯電位信號均應相同而不會有任何的改變得的邏 "(1 " Π η IV、,' 士 T , L 且 Θ 為 延兩。人輪入的邏輯電位信號經〇R邏輯 果為(即為低電位Low)。其信號對應值如真:結 所示。 呆9 A圖」 反之、在任一對信號線彼此發生短路時, 信號線發出的兩次邏輯電位信號,均會傳遞至輪 &因彼此短路)’所以先後兩次自輸入信號線取得的邏輯電. The above logical OR algorithm, where 〇R inclusive OR, is a kind of-push private $ site slave also known as the fixed-carry system logic 遝 | ^ ^ There is a temporary difference, the result is First, whether or not t is a child, when the two operands are both zero (False), the result of the selection is zero. It is only the present invention that uses this kind of logical operation to detect any two = results, it will be zero ^ short circuit? In the process of the test of the present invention, whether the ^ lines are k lines (including an output signal) There is one line and one pair. For any-pairs, they will only change the logic. Signal line sent from the output signal line. The test process will send out the logic potential signal twice. The signal (in a logic 彳 S number h 1 gh , Another time for low-potential logic operation-artificially high potential adds any logic potential signal to the input signal line ^ | 〇w), but will not therefore, under normal circumstances without short circuit; The secondary logic potential signals will not be self-reporting signals (because there is no short circuit with each other), so the two rounds = the signal line. The potential signals should be the same without any changed logic. "(1 " Π η IV ,, ′ T, L and Θ are extended by two. The logic potential signal of the human turn is the logical result of OR (that is, the low potential Low). The corresponding value of the signal is as follows: 9 A "Conversely, when any pair of signal lines short-circuited with each other, Line two logic level signal sent are passed to the wheel & due to short circuit to each other) 'since it is twice the input logic signal lines obtained

45269 8 _案號87117654_年月曰 修正_ 五、發明說明(6) 位信號將會不同,且分別為"Γ (high)與” (Γ (low),這兩 次取自輸入信號線的邏輯電位信號經OR邏輯運算的結果則 為11 Γ'(即為高電位H i g h)。其信號對應值如「第9 B圖」所 示。 為了便於下文的說明,今假設經由上述的測試後,第 一信號線1 2 1與第二信號線1 2 2為正常的信號線,並 在以後的說明中將第一信號線1 2 1稱為輸出信號線,第 二信號線1 2 2稱為輸入信號線。同時請參閱「第3圖」 ,為本發明中用以進行串列傳輸之資料封包的結構示意圖 ,係由一起始位元1 3 1 、一資料位元組1 3 2、以及一 檢驗位元1 3 3組成一資料封包1 3 ,其中起始位元1 3 1係為一低電位,資料位元組又包含有DO〜D7八個資料位 元,檢驗位元1 3 3則是可採奇同位或偶同位的檢查法, 在傳輸時是由起始位元1 3 1開始傳送,再傳資料位元的 最低有效位(LSB ),逐一將資料封包1 3的每一位元自 發送端傳送至接收端。 【實施例二】發送資料封包的步驟 「第4圖」所示,為本發明之發送資料封包1 3的流 •程圖,有關資料封包1 3自發送端1 0發送的步驟依序為 步驟2 A ‘·準備發送資料封包1 3 ; 步驟2 B :檢查所有的信號線,其方法如「第2圖」 所示,並找出可用的輸入信號線及輸出信 號線;45269 8 _Case No. 87117654_ Year and month revision_ V. Description of the invention (6) Bit signals will be different and are " Γ (high) and "(Γ (low), these two times are taken from the input signal line The result of OR logic operation on the logic potential signal is 11 Γ ′ (that is, high potential H igh). The corresponding value of the signal is shown in “Figure 9 B”. For the convenience of the following description, it is assumed that the above test is passed. Thereafter, the first signal line 1 2 1 and the second signal line 1 2 2 are normal signal lines, and in the following description, the first signal line 1 2 1 is referred to as an output signal line, and the second signal line 1 2 2 It is called an input signal line. Please also refer to "Figure 3", which is a structural diagram of a data packet used for serial transmission in the present invention, which consists of a start bit 1 3 1 and a data bit 1 3 2 And a check bit 1 3 3 to form a data packet 1 3, where the start bit 1 3 1 is a low potential, the data bit group also contains eight data bits DO to D7, and the check bit 1 3 3 is the check method that can adopt odd parity or even parity. When transmitting, it starts from the start bit 1 3 1 and then transmits the data. The least significant bit (LSB) of each element is transmitted from the sending end to the receiving end of each bit of the data packet one by one. [Embodiment 2] The step "Figure 4" of sending a data packet is shown in the present invention. Flow chart of sending data packet 1 3, the steps for sending data packet 1 3 from sender 10 are sequentially step 2 A '· ready to send data packet 1 3; step 2 B: check all signal lines, which The method is shown in "Figure 2", and find the available input signal lines and output signal lines;

4 52 69 8 _案號87117654_年月曰 修正_ 五、發明說明(7) 步驟2 C :發送端1 〇等待輸入信號線是否為持續兩 個時間週期的低電位,以使發送端1 〇知 道接收端1 1已準備就緒,可以開傳送資 料封包13; 步驟2 D :發送欲傳送之資料封包1 3的起始位元1 3 1; 步驟2 E :檢查起始位元1 3 1的發送是否成功(註 一),若為是執行2F ,若為否則回至步 驟2 C ; 步驟2 F :準備自資料位元DO開始發送資料位元組1 3 2; 步驟2 G :發送當前的資料位元; 步驟2 Η :檢查當前發送的資料位元是否發送成功( 註一),若為是執行2 I ,若為否則回至 步驟2 C ; 步驟2 I :判斷是否已發送完所有的資料位元,若為 是執行2 J ,若為否則回至步驟2 G ; 步驟2J :發送檢驗位元133; 步驟2Κ :檢查檢驗位元1 3 3的發送是否成功(註 一),若為是執行2 L ,若為否則回至步 驟2 C ; 步驟2 L :結束資料封包的發送。 註一:檢查發送(或接收)是否成功的方式是根據「 第6圖」所示的方式進行,如圖所示,無論是在輸出信號4 52 69 8 _Case No. 87117654_ Year and month amendment_ V. Description of the invention (7) Step 2 C: The sender 1 〇 wait for the input signal line to be a low potential for two time periods to make the sender 1 〇 Knowing that the receiving end 1 1 is ready, you can open the data packet 13; Step 2 D: Send the start bit 1 3 1 of the data packet 1 3 to be transmitted; Step 2 E: Check the start bit 1 3 1 Whether the transmission was successful (Note 1), if it is 2F, if not, go back to step 2C; Step 2F: prepare to start sending data bytes 1 2 from the data bit DO; step 2 G: send the current Data bit; Step 2 Η: Check whether the currently sent data bit is successfully transmitted (Note 1), if it is 2I, if not, go back to Step 2C; Step 2I: Determine whether all the data bits have been sent Data bit, if it is 2 J, if not, go back to step 2 G; Step 2J: Send check bit 133; Step 2K: Check whether the check bit 1 3 3 is sent successfully (Note 1), if it is If yes, execute 2 L. If not, go back to step 2 C; Step 2 L: End the sending of the data packet. Note 1: The way to check whether sending (or receiving) is successful is according to the method shown in "Figure 6", as shown in the figure, whether it is in the output signal

第ίο頁 4 52 69 8 _案號87117654_年月日__ 五、發明說明(8) 線1 2 1 (用以傳送發送端1 〇之資料封包),或是輸入 信號線1 2 2 (用以傳送接收端1 1發送之同步脈衝1 4 )上傳輸的訊息,其在每一個時間週期内正常的資料信號 均會有兩個電位狀態,一為高電位,另一為低電位,例如 :在時間週期10時,在輸出信號線1 2 1上的資料信號為 高電位—低電位,在輸入信號線1 2 2上的資料信號為高 電位—低電位,這表示所傳的資料信號為十六進制的π 1 M :又,當輸出信號線1 2 1上的資料信號變化為低電位— 高電位,在輸入信號線1 2 2上的同步脈衝1 4變化為高 電位—低電位,則表示所傳的資料信號為十六進制的"0" (如「第6圖」中的時間週期t 1 ),但是若在間週期 内輸出信號線1 2 1上的資料信號均為低電位或是高電位 的話,就表示發送(或接收)的資料是錯誤的(如「第6 圊」中的時間週期t 2和時間週期t 3 )。 【實施例三】接收資料封包的步驟 「第5圖」所示,為本發明之接收資料封包1 3的流 程圖,有關接收端1 1接收資料封包1 3的步驟依序為: 步驟3 A :準備接收資料封包1 3 ; 步驟3 B :檢查所有的信號線,其方法如「第2圖」 所示,並找出可用的輸入信號線及輸出信 號線; 步驟3 C :發送端1 0等待輸出信號線是否為持續兩 個時間週期的低電位,以使接收端1 1知 道發送端1 0已準備就緒,欲接收資料封Page 4 52 69 8 _Case No. 87117654_Year Month Day__ V. Description of the invention (8) Line 1 2 1 (used to transmit the data packet of the sender 10), or input signal line 1 2 2 ( It is used to transmit the information transmitted on the synchronization pulse 14 sent by the receiving end 11, and the normal data signal in each time period will have two potential states, one is high potential and the other is low potential, for example : At time period 10, the data signal on the output signal line 1 2 1 is high potential-low potential, and the data signal on the input signal line 1 2 2 is high potential-low potential, which indicates the transmitted data signal Π 1 M in hexadecimal: again, when the data signal on the output signal line 1 2 1 changes to low potential-high potential, the synchronization pulse 14 on the input signal line 1 2 2 changes to high potential-low Potential, it means that the transmitted data signal is hexadecimal " 0 " (such as the time period t 1 in "Figure 6"), but if the data signal on the signal line 1 2 1 is output during the interval If both are low or high, it means that the data sent (or received) is wrong (such as The time period t 2 and the time period t 3 in the "6th frame". [Embodiment 3] The step "Figure 5" of receiving a data packet is a flowchart of receiving a data packet 13 according to the present invention. The steps for receiving data packet 1 3 at the receiving end 11 are as follows: Step 3 A : Ready to receive data packet 1 3; Step 3 B: Check all signal lines, the method is as shown in "Figure 2", and find available input signal lines and output signal lines; Step 3 C: sender 1 0 Wait for the output signal line to be at a low potential for two time periods, so that the receiving end 1 1 knows that the transmitting end 10 is ready to receive data packets.

第11頁 ^52638 _案號87117654_年月曰 修正_ 五、發明說明(9) 包1 3 ; 步驟3 D :接收欲傳來之資料封包1 3的起始位元1 3 1; 步驟3 E :檢查起始位元1 3 1的接收是否成功(註 一),若為是執行3 F ,若為否則回至步 驟3 C ; 步驟3 F :準備自資料位元DO開始接收資料位元组1 3 2; 步驟3 G :接收當前傳來的資料位元; 步驟3 Η :檢查當前接數的資料位元是否接收成功( 註一),若為是執行31 ,若為否則回至 步驟3 C ; 步驟3 I :判斷是否已接收完所有的資料位元,若為 是執行3 J ,若為否則回至步驟3 G ; 步驟3 J :接收檢驗位元1 3 3 ; 步驟3 Κ :檢查檢驗位元1 3 3的接收是否成功,若 為是執行3 L ,若為否則回至步驟3 C ; 步驟3 L :檢查檢驗位元1 3 3是否正確(註一),Page 11 ^ 52638 _Case No. 87117654_ Year and month amendment_ V. Description of the invention (9) Packet 1 3; Step 3 D: Receive the data packet 1 3 starting bit 1 3 1; Step 3 E: Check whether the reception of the start bit 1 3 1 is successful (Note 1), if it is 3 F, if not, go back to step 3 C; Step 3 F: prepare to start receiving data bits from the data bit DO Group 1 3 2; Step 3 G: Receive the current data bit; Step 3 Η: Check whether the current data bit is successfully received (Note 1), if yes, go to 31, if not, go back to step 3 C; Step 3 I: Determine whether all data bits have been received. If yes, execute 3 J, if not, go back to Step 3 G; Step 3 J: Receive check bits 1 3 3; Step 3 Κ: Check whether the reception of check bits 1 3 3 is successful. If yes, execute 3 L. If not, go back to step 3 C; Step 3 L: Check whether the check bits 1 3 3 are correct (Note 1).

- 若為是執行3 Μ,若為否則回至步驟3 C > 步驟3 Μ :結束資料封包的接收。 請參閱「第7圖」,為本發明發送資料為正常之實施 例圖,資料封包1 3中係包括有十六進制為Μ 8 7 "的資料 位元組,首先係是先使輸出信號線1 2 1與輸入信號線1-If yes, execute 3M, if not, go back to Step 3 C > Step 3M: End the reception of the data packet. Please refer to "Figure 7", which is a diagram of a normal embodiment of sending data according to the present invention. The data packet 13 includes data bytes in hexadecimal M 8 7 " Signal line 1 2 1 and input signal line 1

第12頁 45269 0 _案號87117654_年月 曰 修正_ 五、發明說明(10) 2 2在時間週期t 〇 、t 1同時有持續兩個時間週期的低電 位,然後由發送端1 〇和接收端1 1同時送出資料封包1 3及同步脈衝,當接收端在收到發送端傳來之檢驗位元1 3 3,並確認所收之資料封包與資料位元組無誤後,便結 束此次的資料傳送;請參閱「第8圖」,為本發明發送資 料有錯誤時之實施例的示意圖,係在時間週期t 5時發生 資料傳輸的錯誤’所以在時間週期t 6、t 7時,立即使輸 出信號線1 2 1與輸入信號線1 2 2產生持續兩個時間週 期的低電位,以重新發送資料封包1 3。 雖然本發明以前述實施例揭露如上,然其並非用以限 定本發明,任何熟習此技藝者,在不脫離本發明之精神和 範圍内,當可作些許之更動與澗飾,因此本發明之保護範 圍當視後附之申請專利範圍所界定者為準。Page 12 45269 0 _Case No. 87117654_ year and month amendment_ V. Description of the invention (10) 2 2 At the time period t 〇, t 1 there are low potentials for two time periods at the same time, and then by the sending end 1 〇 and The receiver 11 sends data packet 1 3 and the synchronization pulse at the same time. When the receiver receives the check bit 1 3 3 from the sender and confirms that the received data packet and data byte are correct, the process ends. Data transmission; please refer to "Figure 8", which is a schematic diagram of the embodiment of the present invention when there is an error in transmitting data, a data transmission error occurred at time period t 5 'so at time periods t 6 and t 7 , Immediately make the output signal line 1 2 1 and the input signal line 1 2 2 generate a low potential for two time periods to resend the data packet 1 3. Although the present invention is disclosed in the foregoing embodiment as above, it is not intended to limit the present invention. Any person skilled in the art can make some changes and decorations without departing from the spirit and scope of the present invention. The scope of protection shall be determined by the scope of the attached patent application.

第13頁 ^^2698 _案號87Π7654_年月曰 修正_ 圖式簡單說明 【圖式簡單說明】 第1圖,為本發明之通訊硬體架構示意圖D 第2圖,為本發明之測試流程圖。 第3圖,為本發明中資料封包的結構示意圖。 第4圖,為本發明之發送資料封包的流程圖。 第5圖,為本發明之接收資料封包的流程圖。 第6圖,為本發明判斷資料正確與否之實施例圖。 第7圖,為本發明發送資料為正常之實施例圖。 第8圖1為本發明發送資料有錯誤時之實施例圖。 第9 A圖,任一對信號線正常沒有發生短路時的測試 信號表。 第9 B圖,任一對信號線發生短路時的測試信號表。 【圖示符號說明】 10 .......發送端 1Q1 · . · ·第一通訊埠 11 接收端 1 1 1 · · · ·第二通訊埠 12 .....通訊匯流排 1 2 1 · . · ·第一信號線 1 2 2 · · * ·第二信號線 1 2 3 · · · ·第三信號線 1 2 4 · * · ·第四信號線 1 2 5 · ·..第五信號線 1 2 6 · _ . ·第六信號線 1 2 7 . · · ·第七信號線 1 2 8 · · · ·第八信號線 1 2 9 · * ··第九信號線 13 ......資料封包 131.....起始位元 1 3 2 · * ··資料位元組 133.....檢驗位元 1 4......同步脈衝Page 13 ^^ 2698 _Case No. 87Π7654_ Year Month Revision _ Brief Description [Schematic Illustration] Figure 1 is a schematic diagram of the communication hardware architecture of the present invention D Figure 2 is a test flow of the present invention Illustration. FIG. 3 is a schematic structural diagram of a data packet in the present invention. FIG. 4 is a flowchart of sending a data packet according to the present invention. FIG. 5 is a flowchart of receiving a data packet according to the present invention. FIG. 6 is a diagram illustrating an embodiment of judging whether the data is correct or not according to the present invention. FIG. 7 is a diagram illustrating an embodiment in which data is sent normally. FIG. 8 is a diagram of an embodiment when there is an error in sending data according to the present invention. Figure 9A, the test signal table when any pair of signal wires is normal and no short circuit occurs. Figure 9B, the test signal table when any pair of signal lines is short-circuited. [Illustration of Symbols] 10 ....... sender 1Q1 · · · · first communication port 11 receiver 1 1 1 · · · · second communication port 12 ..... communication bus 1 2 1 · · · · First signal line 1 2 2 · · * · Second signal line 1 2 3 · · · · Third signal line 1 2 4 · * · · Fourth signal line 1 2 5 · ··· Five signal lines 1 2 6 · _ · · Sixth signal line 1 2 7 · · · Seventh signal line 1 2 8 · · · · Eighth signal line 1 2 9 · * · Ninth signal line 13 .. .... data packet 131 ..... start bit 1 3 2 · * ·· data bit 133 ..... check bit 1 4 ... sync

第14頁Page 14

Claims (1)

452698 _案號87117654_年月曰 修正_ (六、申請專利範圍 1 . 一種資料串列通訊的方法,用以在一通訊路徑中決定 丨 出一對以上的可用信號線,以便在該通訊路徑的兩個 終端之間傳輸資料,其包括: . a ·藉由一檢查手段於該通訊路徑中找出該成對的可 用信號線;以及 b ·在該成對的可用信號線的兩個終端之間傳輸一資 ' 料封包。 2 *如申請專利範第1項所述資料串_列通訊的方法,其中 該成對的可用信號線包括有:一輸出信號線及一輸入 信號線。 3 .如申請專利範第1項所述資料串列通訊的方法,其中 該檢查手段可藉下列之步驟實現: A ·將該通訊路徑之輸出信號線置於高電位; B .讀取該通訊路徑之輸入信號線的狀態; C *將該通訊路徑之輸出信號線置於低電位; D ·讀取該通訊路徑之輸入信號線的狀態;以及 E ·以邏輯之或(OR )的演算法比較分別讀取自該步 驟B與該步驟D之該輸入信號線狀態的結果,找 出該成對的可用信號線。 4 .如申請專利範第1項所述資料串列通訊的方法,其中 該資料封包係由一起始位元、一資料位元組、以及一 檢驗位元所組成。 5 .如申請專利範第4項所述資料串列通訊的方法,其中 該資料位元組係具有多數個待送位元。452698 _Case No. 87117654_ Amendment Month_ (Sixth, the scope of patent application 1. A method of data serial communication, used to determine a pair of available signal lines in a communication path, in order to Data transmission between the two terminals includes: a. Finding the pair of available signal lines in the communication path by a means of inspection; and b. Two terminals of the pair of available signal lines A packet of data is transmitted between the data packets. 2 * The method of data string communication described in item 1 of the patent application, wherein the pair of available signal lines includes: an output signal line and an input signal line. 3 . The method of serial data communication as described in item 1 of the patent application, wherein the checking means can be implemented by the following steps: A · Set the output signal line of the communication path to a high potential; B. Read the communication path The state of the input signal line of the communication path; C * set the output signal line of the communication path to a low potential; D · read the state of the input signal line of the communication path; and E · compare with a logical OR algorithm Minute Read the results of the input signal line status from step B and step D to find the pair of available signal lines. 4. The method of serial data communication as described in item 1 of the patent application, where the data The packet is composed of a start bit, a data byte, and a check bit. 5. The method of data serial communication as described in item 4 of the patent application, wherein the data byte has a plurality of Bits to be sent. 第15頁 ^5269 〇 _案號8Ή17654_年月曰 修正_ 六、申請專利範圍 6 ·如申請專利範第3項所述資料串列通訊的方法,其中 該步驟Ε所找出之該成對的可用信號線,係為在以邏 輯之或(OR )的演算法比較後,結果為非高電位者。 7 . —種資料串列通訊的方法,係在一通訊路徑中決定出 一包含輸入信號與輸出信號的成對信號線,以便在位 於該通訊路徑的兩終端之間進行通訊,其步驟為: a _將該通訊路徑之輸出信號線置於高電位; b _讀取該通訊路徑之輸入信號線的狀態; c ·將該通訊路徑之輸出信號線置於低電位; d ·讀取該通訊路徑之輸入信號線的狀態; e .以邏輯之或(OR )的演算法比較分別讀取自該步 驟b與該步驟d之該通訊埠之輸入信號線狀態的 _結果,找出該對信號線;以及 f _在該對信號線的兩個終端之間傳輸一資料封包。 8 ·如申請專利範第7項所述資料串列通訊的方法,其中 該資料封包係由一起始位元、一資料位元組、以及一 檢驗位元所組成。 9 ·如申請專利範第8項所述資料串列通訊的方法,其中 該資料位元組係具有多數個待送位元。 1 0 ·如申請專利範第7項所述資料串列通訊的方法,其 中該步驟e所找出之該成對的可用信號線,係為在 以邏輯之或(OR )的演算法比較後,結果為非高電 位者。Page 15 ^ 5269 〇_ Case No. 8Ή17654_Year Month Amendment_ VI. Patent Application Range 6 · The method of serial communication of data as described in item 3 of the patent application, where the pair found in step E The available signal lines are those with a non-high potential after a comparison using a logical OR algorithm. 7. A method of serial data communication, in which a pair of signal lines including an input signal and an output signal is determined in a communication path in order to perform communication between two terminals located on the communication path. The steps are: a _ Set the output signal line of the communication path to a high potential; b _ Read the status of the input signal line of the communication path; c · Set the output signal line of the communication path to a low potential; d · Read the communication The state of the input signal line of the path; e. Compare the result of the state of the input signal line of the communication port from step b and step d with a logical OR algorithm to find the pair of signals Line; and f_ transmits a data packet between two terminals of the pair of signal lines. 8. The data serial communication method as described in item 7 of the patent application, wherein the data packet is composed of a start bit, a data byte, and a check bit. 9. The method of serial data communication as described in item 8 of the patent application, wherein the data byte has a plurality of bits to be sent. 10 · The method of serial data communication as described in item 7 of the patent application, wherein the pair of available signal lines found in step e are after a logical OR comparison (OR) algorithm comparison , The result is non-high potential. 第16頁Page 16
TW87117654A 1998-10-26 1998-10-26 Serial communication method for data TW452698B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW87117654A TW452698B (en) 1998-10-26 1998-10-26 Serial communication method for data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW87117654A TW452698B (en) 1998-10-26 1998-10-26 Serial communication method for data

Publications (1)

Publication Number Publication Date
TW452698B true TW452698B (en) 2001-09-01

Family

ID=21631761

Family Applications (1)

Application Number Title Priority Date Filing Date
TW87117654A TW452698B (en) 1998-10-26 1998-10-26 Serial communication method for data

Country Status (1)

Country Link
TW (1) TW452698B (en)

Similar Documents

Publication Publication Date Title
EP0544964B1 (en) Store and forward apparatus and method of maintaining integrity of data during storage
CN108390752A (en) Signal acceptance method
TW201205276A (en) Data transmission detecing device, data transmission detecing method and electronic device thereof
JPH02149051A (en) Method of initiating and synchronizing communication link-interface and receiver for communication link
TW452698B (en) Serial communication method for data
US7668204B2 (en) Port driven authentication in a network
TWI332771B (en) Receiver and test method therefor
EP0093004B1 (en) Data communication system
JPH06204989A (en) Data communication equipment
JPS6362427A (en) Detection system for error of data communication
JP3001414B2 (en) Code error correction device
JP3549702B2 (en) Bus control circuit and test method thereof
JPS60259035A (en) Communication system
JP3137092B2 (en) Data transmission method and transmission / reception device
JPH0244921A (en) Error detecting circuit
JPH04267631A (en) Parity bit addition system
GB2345422A (en) Method for data serial transfer
JPH10164104A (en) Equipment and method for communication
JP3137090B2 (en) Error detection circuit
JPH0637738A (en) Data transmission error control system
JPS6286942A (en) Detecting method for data abnormality
JPH0837541A (en) Data transmission system
JPH10150476A (en) Baud rate generation circuit
JPH0439928B2 (en)
JPH06104875A (en) Serial port

Legal Events

Date Code Title Description
GD4A Issue of patent certificate for granted invention patent
MM4A Annulment or lapse of patent due to non-payment of fees