TW201134145A - Network cable length detection system - Google Patents

Network cable length detection system Download PDF

Info

Publication number
TW201134145A
TW201134145A TW99108464A TW99108464A TW201134145A TW 201134145 A TW201134145 A TW 201134145A TW 99108464 A TW99108464 A TW 99108464A TW 99108464 A TW99108464 A TW 99108464A TW 201134145 A TW201134145 A TW 201134145A
Authority
TW
Taiwan
Prior art keywords
local
remote
microprocessor
network route
signal
Prior art date
Application number
TW99108464A
Other languages
Chinese (zh)
Other versions
TWI488459B (en
Inventor
zi-zheng Lou
Original Assignee
zi-zheng Lou
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 zi-zheng Lou filed Critical zi-zheng Lou
Priority to TW99108464A priority Critical patent/TW201134145A/en
Publication of TW201134145A publication Critical patent/TW201134145A/en
Application granted granted Critical
Publication of TWI488459B publication Critical patent/TWI488459B/zh

Links

Abstract

The present invention relates to a network cable length detection system, including a local end module and a remote module, wherein the local end module can send a measurement signal to a pair of sub-lines of a network cable. The remote module comprises a remote microprocessor, a remote communication circuit and an automatic reflex circuit. The remote communication circuit is connected with the remote microprocessor, and connected with the local end module through the network cable. The automatic reflex circuit is connected between the remote microprocessor and the remote communication circuit, and automatically reflects back the measurement signal to the local end module, allowing the local end module to calculate a length of network cable by detecting the time required for the measurement signal from sending to receiving . Thus, network cable length can be calculated accurately and fast with low cost.

Description

201134145 六、發明f兒明: 【發明所屬之技術領域】 本發明係關於一種網路線線長偵 民冰我1貝凋糸統’尤指一種成 本低廉、電路簡單且測量精準声古 稱+度间的網路線線長偵測系 統。 【先前技術】 在許多電腦及其周邊產品的應用中,使用者通常係使 用鍵盤、滑鼠等輸人裝置操作電腦主機,巾電腦主機則藉 由監視器(即電腦螢幕)或揚聲器等輸出裝置來顯示電腦主 機的狀態,藉此讓使用者與電腦主機之間可順利地互動, 故-般係將鍵盤、滑鼠及監視器通稱為控制台(c〇ns〇|e)。 為因應一些控制台不便裝設在電腦主機旁,導致控制 σ的使用位置無法緊鄰電腦主機安裝的特殊應用,於是有 控制台延伸器(Console Extender)、視訊延伸器(Video Extender)及網路線傳輸的多電腦切換器(KVM Swjtch)等裝 置的出現’這些裝置都是利用網路線,例如五類線 (Cat5/Cat5e)或六類線(Cat6),連接於控制台與電腦主機 之間’藉此利用網路線達到延長控制台與電腦主機之間距 離的效果。 上述技術主要係利用網路線中的四對子線來作為傳遞 鍵盤、滑鼠、監視器及音訊訊號的媒介,其中三對子線用 來處理監視器的訊號(包含RGB、H-Sync及V-Sync訊號), 而另外一對子線則用來處理鍵盤、滑鼠及音訊的訊號。然 因RGB訊號在長距離傳輸的過程中,容易有訊號衰減的 201134145 - 現象發生,故為解決此一問題,目前常見的解決方式即是 預先偵測網路線的線長,以便根據網路線線長推知控制台 與電腦主機的距離,進而推算出訊號的衰減量以補償衰減 的訊號。 既有計算網路線線長的方式,最常見的是自遠端裝置 (在此係指電腦主機端之裝置)將方波訊號疊加於RGB訊號 中後,連同RGB訊號一同送入用以傳遞RGB訊號之三對 子線中的一對子線,當本地端裝置(在此係指控制台延伸 φ 器、視訊延伸器或網路線傳輸的多電腦切換器)接收到疊加 有方波訊號的RGB訊號後,可自其中提取及還原方波訊 號,並將方波訊號輸入一設在本地端裝置的電阻電容(rc) 充放電路,藉由計算RC充放電路的充放電時間來計算網 路線的線長。惟由於利用RC充放電時間計算網路線線長 的方式所能得到的數值解析度有限,故較不精準,且因該 數值非為線性數據’故誤差較大;此外,遠端裝置上所需 設置之計算電路亦十分複雜。 _ 為提尚計算網路線線長的準4度’另一既有計算網路 線線長的方式,係藉由計算高速資料流(data stream)之發 射與回傳時間差,來推算出網路線的線長,其架構請參閱 第七圖所示,係包括一本地端模組(40)及一遠端模組(5〇), 其中:該本地端模組(40)係包括一本地端微處理器(々I)、 一本地端高速資料流收發器(42)及一本地端通信電路 (43),該高速資料流收發器(42)係連接於該本地端微處理 器(41)及該本地端通信電路(43)之間,由該本地端微處理 器(41)控制以透過該本地端通信電路(43)向一網路線(6〇) 201134145 - 出高速資料流,並由該本地端微處理器(41)開始計數資料 流傳輸時間。而該遠端模組(50)係包括一遠端微處理器 (51)、一遠端高速資料流收發器(52)及一遠端通信電路 (53) ’該遠端高速資料流收發器(52)係連接於該遠端微處 理器(51)及該遠端通信電路(53)之間,供自該遠端通信電 路(53)透過網路線(60)接收該本地端模組(40)發出的高速資 料流’並轉傳送至該遠端微處理器(51),經該遠端微處理 器(51)接收並計算後,再發出一高速資料流,透過該遠端 φ 南速資料流收發器(52)、遠端通信電路(53)及網路線(60)傳 送至該本地端模組(40),當該本地端微處理器(41)接收到 自遠端模組(50)回傳之高速資料流時,即停止計數資料流 傳輸時間,並以所得之資料流傳輸時間計算出網路線(6〇) 的線長。惟發射與回傳高速資料流所需之高速資料流收發 器(42)(52)及本地端和遠端微處理器(41 )(51)上所需安裝之 高速資料流收發判斷程式皆需極高的製造成本方能達成, 且遠端微處理器(51)和遠端高速資料流收發器(52)在收到 鲁π速資料流後必須進行軟體的編解碼及判斷程序,導致資 料處理時間延遲,故以高速資料流計算網路線線長的方式 並不普及》 ▲是以,既有計算網路線線長的做法,仍有待進一步檢 討’並謀求可行之改進方案。 【發明内容】201134145 VI. Inventions: The technical field of the invention belongs to the invention. The invention relates to a network route line, long detection, ice, and ice, which is a low cost, simple circuit, and accurate measurement. Inter-network route line length detection system. [Prior Art] In many applications of computers and their peripheral products, users usually use a keyboard, mouse and other input devices to operate the computer mainframe. The computer mainframe uses output devices such as monitors (ie computer screens) or speakers. To display the status of the host computer, so that the user and the host computer can smoothly interact, so the keyboard, mouse and monitor are generally referred to as the console (c〇ns〇|e). In order to accommodate some consoles inconveniently installed next to the host computer, the position of the control σ can not be installed next to the special application installed by the host computer, so there are Console Extender, Video Extender and network route transmission. The emergence of devices such as KVM Swjtch [these devices are all using network routes, such as Category 5 (Cat5/Cat5e) or Category 6 (Cat6), connected between the console and the computer host. This uses the network route to achieve the effect of extending the distance between the console and the host computer. The above technology mainly uses four pairs of sub-lines in the network route as a medium for transmitting keyboards, mice, monitors and audio signals, wherein three pairs of sub-lines are used to process the monitor signals (including RGB, H-Sync and V). -Sync signal), and another pair of sub-lines are used to process keyboard, mouse and audio signals. However, due to the RGB signal transmission in the long distance, it is easy to have signal attenuation 201134145 - phenomenon occurs, so to solve this problem, the current common solution is to pre-detect the line length of the network route, in order to follow the network route line. The distance between the console and the host computer is inferred, and the attenuation of the signal is calculated to compensate for the attenuated signal. There is a way to calculate the length of the route of the network. The most common way is to add the square wave signal to the RGB signal from the remote device (in this case, the device on the host side of the computer), and send it together with the RGB signal to transmit RGB. A pair of sub-lines of the three pairs of signals, when the local device (in this case, the console extension φ, video extender or network switch transmission KVM switch) receives the RGB with the square wave signal superimposed After the signal, the square wave signal can be extracted and restored from the square wave signal, and the square wave signal is input into a resistor-capacitor (rc) charging and discharging circuit of the local device, and the network route is calculated by calculating the charging and discharging time of the RC charging and discharging circuit. The length of the line. However, since the numerical resolution obtained by calculating the route length of the network by using the RC charge and discharge time is limited, it is less accurate, and since the value is not linear data, the error is large; in addition, the remote device requires The calculation circuit of the setup is also very complicated. _ To calculate the quasi-four degrees of the length of the route line of the network. Another way to calculate the length of the route of the network is to calculate the route of the network by calculating the difference between the transmission and the return time of the high-speed data stream. The line length is as shown in the seventh figure. The system includes a local end module (40) and a remote module (5〇). The local end module (40) includes a local end micro. a processor (々I), a local high speed data stream transceiver (42) and a local end communication circuit (43), the high speed data stream transceiver (42) being connected to the local end microprocessor (41) and The local end communication circuit (43) is controlled by the local end microprocessor (41) to transmit a high speed data stream to the network route (6〇) 201134145 through the local end communication circuit (43), and The local-end microprocessor (41) starts counting the data stream transmission time. The remote module (50) includes a remote microprocessor (51), a remote high-speed data stream transceiver (52), and a remote communication circuit (53) 'the remote high-speed data stream transceiver (52) being coupled between the remote microprocessor (51) and the remote communication circuit (53) for receiving the local end module from the remote communication circuit (53) via the network route (60) ( 40) The sent high speed data stream is transmitted to the remote microprocessor (51), and after receiving and calculating by the remote microprocessor (51), a high speed data stream is sent through the remote φ south. The data stream transceiver (52), the remote communication circuit (53) and the network route (60) are transmitted to the local end module (40), and when the local end microprocessor (41) receives the remote module (50) When the high-speed data stream is returned, the data stream transmission time is stopped, and the line length of the network route (6〇) is calculated by using the obtained data stream transmission time. The high-speed data stream transceiver (42) (52) required for transmitting and returning the high-speed data stream and the high-speed data stream receiving and determining program required on the local and remote microprocessors (41) (51) are required. Extremely high manufacturing costs can be achieved, and the remote microprocessor (51) and the remote high-speed data stream transceiver (52) must perform software codec and judgment procedures after receiving the Lu-speed data stream, resulting in data. Processing time delay, so the way to calculate the length of the network route line with high-speed data stream is not popular. ▲ Yes, there is a practice of calculating the route length of the network, and it is still necessary to further review 'and seek feasible improvement programs. [Summary of the Invention]

ί SJ 為改善既有計算網路線線長方式的缺失,本發明之主 要目的在提供-種網路線線㈣測系統,其成本低廉且測 5 201134145 _ 量精準度高。 為達成别述目的所採取之主要技術手段係令前述網路 線線長Y貞測系統包括: 一本地端模組,其可向一網路線中的一對子線發出一 測量訊號; 一遠端模組,係透過該網路線與該本地端模組連接, 並包括一遠端通信電路、一自動反射電路及一遠端微處理 器,其中3亥遠端通信電路係透過網路線連接該本地端模 | 組,該自動反射電路係連接該遠端通信電路,該遠端微處 理器係連接該遠端通信電路和自動反射電路,並儲存且執 仃一反射切換程序,又該遠端微處理器具有一連接該自動 反射電路的模式控制端,當該遠端微處理器執行該反射切 換程序時,該自動反射電路即運作以自動地反射該本地端 模組所發出之測量訊號,而作為一反射訊號經該網路線回 傳予該本地端模組,由該本地端模組藉由偵測測量訊號自 發出至接收所需的時間計算出一網路線長度值。 齡 上述技術手段係計算測量訊號的發出及接收時間,並 將之除以電波傳輸速度(即光速)後再除以2,即可得到網 路線的線長,故無需在網路線所傳輸之訊號再疊加方波訊 號故亦無需设計、安裝用以截取方波訊號的電路,更無 需利用電阻電容(RC)充放電路藉由方波訊號的多寡進行充 電以計算網路線線長,也因此所計算出的數值不會因RC 充放電時所產生的延遲造成誤差;此外,由於本發明之系 統只需使用一般的訊號作為測量訊號即可,而毋須技術成 本較高的高速資料流,且因該自動反射電路係由遠端微處 6 201134145 理器控制,以自動地反射該本地端模組所發出之測量訊 號,故毋須設計複雜的判斷程式供該遠端微處理器執行以 回傳測量訊號,因此可提高計算速度及降低整體成本。 【實施方式】 請參閱第一圖所示’本發明之網路線線長偵測系統係 包括一本地端模組(1 0)及一遠端模組(20)。 上述本地端权組(10)可向一網路線(3 〇),例如五類線 φ (Cat5/Cat5e)或六類線(Cat6)中的一對子線,發出一測量 訊號。凊進一步參閱第二圖所示’較佳地,該本地端模組(1 〇) 係包括: 一本地端微處理器(11 ),係具有一模式控制端 (Μ〇D E1)’並儲存一福測啟動程序;較佳地,該本地端微 處理器(11)係具有通用非同步收發傳輸器(Universa| Asynchronous Receiver/ Transmitter > 簡稱 UART),舉 例而言,當該本地端微處理器(1 1)自該模式控制端(MODE 1) # 輸出一高準位訊號時,該本地端微處理器(1 1)不會執行該 偵測啟動程序,故該本地端微處理器(1 1)可依一般Uart 之運作’在串列傳輸與平行傳輸之間轉換資料,反之若該 本地端微處理器(11)自該模式控制端(M0DE1)輸出一低準 位sfl號時,邊本地端微處理器(1 1)將一同執行該债測啟動 程序; 一主控制器(12),係連接該本地端微處理器(11),並 儲存一線長偵測程序,由該本地端微處理器(1 1)執行該偵 測啟動程序’先發出一線長偵測命令後,再控制該主控制 7 201134145 器(12)執行該線長偵測程序; 一切換器(1 3),係連接該本地端微處理器(彳1)的模式 控制端(MODE1)及該主控制器(12); t Si 一本地端通信電路(14),係連接該網路線(3〇)及該切 換器(13),使s玄本地端微處理器(11)和該主控制器(12)皆透 過該切換器(1 3)連接該本地端通信電路(彳4),當該本地端 微處理器(1 1)執行該偵測啟動程序時,會自該模式控制端 (M0DE1)輸出一低準位訊號予該切換器(13),以切換使該 φ 主控制器(1 2)可透過該本地端通信電路(14)發射一測量訊 號或接收一反射訊號,如該本地端微處理器(彳彳)未執行該 損測啟動程序,則會自該模式控制端(MODE 1)輸出一高準 位訊號予該切換器(1 3 ),以切換使該本地端微處理器(1 <|) 可透過该本地端通信電路(14)發射及接收訊號;較佳地, s玄本地端通信電路(14)係包括一本地端rs_485控制器 (141),其至少具有一對差動輸入輸出端(D〇) (/D〇)、一收 發方向控制端(DE)、一接收輸出端(r〇)及一發射輸入端 •([)丨),其中:該對差動輸入輸出端(〇〇)(/〇〇)係與網路線(30) 連接;該收發方向控制端(DE)係透過該切換器(13)連接該 本地端微處理器(11)和該主控制器(12),並供設定該本地 端RS-485控制器(141)之工作狀態為接收狀態或發送狀 態’當該收發方向控制端(DE)接收到高準位訊號時該本地 端RS-485控制器(141)係呈發送狀態,當該收發方向控制 端(DE)接收到低準位訊號時該本地端rS_485控制器(141) 係呈接收狀態;該接收輸出端(R0)係透過該切換器(1 3)連 接該本地端微處理器(1 1)和該主控制器(12),供傳送經本 8 201134145 地k RS-485控制器(141)轉換之訊號;該發射輸入端(⑴) 係透過該切換器(13)連接該本地端微處理器⑴)和該主控 制益(12),供接收訊號予該本地端RS_485控制器(⑷)轉 換後由s亥對差動輸入輸出端(D〇)(/d〇)發送; -計數器(15) ’係連接該主控制器(12),該計數器(15) 係由該主控制器(12)於發出測量訊號時一同啟動,直至該 主控制(12)接收到反射訊號時才終止該計數器〇 之計 數,藉此叶數一收發時間計數值,並由該主控制器(1 2)通 • 知該本地端微處理器(1 1)自該計數器(15)讀出該收發時間 計數值,而由該本地端微處理器(1彳)據此計算出一網路線 長度值,如此一來,使用本發明之系統的外部裝置即可由 該網路線長度值推算出視訊訊號的衰減量,以補償衰減的 視訊訊號; 其中,S玄主控制器(1 2)、切換器(1 3)及計數器(14)則可 整合於一元件可程式邏輯閘陣列(Field Pr〇grammab|e Gate Array,簡稱FPGA)或複雜可程式邏輯裝置(c〇mp|ex φ Programmable Logic Device > 簡稱 CPLD)中。 上述遠端模組(20)透過該網路線(30)與該本地端模組 (1 0)連接,且該遠端模組(20)可於接收到測量訊號時,將 測量訊號反射回本地端模組(1 〇);又如第三圖所示,該遠 端模組(20)係包括: 一遠端通信電路(21) ’係透過網路線(30)連接該本地 端通信電路(14);較佳地,該遠端通信電路(21)係包括一 遠端RS-485控制器(211),其與該本地端RS-485控制器 (141)的規格相同,其中該對差動輸入輸出端(d〇)(/DO)係 9 201134145 與網路線(30)連接; 一自動反射電路(22),係連接該遠端通信電路(21); 較佳地,該自動反射電路(22)係連接該遠端RS-485控制 器(211)之收發方向控制端(DE)和接收輸出端(RO); 一遠端微處理器(23) ’係連接該遠端通信電路(21)和 自動反射電路(22),並儲存一反射切換程序,又該遠端微 處理器(23)具有一連接該自動反射電路(22)的模式控制端 (MODE2),該遠端微處理器(23)係藉由改變其模式控制端 φ (M0DE2)輸出至該自動反射電路(22)的訊號準位,以控制 該自動反射電路(22)是否運作;較佳地,該遠端微處理器(23) 係連接該遠端RS-485控制器(21 1)之接收輸出端(r〇)及發 射輸入端(DI),又該遠端微處理器(23)之模式控制端 (MODE2)係連接該自動反射電路(22),且該遠端微處理器 (23)亦具有UART,舉例而言,當該遠端微處理器(23)自該 模式控制端(MODE2)輸出一低準位訊號時,該遠端微處理 器(23)不會執行該反射切換程序,故該遠端微處理器(23) • 可依一般UART之運作,在串列傳輸與平行傳輸之間轉換 資料,且該遠端通信電路(21)之遠端RS_485控制器(211) 係依該遠端通信電路(21)輸出、經該自動反射電路(22)傳 送至該遠端RS-485控制器(211)之收發方向控制端(DE)的 讯號準位工作;反之,若該遠端微處理器(23)經由該遠端 通仏電路(21)接收到該本地端微處理器(1彳)所發出的線長 偵而命7並回覆一確過收達訊號時,該遠端微處理器(23) 即執行該反射切換程序並自該模式控制端(m〇de2)輸出一 尚準位訊號,以控制該自動反射電路(22)運作,進而自動 10 201134145 地反射該主控制器(12)所發出之測量訊號作為一反射訊 號,使該反射訊號經由該網路線(30)回傳予該主控制器 (12)。 又如第三圖所示,該自動反射電路(22)係包括: 第反及閘ι(221)’係具有兩輸入端及一輸出端,該 兩輸入端係共同連接該遠端RS-485控制器(211)之接收輸 出端(RO); 一第二反及閘(222),係具有一第一輸入端(222a)、一 φ 第二輸入端(222b)及一輸出端,其中該第一輸入端(222a) 係連接該第一反及閘(221)的輸出端,該第二輸入端(222b) 係連接該遠端微處理器(23); 一二極體(D1)’其陰極係連接該第二反及閘(222)的輸 出端; 一電阻(R6) ’係連接該二極體(D1)的陽極; 一電容(C1) ’係連接該二極體(D1)的陽極及該電阻 (R6); 鲁 一第二反及閘(223) ’係具有兩輸入端及一輸出端,其 中該兩輸入端係共同連接該遠端微處理器(23); 一第四反及閘(224),係具有一第一輸入端(224a) ' 一 第二輸入端(224b)及一輸出端,其中第一輸入端(224a)係 連接該二極體(D1)的陽極、電阻(R6)及電容(C1),該第二 輸入端(224b)係連接該第三反及閘(223)的輸出端,而輸出 端則連接該遠端RS-485控制器(211)之收發方向控制端 (DE)。 請進一步參閱第四圖所示,該本地端微處理器(1 11 201134145 執行之偵測啟動程序係包括下列步驟: 發出一線長偵測命令給遠端模組(4〇 ]); 判斷是否收到遠端模組回傳之一確認收達訊號(4〇2); ^若未收到確認收達訊號,則進一步判斷是否已超過一 衝時間(403) ’若尚未超過緩衝時間則繼續判斷是否收到 一確認收達訊號(4〇2),反之則結束流程; 八右有收到確認收達訊號,則進一步控制切換器切換僅 ^主控制器連接本地端通信電路(4Q4),並控制主控制器執 φ 行線長偵測程序(4〇5〉; 判斷主控制器是否完成線長偵測程序(406),係由主控 制器(12)是否通知可自計數器取得收發時間計數值加以判 斷; 右主控制器(12)已通知通知可自計數器(15)取得收發 時間計數值,則自計數器讀出收發時間計數值(4〇7),並根 據收發時間計數值計算網路線長度值(4〇8);較佳地,該計 f公式為線長(公尺)=[(收發時間計數值* T_c丨〇ck 一 T」c) _ * 〇·3 ] / 2,其中T_clock是計數器(15)的測量頻率單位, T—rC是遠端RS485控制器(211)的反應時間,是一固定值, 如果要求的精度不高日寺,T_「c彳以忽略不言十,舉例而言, 若系統時鐘頻率{ 40MHz,則計數器(15)的最小計數單位 為25ns(十億分之一秒),故電磁波的傳輸速度為 〇〇,〇00,0〇〇公尺(m)’秒(s),即〇3m/ns,因此測量網路 線(3〇)長度之精密度為3.25m ;如果系統時鐘頻率是 1〇〇MtHz,則測量網路線(30)長度之精密度可達彳5m ; 控制切換器切換僅令本地端微處理器連接本地端通信 201134145 電路(409); 若主控制器(12)尚未通知可自計數器(15)取得收發時 間計數值’則進一步判斷是否已超過一延遲時間(41 〇),若 尚未超過延遲時間則繼續判斷主控制器是否通知可自計數 器取得收發時間計數值(4〇6),反之則控制切換器切換僅令 本地端微處理器連接本地端通信電路(4〇9)後結束流程。 請進一步參閱第五圖所示,該本地端模組(1〇)之主控 制器(1 2)所執行的線長偵測程序係包括下列步驟: 設定本地端通信電路為發送狀態(501 ),係對該本地端 RS-485控制器(141)之收發方向控制端(DE)發出一高準位 訊號; 對本地端通信電路發出測量訊號並同時控制計數器開 始計數(502); 設定本地端通信電路為接收狀態(503),係對該本地端 RS-485控制器(141)之收發方向控制端(DE)發出一低準位 訊號; 判斷是否收到與測量訊號相同的反射訊號(5〇4); 若未能收到與測量訊號相同的反射訊號,則進一步判 斷計數器是否已溢位(505),若尚未溢位則繼續判斷是否收 到與測量訊號相同的反射訊號(504),反之則表示網路線(3〇) 長度已超過最大範圍,故以一錯誤預設值作為網路線長度 值(506),並進一步控制計數器停止計數(5〇7); 若已收到與測量訊號相同的反射訊號,則控制計數器 停止計數(507) ’並進一步通知本地端微處理器可自計數器 取得收發時間計數值(508)後結束。 13 201134145 再請進一步參閱第六圖所示,該袁 及通4微處理器(23)所 執行之反射切換程序係包括下列步驟: 流程開始後,即判斷是否收到線長偵測命令(6〇1 ),若 否則結束流程,反之則繼續進行下列步驟; 回覆確認收達訊號(602); 控制自動反射電路運作(603),係自^莫式控制端 (MQDE2)輸出一高準位訊號; 計算運作時間(604),係用以計算該自動反射電路的運 作時間; 判斷自動反射電路運作時間是否超過一預設時間 (605); 如自動反射電路(22)運作時間並未超過預設時間,則 繼續判斷自動反射電路運作時間是否超過一預設時間 (605),反之則控制自動反射電路停止運作(6〇6),係自該 模式控制端(MODE2)輸出一低準位訊號,隨後即結束流 程0 以下謹配合該主控制器(12)所發出之測量訊號為一低 準位訊號舉例,就該自動反射電路(22)之動作加以說明: 1 _當該遠端微處理器(23)收到自本地端模組(1〇)傳來 的線長彳貞測命令並回覆確認收達訊號後,即自該模式控制 端(MODE2)輸出一高準位訊號至該第二反及閘(222)之第二 輸入端(222b),表示該遠端模組(2〇)係進入可自動反射測 量訊號的工作模式’此時,該遠端微處理器(23)並輸出一 低準位訊號至該遠端RS-485控制器(211)之發射輸入端 (DI),至此,該遠端通信電路(21)係呈現等待接收狀態。 201134145 2·當該遠端微處理器(23)收到自本地端模組(10)傳來 之測量訊號(即低準位訊號)的同時,該測量訊號亦輸入該 第一反及閘(221)之兩輸入端,使該第一反及閘(221)之輸 出端係輸出一高準位訊號予該第二反及閘(222)之第一輸入 端(222a),此時配合自該遠端微處理器(23)之模式控制端 (MODE2)輸出至該第二反及閘(222)之第二輸入端(222b)的 高準位訊號’該第二反及閘(222)之輸出端將輸出一低準位 訊號’此時該二極體(D1)將導通,進而使該電容(C1)放電, φ 導致該第四反及閘(224)連接至電容(C1)的第一輸入端 (224a)將取得一低準位訊號,令該第四反及閘(224)之輸出 端必然輸出一高準位訊號予該遠端RS_485控制器(211)之 收發方向控制端(DE),至此將令該遠端通信電路(21)切換 呈發送狀態,由該遠端RS-485控制器(211)將其發射輸入 端(DI)所取得該遠端微處理器(23)輸出之低準位訊號發送 出去,其效果等同於該自動反射電路(22)將該測量訊號自 動地反射回去。 籲 由上述可知,本發明係藉由令本地端模組(1 〇)發送測 量sfl號透過網路線(3〇)傳送至遠端模組(2〇),再由遠端模 組(20)自動地將測量訊號反射回本地端模組(彳〇),然後計 算測量訊號在網路線(3〇)上傳輸往返的時間,配合電磁波 的傳輸速率及測量系統的參數值,從而精確計算出網路錄 (30)長度值。 缘 當要測量線長時,本發明之較佳實施例又是利用網路 線(30)的其中—對子線傳輸該測量訊號,以控制台延伸器、 視訊延伸器或網路線傳輸的多電腦切換器作為舉例,該對 15 201134145ί SJ In order to improve the lack of route length of the existing computing network, the main purpose of the present invention is to provide a network route (four) measurement system, which is low in cost and high in accuracy. The main technical means for achieving the stated purpose is that the network route length measurement system includes: a local end module, which can send a measurement signal to a pair of sub-lines in a network route; The module is connected to the local end module through the network route, and includes a remote communication circuit, an automatic reflection circuit and a remote microprocessor, wherein the 3H remote communication circuit connects the local area through the network route The end mode | the automatic reflection circuit is connected to the remote communication circuit, the remote microprocessor is connected to the remote communication circuit and the automatic reflection circuit, and stores and executes a reflection switching program, and the remote micro The processor has a mode control terminal connected to the automatic reflection circuit. When the remote microprocessor performs the reflection switching process, the automatic reflection circuit operates to automatically reflect the measurement signal sent by the local end module, and A reflected signal is transmitted back to the local end module via the network route, and the local end module calculates the length of a network route by detecting the time required for the measurement signal to be sent to receive. . The above technical means calculates the time of sending and receiving the measurement signal, divides it by the transmission speed of the radio wave (ie, the speed of light) and then divides by 2 to obtain the line length of the network route, so there is no need to transmit the signal on the network route. In addition, the square wave signal is superimposed, so there is no need to design and install a circuit for intercepting the square wave signal, and it is not necessary to use a resistor-capacitor (RC) charging and discharging circuit to charge the square wave signal to calculate the length of the network route line. The calculated value does not cause an error due to the delay generated when the RC is charged and discharged; in addition, since the system of the present invention only needs to use a general signal as a measurement signal, there is no need for a high-speed data stream with high technical cost, and Since the auto-reflection circuit is controlled by the remote micro-location 6 201134145 to automatically reflect the measurement signal sent by the local-end module, it is not necessary to design a complicated judgment program for the remote microprocessor to perform the return. Measuring signals can increase calculation speed and lower overall cost. [Embodiment] Please refer to the first figure. The network route length detection system of the present invention includes a local end module (10) and a remote module (20). The local end group (10) can send a measurement signal to a network route (3 〇), for example, a pair of sub-lines of Category 5 φ (Cat5/Cat5e) or Category 6 (Cat6). Further referring to the second figure, preferably, the local end module (1 〇) includes: a local end microprocessor (11) having a mode control terminal (Μ〇D E1)' and storing Preferably, the local-end microprocessor (11) has a universal asynchronous transceiver (Universa|Asynchronous Receiver/Transmitter > UART), for example, when the local-side microprocessor When the device (1 1) outputs a high level signal from the mode control terminal (MODE 1) #, the local terminal microprocessor (1 1) does not execute the detection startup program, so the local terminal microprocessor ( 1 1) The data can be converted between serial transmission and parallel transmission according to the operation of the general Uart, and if the local terminal microprocessor (11) outputs a low level sfl from the mode control terminal (M0DE1), The local terminal microprocessor (1 1) will execute the debt test startup program together; a main controller (12) is connected to the local terminal microprocessor (11), and stores a line length detection program by the local The terminal microprocessor (1 1) executes the detection start program to first issue a line length After detecting the command, the main control 7 201134145 (12) executes the line length detection program; a switch (1 3) is connected to the mode control end of the local terminal microprocessor (彳1) (MODE1) And the main controller (12); t Si a local communication circuit (14), which is connected to the network route (3〇) and the switch (13), so that the sin local microprocessor (11) and The main controller (12) is connected to the local communication circuit (彳4) through the switch (13), and when the local terminal microprocessor (11) executes the detection startup program, it will be from the mode. The control terminal (M0DE1) outputs a low level signal to the switch (13) for switching to enable the φ main controller (12) to transmit a measurement signal or receive a reflection signal through the local communication circuit (14). If the local terminal microprocessor (彳彳) does not execute the damage detection startup program, a high level signal is output from the mode control terminal (MODE 1) to the switch (1 3 ) to switch to The local-end microprocessor (1 <|) can transmit and receive signals through the local communication circuit (14); preferably, the s-local The communication circuit (14) includes a local rs_485 controller (141) having at least one pair of differential input and output terminals (D〇), a transceiver direction control terminal (DE), and a receiving output terminal. (r〇) and a transmitting input terminal (()丨), wherein: the pair of differential input and output terminals (〇〇) (/〇〇) are connected to the network route (30); the transmitting and receiving direction control terminal (DE Connecting the local terminal microprocessor (11) and the main controller (12) through the switch (13), and setting the working state of the local RS-485 controller (141) to the receiving state or sending State 'When the transceiver direction control terminal (DE) receives the high level signal, the local RS-485 controller (141) is in the transmitting state, when the transceiver direction control terminal (DE) receives the low level signal The local rS_485 controller (141) is in a receiving state; the receiving output (R0) is connected to the local terminal microprocessor (11) and the main controller (12) through the switch (13). For transmitting the signal converted by the RS-485 controller (141); the transmitting input ((1)) is transmitted through the switch (13) Connect the local terminal microprocessor (1)) and the main control benefit (12) for receiving signals to the local RS_485 controller ((4)) after conversion by shai to differential input and output (D〇) (/d 〇) send; - counter (15) 'connects to the main controller (12), the counter (15) is activated by the main controller (12) when the measurement signal is sent until the main control (12) receives The counter is terminated when the signal is reflected, whereby the leaf number is sent and received as a time count value, and the main controller (1 2) knows the local terminal microprocessor (1 1) from the counter (15) Reading the transceiver time count value, and the local terminal microprocessor (1彳) calculates a network route length value according to the data, so that the external device of the system of the present invention can use the network route length value Deriving the attenuation of the video signal to compensate for the attenuated video signal; wherein, the S-master controller (1 2), the switch (13), and the counter (14) can be integrated into a component programmable logic gate array ( Field Pr〇grammab|e Gate Array (FPGA) or complex programmable logic Means (c〇mp | ex φ Programmable Logic Device > referred CPLD) in. The remote module (20) is connected to the local end module (10) through the network route (30), and the remote module (20) can reflect the measurement signal back to the locality when receiving the measurement signal. The end module (1 〇); as shown in the third figure, the remote module (20) includes: a remote communication circuit (21) 'connects the local communication circuit through the network route (30) ( 14) Preferably, the remote communication circuit (21) comprises a remote RS-485 controller (211) having the same specifications as the local RS-485 controller (141), wherein the pair is poor The dynamic input/output terminal (d〇) (/DO) system 9 201134145 is connected to the network route (30); an automatic reflection circuit (22) is connected to the remote communication circuit (21); preferably, the automatic reflection circuit (22) connecting the transceiver direction control terminal (DE) and the receiving output terminal (RO) of the remote RS-485 controller (211); a remote microprocessor (23) is connected to the remote communication circuit ( 21) and an automatic reflection circuit (22), and storing a reflection switching program, the remote microprocessor (23) having a mode control terminal connected to the automatic reflection circuit (22) (MODE2), the remote microprocessor (23) controls whether the automatic reflection circuit (22) operates by changing the signal level of the mode control terminal φ (M0DE2) to the automatic reflection circuit (22). Preferably, the remote microprocessor (23) is connected to the receiving output end (r〇) and the transmitting input end (DI) of the remote RS-485 controller (21 1), and the remote micro processing The mode control terminal (MODE2) of the device (23) is connected to the automatic reflection circuit (22), and the remote microprocessor (23) also has a UART, for example, when the remote microprocessor (23) is When the mode control terminal (MODE2) outputs a low level signal, the remote microprocessor (23) does not perform the reflection switching procedure, so the remote microprocessor (23) can operate according to the general UART. Converting data between serial transmission and parallel transmission, and the remote RS_485 controller (211) of the remote communication circuit (21) outputs according to the remote communication circuit (21), and the automatic reflection circuit (22) Transmitting to the signal level of the transceiver direction control (DE) of the remote RS-485 controller (211); otherwise, if the remote end The processor (23) receives the line length detection 7 sent by the local terminal microprocessor (1) via the remote communication circuit (21) and replies to the received signal, the remote micro The processor (23) executes the reflection switching program and outputs a level signal from the mode control end (m〇de2) to control the operation of the automatic reflection circuit (22), thereby automatically reflecting the main controller 10 201134145 (12) The measured signal is sent as a reflected signal, and the reflected signal is transmitted back to the main controller (12) via the network route (30). As shown in the third figure, the automatic reflection circuit (22) includes: a first switch and a shutter (221) having two input terminals and an output terminal, wherein the two input terminals are connected to the remote RS-485. a receiving output (RO) of the controller (211); a second reverse gate (222) having a first input end (222a), a φ second input end (222b), and an output end, wherein the The first input terminal (222a) is connected to the output end of the first anti-gate (221), and the second input terminal (222b) is connected to the remote microprocessor (23); a diode (D1)' The cathode is connected to the output end of the second anti-gate (222); a resistor (R6)' is connected to the anode of the diode (D1); and a capacitor (C1) is connected to the diode (D1) The anode and the resistor (R6); the Luyi second reverse gate (223) has a two-input and an output, wherein the two inputs are commonly connected to the remote microprocessor (23); The fourth reverse gate (224) has a first input end (224a) 'a second input end (224b) and an output end, wherein the first input end (224a) is connected to the diode (D1) a pole, a resistor (R6) and a capacitor (C1), the second input terminal (224b) is connected to the output end of the third reverse gate (223), and the output terminal is connected to the remote RS-485 controller (211 The transmission and reception direction control terminal (DE). Please refer to the fourth figure, the local terminal microprocessor (1 11 201134145 performs the detection start procedure includes the following steps: issuing a line length detection command to the remote module (4〇)); One of the remote module returns to confirm the receipt signal (4〇2); ^ If the confirmation receipt signal is not received, further determine whether the time has elapsed (403) 'If the buffer time has not been exceeded, continue to judge Whether to receive a confirmation receipt signal (4〇2), otherwise to end the process; eight right has received the confirmation receipt signal, then further control the switcher switch only ^ the main controller is connected to the local communication circuit (4Q4), and Control the main controller to execute the φ line length detection program (4〇5>; determine whether the main controller completes the line length detection program (406), whether the main controller (12) notifies the self-counter to obtain the transmission and reception time meter The value is judged by the value; the right main controller (12) has notified that the counter can receive the transmission and reception time count value from the counter (15), and reads and receives the transmission and reception time count value (4〇7) from the counter, and calculates the network route according to the transmission and reception time count value. Length value 4〇8); Preferably, the formula of the formula f is line length (meter) = [(transmission time count value * T_c丨〇ck - T" c) _ * 〇 · 3 ] / 2, where T_clock is a counter (15) The measurement frequency unit, T-rC is the reaction time of the remote RS485 controller (211), which is a fixed value. If the required accuracy is not high, the T_"c彳 ignores the ten, for example In other words, if the system clock frequency is { 40MHz, the minimum count unit of the counter (15) is 25ns (one billionth of a second), so the transmission speed of the electromagnetic wave is 〇〇, 〇00,0〇〇m (m)' Seconds (s), that is, 〇3m/ns, so the precision of the length of the measurement network route (3〇) is 3.25m; if the system clock frequency is 1〇〇MtHz, the precision of the length of the measurement network route (30) can be reached.彳5m ; Control switcher switching only connects the local terminal microprocessor to the local communication 201134145 circuit (409); if the main controller (12) has not notified the counter (15) to obtain the transceiver time count value, then further determine whether it has More than one delay time (41 〇), if the delay time has not been exceeded, continue to judge whether the main controller notifies the self-counter The transceiver time count value (4〇6) is obtained. Otherwise, the switch is controlled to switch the local end microprocessor to the local communication circuit (4〇9) and the process ends. Please refer to the fifth figure for the local end. The line length detection procedure performed by the main controller (1 2) of the module (1) includes the following steps: setting the local communication circuit to the transmission state (501), which is the local RS-485 controller ( 141) The transmitting and receiving direction control end (DE) sends a high level signal; sends a measurement signal to the local end communication circuit and simultaneously controls the counter to start counting (502); setting the local end communication circuit to the receiving state (503), The transmitting and receiving direction control terminal (DE) of the local RS-485 controller (141) sends a low level signal; it is judged whether the same reflected signal (5〇4) is received as the measurement signal; if the measurement signal is not received The same reflected signal further determines whether the counter has overflowed (505). If it has not overflowed, it continues to judge whether the same reflected signal (504) is received. Otherwise, the length of the network route (3〇) has exceeded. maximum Therefore, an error preset value is used as the network route length value (506), and the counter is further controlled to stop counting (5〇7); if the same reflected signal as the measurement signal has been received, the control counter stops counting (507) 'And further inform the local terminal microprocessor can obtain the transceiver time count value (508) from the counter and then end. 13 201134145 Please refer to the sixth figure again. The reflection switching procedure performed by the Yuan and Tong 4 microprocessor (23) includes the following steps: After the process starts, it is judged whether the line length detection command is received (6〇1) If otherwise, the process is terminated, otherwise the following steps are continued; reply to confirm the receipt signal (602); control the automatic reflection circuit operation (603), output a high level signal from the control terminal (MQDE2); The operation time (604) is used to calculate the operation time of the automatic reflection circuit; determine whether the operation time of the automatic reflection circuit exceeds a preset time (605); if the operation time of the automatic reflection circuit (22) does not exceed the preset time, Then, it is determined whether the operation time of the automatic reflection circuit exceeds a preset time (605), and vice versa, the automatic reflection circuit is stopped (6〇6), and a low level signal is outputted from the mode control end (MODE2), and then End Process 0 The following is an example of a low-level signal signal sent by the main controller (12), and the action of the automatic reflection circuit (22) is explained: 1 _When After receiving the line length detection command sent from the local end module (1〇) and replying to confirm the receipt signal, the remote microprocessor (23) outputs a high level from the mode control end (MODE2). The bit signal to the second input end (222b) of the second anti-gate (222) indicates that the remote module (2〇) enters an operation mode capable of automatically reflecting the measurement signal. At this time, the remote micro processing The device (23) outputs a low level signal to the transmitting input terminal (DI) of the remote RS-485 controller (211). At this point, the far end communication circuit (21) assumes a waiting for receiving state. 201134145 2. When the remote microprocessor (23) receives the measurement signal (ie, the low level signal) from the local end module (10), the measurement signal is also input to the first reverse gate ( 221) the two input ends, the output end of the first anti-gate (221) outputs a high level signal to the first input end (222a) of the second anti-gate (222), The mode control terminal (MODE2) of the remote microprocessor (23) outputs a high level signal to the second input terminal (222b) of the second reverse gate (222) 'the second reverse gate (222) The output terminal will output a low level signal 'At this time, the diode (D1) will be turned on, thereby discharging the capacitor (C1), and φ causes the fourth back gate (224) to be connected to the capacitor (C1). The first input terminal (224a) will obtain a low level signal, so that the output end of the fourth reverse gate (224) necessarily outputs a high level signal to the transceiver direction control end of the remote RS_485 controller (211). (DE), at this point, the remote communication circuit (21) will be switched to the transmitting state, and the remote RS-485 controller (211) obtains the transmitting input terminal (DI) thereof. The low level signal output from the remote microprocessor (23) is sent out, and the effect is equivalent to the automatic reflection circuit (22) automatically reflecting the measurement signal back. It can be seen from the above that the present invention transmits the measurement sfl number through the network route (3〇) to the remote module (2〇) by the local end module (1〇), and then the remote module (20). Automatically reflect the measurement signal back to the local end module (彳〇), and then calculate the time when the measurement signal is transmitted back and forth on the network route (3〇), match the transmission rate of the electromagnetic wave and the parameter value of the measurement system, thereby accurately calculating the network. Road record (30) length value. When the line length is to be measured, the preferred embodiment of the present invention utilizes a multi-computer that transmits the measurement signal to the sub-line of the network route (30) and transmits it by a console extender, a video extender or a network route. Switcher as an example, the pair 15 201134145

子線可為負責傳遞鍵盤及滑鼠數位訊號的通道,故本發明 僅利用網路線(30)四對子線中負責傳送數位通訊的一對子 線,兀全不需要動用另外三對負責傳送監視器訊號的子 線故應用上較為方便。此外,本發明既不需要如既有計 算網路線線長的方式般必須疊加方波訊號,更不需要利方 波λ號多募的充電方式計算網路線長度值,亦不需要使用 成本較冋的咼速資料流技術,因此本發明之系統所計算出 的’用路線長度值精密度是屬於線性的精密度,遠較既有計 算網路線線&的方式精準,i戶斤需成本較低β 再者,本發明亦毋須如既有利用高速資料流計算網路 線線長的方式般,必須使用高速資料流收發器,因此可降 低成本;又本發明之自動反射電路(22)可自動地反射該本 也端模,’且(1 G)所發出之測量訊號,故該遠端微處理器⑻) 上毋須如既有利用高速資料流計算網路線線長的方式般必 頁、’星由軟體的判斷&式,因此不但遠端微處理器(23)毋須 執行軟體的判斷程式而可加速網路線長度的計算,且也可 省去高速資料流收發器之成本。 惟本發明雖已於前述實施例中所揭露,但並不僅限於 前述實施例巾所提及之心,在不脫離本發明之精神和範 圍内所作之任何變化與修改,均屬於本發明之保護範圍。 综上所述,本發明已具備顯著功效增進,並符合發明 專利要件’袭依法提起申請。 【圖式簡單說明】 第一圖:係本發明之功能方塊圖。The sub-line can be the channel responsible for transmitting the keyboard and the mouse digital signal. Therefore, the present invention only utilizes a pair of sub-lines of the four pairs of sub-lines responsible for transmitting the digital communication in the network route (30), and does not need to use the other three pairs to transmit. The sub-line of the monitor signal is therefore more convenient to apply. In addition, the present invention does not need to superimpose the square wave signal as in the method of calculating the length of the route of the network, and does not need to calculate the route length value of the network by the charging method of the square wave λ number, and does not need to use the cost. The idle data flow technology, therefore, the precision of the route length value calculated by the system of the present invention is linear precision, which is far more accurate than the existing route of the calculation network route & Low β Further, the present invention does not need to use a high-speed data stream to calculate the route length of the network, and must use a high-speed data stream transceiver, thereby reducing the cost; and the automatic reflection circuit (22) of the present invention can automatically Reflexively reflects the measurement signal sent by the end mode, 'and (1 G), so the remote microprocessor (8) does not need to use the high-speed data stream to calculate the route length of the network. The star is judged by the software & the far-end microprocessor (23) not only does not need to execute the software judgment program to speed up the calculation of the network route length, but also eliminates the cost of the high-speed data stream transceiver. However, the present invention has been disclosed in the foregoing embodiments, and is not limited to the above-mentioned embodiments, and any changes and modifications made without departing from the spirit and scope of the present invention are protected by the present invention. range. In summary, the present invention has been significantly improved in effectiveness and is in compliance with the invention patents. BRIEF DESCRIPTION OF THE DRAWINGS The first figure is a functional block diagram of the present invention.

ί 'SI 16 201134145 第二圖:係本發明中一本地端模組的功能方塊暨部分 電路圖。ί 'SI 16 201134145 The second figure is a functional block and a partial circuit diagram of a local end module in the present invention.

既有利用高速資料 第二圖:係本發明中一 第四圖:係本發明中一 啟動程序的流程圖》 第五圖:係本發明中一 序的流程圖。 第六圖:係本發明中一 換程序的流程圖。 第七圖:係 構的功能方塊圖 遠端模組的電路圖。 本地端微處理器執行之一偵測 主控制器執行之-線長偵測程 遠端微處理器執行之一反射切 流計算網路線線長之架 【主要元件符號說明】 (1〇)本地端模組 (11) 本地端微處理器 (12) 主控制器 (13) 切換器 (1 4)本地端通信電路 (141)本地端RS-485控制巧 (15)計數器 (20) 遠端模組 (21) 遠端通信電路 (21 1)遠端RS-485控制器 (22) 自動反射電路 (221)第一反及閘 201134145 (222) 第二反及閘 (222a)第一輸入端 (222b)第二輸入端 (223) 第三反及閘 (224) 第四反及閘 (224a)第一輸入端 (224b)第二輸入端 (23)遠端微處理器 (30)網路線 (4 0)本地端模組 (41) 本地端微處理器 (42) 本地端高速資料流收發器 (43) 本地端通信電路 (50) 遠端模組 (51) 遠端微處理器 (52) 遠端高速資料流收發器 (53) 遠端通信電路 (60)網路線 18The use of high speed data is the second drawing: a fourth drawing of the present invention: a flow chart of a starting procedure in the present invention. Fig. 5 is a flow chart showing the sequence of the present invention. Fig. 6 is a flow chart showing a procedure of the present invention. Figure 7: Functional block diagram of the system Circuit diagram of the remote module. The local-end microprocessor executes one of the detections of the main controller to execute the line length detection process. The remote microprocessor performs one of the reflection cut flow calculation network route line length frame [main component symbol description] (1〇) local end mode Group (11) Local-end microprocessor (12) Main controller (13) Switcher (1 4) Local-side communication circuit (141) Local-side RS-485 control (15) Counter (20) Remote module ( 21) Remote communication circuit (21 1) Remote RS-485 controller (22) Automatic reflection circuit (221) First reverse gate 201134145 (222) Second reverse gate (222a) first input terminal (222b) Second input terminal (223) third reverse gate (224) fourth reverse gate (224a) first input terminal (224b) second input terminal (23) remote microprocessor (30) network route (4 0 Local Module (41) Local Microprocessor (42) Local High Speed Data Stream Transceiver (43) Local Communication Circuit (50) Remote Module (51) Remote Microprocessor (52) Remote High-speed data stream transceiver (53) remote communication circuit (60) network route 18

Claims (1)

201134145 七、申請專利範圍: 1 · 一種網路線線長偵測系統,係包括: 一本地端模組,其可向一網路線中的一對子線發出一 測量訊號; 一遠端模組,係透過該網路線與該本地端模組連接, 並包括一遠端通信電路、一自動反射電路及一遠端微處理 器,其中:該遠端通信電路係透過網路線連接該本地端模 組;該自動反射電路係連接該遠端通信電路;該遠端微處 理器係連接該遠端通信電路和自動反射電路,並儲存且執 行一反射切換程序,又該遠端微處理器具有一連接該自動 反射電路的模式控制端,當該遠端微處理器執行該反射切 換程序時,該自動反射電路即運作以自動地反射該本地端 模組所發出之測量訊號,而作為一反射訊號經該網路線回 傳予該本地端模組,由該本地端模組藉由偵測測量訊號自 發出至接收所需的時間計算出一網路線長度值。 2.如申請專利範圍第1項所述之網路線線長偵測系 統’該自動反射電路係包括: —第一反及閘,係具有兩輸入端及一輸出端,該兩輸 入端係共同連接該遠端通信電路; 一第二反及閘,係具有—第一輸入端、一第二輸入端 及:輸出端’纟中該第一輸入端係連接該第—反及閘的輸 出端,該第二輸入端係連接該遠端微處理器的模式控 端; 、工 —二極體,其陰極係連接該第二反及閘的輸出端; 一電阻’係連接該二極體的陽極; 201134145 一電容’係連接該二極體的陽極及該電阻; 一第三反及閘’係具有兩輸入端及一輸出端,其中該 兩輸入端係共同連接該遠端微處理器; 一第四反及閘,係具有一第一輸入端、—第二輸入端 及一輸出端,其中第一輸入端係連接該二極體的陽極、電 阻及電容,該第二輸入端係連接該第三反及閘的輪出端, 而輸出端則連接該遠端通信電路。 3.如申請專利範圍第2項所述之網路線線長偵測系 φ 統,該遠端通信電路係包括一遠端RS-485控制器,該遠 端RS-485控制器具有: 一對差動輸入輸出端,係與網路線連接; 一收發方向控制端,係連接該第四反及閘之輸出端; 一接收輸出端,係連接該遠端微處理器及該第一反及 閘的兩輸入端,供傳送經遠端RS_485控制器轉換之訊號; 及 ) 一發射輸入端,係連接該遠端微處理器,供接收訊號 •予該遠端Rs·485控制器轉換後由該對差動輸入輸出端發 送。 4_如申清專利範圍第3項所述之網路線線長偵測系 統,當該測量訊號係為一低準位訊號時,該遠端微處理器 係藉由輸出一低準位訊號至該遠端Rs_485控制器之發射 輸入端及自其模式控制端輸出一高準位訊號至該第二反及 閘之第二輸入端,以啟動該自動反射電路工作,將測量訊 號反射回本地端模組。 5·如申請專利範@第]i 4項中任—項所述之網路線 20 201134145 線長偵測系統,該本地端模組包括: 一本地端微處理器’係具有一模式控制端,並儲存一 偵測啟動程序; 一主控制器’係連接該本地端微處理器,並儲存一線 長债測程序’由該本地端微處理器執行該偵測啟動程序, 先發出一線長偵測命令後’再控制該主控制器執行該線長 須測程序,而該遠端模組則在接收到該線長偵測命令後始 啟動該自動反射電路以將測量訊號反射回本地端模組; 鲁 切換器,係連接該本地端微處理器的模式控制端及 該主控制器; 一本地端通信電路’係連接該網路線及該切換器,使 該本地端微處理器和該主控制器皆透過該切換器連接該本 地端通信電路,當該本地端微處理器執行該偵測啟動程序 時’該切換器即被切換僅令該主控制器可透過該本地端通 信電路發射一測量訊號或接收一反射訊號,反之則該切換 器即被切換令該本地端微處理器可透過該本地端通信電路 φ 發射及接收訊號; 一計數器,係連接該主控制器,該計數器係由該主控 制器於發出測量訊號時一同啟動,直至該主控制器接收到 反射訊號時才終止該計數器之計數,藉此計數一收發時間 計數值’並由該主控制器通知該本地端微處理器自該主控 制器讀出該收發時間計數值,而由該本地端微處理器據此 計算出網路線長度值。 6.如申請專利範圍第5項所述之網路線線長偵測系 統’當該遠端模組接收到該本地端微處理器所發出的線長 21 201134145 偵測命令時,係先回覆一確認收達訊號後,方可將測量訊 號反射回本地端模組。 7_如申請專利範圍第6項所述之網路線線長偵測系 統,該遠端微處理器所執行之反射切換程序係包括下列步 驟: 流程開始後,即判斷是否收到線長偵測命令,若否則 結束流程,反之則繼續進行下列步驟; 回覆確認收達訊號; φ 控制自動反射電路運作; 計算運作時間; 判斷自動反射電路運作時間是否超過一預設時間; 如自動反射電路運作時間並未超過預設時間,則繼續 判斷自動反射電路運作時間是否超過一預設時間,反之則 控制自動反射電路停止運作,隨後即結束流程。 8_如申請專利範圍第6項所述之網路線線長偵測系 統,該本地端微處理器所執行之偵測啟動程序係包括下列 φ 步驟: 發出一線長偵測命令給遠端模組; 判斷疋否收到遠端模組回傳之一破認收達訊號; 若未收到確認收達訊號,則進一步判斷是否已超過一 緩衝時間’若尚未超過緩衝時間則繼續判斷是否收到一確 認收達訊號’反之則結束流程; 若有收到確認收達訊號,則進一步控制切換器切換僅 令主控制器連接本地端通信電路,並控制主控制器執行線 長偵測程序; 22 201134145 主控制^是以成線㈣測料,係 是否通知可自计動哭诉炫剌裔 ^ 冲數取件收發時間計數值加以判斷; 右主控制器已通知通知可自計數器取得收發時間計數 值,則自計數器讀出收發時間計數值,並根據收發時間計 數值計算網路線長度值; 控制切換器切換僅令本地端微處理器連接本地端通信 電路; 若主控制器尚未通知可自計數器取得收發時間計數 籲值,則進-步判斷是否已超過一延遲時間,若尚未超過延 遲時間則繼續判斷主控制器是否通知可自計數器取得收發 時間計數值,反之則控制切換器切換僅令本地端微處理器 連接本地端通信電路後結束流程。 9.如申請專利範圍第8項所述之網路線線長偵測系 統,該主控制器所執行之線長偵測程序係包括下列步驟: 設定本地端通信電路為發送狀態; 對本地端通信電路發出測量訊號並同時控制計數器開 φ 始計數; 設定本地端通信電路為接收狀態; 判斷是否收到與測量訊號相同的反射訊號; 若未能收到與測量訊號相同的反射訊號,則進一步判 斷計數器是否已溢位,若尚未溢位則繼續判斷是否收到與 測量訊號相同的反射訊號,反之則表示網路線長度已超過 最大範圍’故以一錯誤預設值作為網路線長度值,並進— 步控制計數器停止計數; t 若已收到與測量訊號相同的反射訊號,則控制計數器 23 201134145 停止計數,並進一步通知本地端微處理器可自計數器取得 收發時間計數值後結束。 10·如申請專利範圍第9項所述之網路線線長偵測系 統,該本地端通信電路係包括一本地端rS_485控制器, 該本地端RS-485控制器具有: 一對差動輸入輸出端,係與網路線連接; 一收發方向控制端,係透過該切換器連接該本地端微 處理器和該主控制器; • 一接收輸出端,係透過該切換器連接該本地端微處理 器和該主控制器,供傳送經本地端RS-485控制器轉換之 訊號;及 一發射輸入端,係透過該切換器連接該本地端微處理 器和該主控制器,供接收訊號予該本地端RS-485控制器 轉換後由該對差動輸入輸出端發送。 八、圖式:(如次頁) 24201134145 VII. Patent application scope: 1 · A network route line length detection system includes: a local end module, which can send a measurement signal to a pair of sub-lines in a network route; a remote module, Connected to the local end module through the network route, and includes a remote communication circuit, an automatic reflection circuit and a remote microprocessor, wherein: the remote communication circuit connects the local end module through a network route The automatic reflection circuit is connected to the remote communication circuit; the remote microprocessor is connected to the remote communication circuit and the automatic reflection circuit, and stores and executes a reflection switching program, and the remote microprocessor has a connection a mode control end of the automatic reflection circuit, when the remote microprocessor performs the reflection switching process, the automatic reflection circuit operates to automatically reflect the measurement signal sent by the local end module, and the reflected signal is transmitted as a reflection signal The network route is transmitted back to the local end module, and the local end module calculates a network route length value by detecting the time required for the measurement signal to be sent to the reception. 2. The network route length detection system according to claim 1, wherein the automatic reflection circuit comprises: a first reverse gate having two inputs and an output, the two inputs being common Connecting the remote communication circuit; a second reverse gate having a first input terminal, a second input terminal, and an output terminal '纟, the first input terminal is connected to the output end of the first-reverse gate The second input end is connected to the mode control end of the remote microprocessor; the work-diode has a cathode connected to the output end of the second anti-gate; and a resistor 'connects the diode An anode; 201134145 a capacitor 'connects the anode of the diode and the resistor; a third reverse gate has a two-input and an output, wherein the two inputs are commonly connected to the remote microprocessor; a fourth input gate has a first input end, a second input end and an output end, wherein the first input end is connected to the anode, the resistor and the capacitor of the diode, and the second input end is connected The third reverse gate has a wheel end, and the output end The communication circuit connected to the distal end. 3. The network route length detection system φ system described in claim 2, the remote communication circuit includes a remote RS-485 controller, the remote RS-485 controller has: a pair a differential input and output terminal is connected to the network route; a transceiver direction control end is connected to the output end of the fourth reverse gate; and a receiving output terminal is connected to the remote microprocessor and the first reverse gate Two input terminals for transmitting signals converted by the remote RS_485 controller; and) a transmitting input terminal for connecting the remote microprocessor for receiving signals, and being converted by the remote Rs·485 controller Send to the differential input and output. 4_ For example, in the network route length detection system described in claim 3, when the measurement signal is a low level signal, the remote microprocessor outputs a low level signal to The transmitting input end of the remote Rs_485 controller outputs a high level signal from the mode control end to the second input end of the second back and gate to activate the automatic reflection circuit to reflect the measurement signal back to the local end. Module. 5. If you apply for the patent line @第4], the network route 20 201134145 line length detection system, the local end module includes: a local end microprocessor 'has a mode control end, And storing a detection start program; a main controller 'connects the local terminal microprocessor and stores a long line debt test program' by the local terminal microprocessor to execute the detection start program, first issuing a line length detection After the command, the main controller executes the line length test procedure, and the remote module starts the automatic reflection circuit after receiving the line length detection command to reflect the measurement signal back to the local end module; a switch, connected to the mode control end of the local microprocessor and the main controller; a local communication circuit 'connects the network route and the switch to make the local terminal microprocessor and the main controller The local end communication circuit is connected through the switch, and when the local end microprocessor executes the detection start program, the switch is switched only to enable the main controller to transmit through the local communication circuit. Shooting a measurement signal or receiving a reflection signal, otherwise the switch is switched so that the local terminal microprocessor can transmit and receive signals through the local communication circuit φ; a counter is connected to the main controller, the counter When the main controller sends a measurement signal, the main controller starts up until the main controller receives the reflection signal, thereby counting the counter count value, and notifying the local controller by the main controller. The terminal microprocessor reads the transceiver time count value from the master controller, and the local terminal microprocessor calculates the network route length value accordingly. 6. If the remote module receives the line length 21 201134145 detection command issued by the local terminal microprocessor, the network route line length detection system described in claim 5 After confirming the receipt signal, the measurement signal can be reflected back to the local module. 7_ For the network route length detection system described in claim 6 of the patent scope, the reflection switching procedure performed by the remote microprocessor includes the following steps: After the process starts, it is determined whether the line length detection is received. If the process is terminated otherwise, the process continues. The procedure is as follows: reply to confirm the receipt signal; φ control the operation of the automatic reflection circuit; calculate the operation time; determine whether the operation time of the automatic reflection circuit exceeds a preset time; If the preset time is not exceeded, it is determined whether the operation time of the automatic reflection circuit exceeds a preset time, otherwise the automatic reflection circuit is controlled to stop operating, and then the process ends. 8_ For the network route length detection system described in claim 6 of the patent scope, the detection start procedure executed by the local microprocessor includes the following φ steps: issuing a line length detection command to the remote module After judging whether the remote module received a reply signal, if it has not received the confirmation receipt signal, it further determines whether it has exceeded a buffer time. If it has not exceeded the buffer time, it continues to judge whether it has received The acknowledgment of the receipt signal is reversed. If the acknowledgment receipt signal is received, further control of the switchover switch only causes the main controller to connect to the local communication circuit and control the main controller to execute the line length detection procedure; 201134145 The main control ^ is based on the line (four) to measure the material, whether it is notified or not, it can be judged by the self-counting and crying, and the count value of the receiving and receiving time is judged; the right main controller has notified the notification that the counter can receive the sending and receiving time count value. , the counter reading time count value is read from the counter, and the network route length value is calculated according to the sending and receiving time count value; the control switcher switches only the local end microprocessor Connect the local communication circuit; if the main controller has not notified the self-counter to obtain the transmission and reception time count call value, it will judge whether it has exceeded a delay time, and if it has not exceeded the delay time, continue to judge whether the main controller notifies the self-counter The receiving and receiving time count value is obtained. Otherwise, the switching of the control switch only ends the process after the local terminal microprocessor is connected to the local communication circuit. 9. The network route length detection system according to item 8 of the patent application scope, the line length detection program executed by the main controller comprises the following steps: setting a local end communication circuit to a transmission state; The circuit sends a measurement signal and simultaneously controls the counter to start φ to start counting; sets the local communication circuit to receive state; determines whether the same reflection signal is received as the measurement signal; if it fails to receive the same reflection signal as the measurement signal, further judges Whether the counter has overflowed. If it has not overflowed, it continues to judge whether it receives the same reflection signal as the measurement signal. Otherwise, it indicates that the network route length has exceeded the maximum range. Therefore, an incorrect preset value is used as the network route length value. The step control counter stops counting; t If the same reflected signal as the measurement signal has been received, the control counter 23 201134145 stops counting, and further informs the local terminal that the microprocessor can obtain the transmission and reception time count value from the counter and ends. 10. The network route length detection system according to claim 9 of the patent scope, the local communication circuit comprises a local rS_485 controller, the local RS-485 controller has: a pair of differential input and output The end is connected to the network route; a transceiver direction control end is connected to the local end microprocessor and the main controller through the switch; • a receiving output terminal is connected to the local end microprocessor through the switch And the main controller is configured to transmit a signal converted by the local RS-485 controller; and a transmitting input is connected to the local terminal microprocessor and the main controller through the switch for receiving signals to the local The RS-485 controller is converted and sent by the pair of differential input and output terminals. Eight, schema: (such as the next page) 24
TW99108464A 2010-03-23 2010-03-23 Network cable length detection system TW201134145A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW99108464A TW201134145A (en) 2010-03-23 2010-03-23 Network cable length detection system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW99108464A TW201134145A (en) 2010-03-23 2010-03-23 Network cable length detection system

Publications (2)

Publication Number Publication Date
TW201134145A true TW201134145A (en) 2011-10-01
TWI488459B TWI488459B (en) 2015-06-11

Family

ID=46751387

Family Applications (1)

Application Number Title Priority Date Filing Date
TW99108464A TW201134145A (en) 2010-03-23 2010-03-23 Network cable length detection system

Country Status (1)

Country Link
TW (1) TW201134145A (en)

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW215982B (en) * 1993-04-26 1993-11-11 Telecomm Lab The accurate detecting method for locating malfunction spot on telecommunication wires
US6487276B1 (en) * 1999-09-30 2002-11-26 Teradyne, Inc. Detecting faults in subscriber telephone lines

Also Published As

Publication number Publication date
TWI488459B (en) 2015-06-11

Similar Documents

Publication Publication Date Title
US8510492B2 (en) System and method for communication handshaking between a master processors and a slave processor
JP6208232B2 (en) Method and apparatus for USB signaling over intermediate transport
CN103209030B (en) Electronic device and data transmission method thereof
CN201233224Y (en) CCD laser triangle displacement sensor
RU2016132577A (en) PERIPHERAL DEVICES IN A WIRELESS COUPLING SYSTEM
WO2019000373A1 (en) Circuit, method and related chip for time measurement, system, and device
TWI226551B (en) Multi-function wireless bridge for USB and associated system
CN108616663A (en) Sharing files method, apparatus, mobile terminal and storage medium
TW201134145A (en) Network cable length detection system
CN201967024U (en) Tripod head camera
WO2017049556A1 (en) Data transmission method and mobile terminal
CN106155426A (en) There is the mouse pad touching tracking function
TWM453140U (en) Portable optical fiber testing device operable through wireless mobile devices
CN204536440U (en) A kind of wireless frequency spectrum through type digital radio frequency power meter
CN109200600B (en) Intelligent building block system and data transmission method
TWI511478B (en) Ultrasound data acquisition system, and method and ultrasound receiving device
CN201774527U (en) Wireless transceiving module connected with USB interface and based on virtual COM interface
CN108769934B (en) Information processing method and device and mobile terminal
CN107703462B (en) Controller
CN102841877B (en) Detecting method and automatic detecting circuit of working mode
CN102799330B (en) Based on the sensor connecting circuit of electronic equipment and control method thereof and electronic equipment
CN110177035A (en) Data receiver and sending method, device and data receiving-transmitting system
CN102201946B (en) Network cable length sensing system
TW201020767A (en) Error detecting apparatus of server and error detecting method thereof
JP2543272B2 (en) Mouse extension / expansion device

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees