版權(quán)說(shuō)明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
1、<p><b> 科技文章摘譯 </b></p><p><b> 英文原文 </b></p><p> Abstract: This application note discusses the timing requirements for the commonly used serial asynchronous commu
2、nications protocol implemented in UARTs, and shows how to determine the tolerance for the UART clock source at both ends of an asynchronous link.</p><p> Background</p><p> The RS-232 specifi
3、cation dates back to 1962, when it was first released by the EIA (Electronic Industries Association). The specification has changed over time, incorporating higher data rates and closing the compatibility gaps between TI
4、A (Telecommunication Industry Association) and international (ITU, ISO) standards. The current version of the RS-232 specification is EIA/TIA-232-F, dated October 1997. </p><p> The protocol benefited from
5、the availability of MSI ICs from the late 1970s which had the complexity to handle the standard at reasonable cost. These ICs are generically called UARTs (Universal Asynchronous Receive Transmit). Many LSI ICs (includin
6、g microcontrollers) now include the functionality.</p><p> As is often the case, the availability of UARTs drove the industry to use the RS-232 serial protocol in non-RS-232 ways. Common examples are RS-485
7、 transmissions, opto-isolated transmissions, and transmissions using a single-ended physical layer (i.e. 0 - 3.3V instead of ±5V or ±10V). This note covers the general timing aspects of the serial interface, no
8、t application nuances of handshaking or the physical layer, and so is applicable to all generalized UART applications.</p><p> UART Timing</p><p> A typical UART frame is shown in Figure 1. It
9、 comprises a Start bit, 8 data bits, and a Stop bit. Other variants are also possible in RS-232 applications - the data packet could be 5, 6, or 7 bits long, there could be 2 Stop bits, and a Parity bit could be inserted
10、 between the data packet and the Stop bit for rudimentary error detection. Figure 1 shows the signaling as seen at a UART's TXD (Transmit Data) or RXD (Receive Data) pins. RS-232 bus drivers invert as well as level s
11、hift, so a logic 1 </p><p> Figure 1. A typical UART data frame.</p><p> When two UARTs communicate, it is a given that both transmitter and receiver know the signaling speed. The receiver doe
12、sn't know when a packet will be sent, with respect to the receiver clock, hence the protocol is termed asynchronous. The receiver circuitry is correspondingly more complex than that of the transmitter. While the tran
13、smitter simply has to shuffle out a frame of data at a defined bit rate, the receiver has to recognize the start of the frame to synchronize itself, and therefore de</p><p> Figure 2 shows a common method u
14、sed by UART receivers to synchronize to a received frame. The receive UART uses a clock which is 16 times the data rate. A new frame is recognized by the falling edge at the beginning of the active-low Start bit, when th
15、e signal changes from the active-high Stop bit or bus idle condition. The receive UART resets its counters on this falling edge, and expects mid Start bit to occur after 8 clock cycles, and the mid point of each subseque
16、nt bit to appear every 16 cl</p><p> Figure 2. UART receive frame synchronization and data sampling points.</p><p> Timing Accuracy</p><p> So the question is: how accurate does
17、the receive UART clock have to be to be sure of receiving data correctly? (Actually, a better question is to ask how far different the transmit and receive UART clocks can be, since the absolute clock rate is unimportant
18、 for the purposes of accurate reception. More on this later.) To answer this, the first point to understand is that because the UART receiver synchronizes itself to the start of each and every frame, we only care about a
19、ccurate data sampling </p><p> When do we get a timing error due to transmit-receive clock mismatch? Well, we are attempting to sample each bit at the mid point (Figure 2). If we sample a bit ½ a bit p
20、eriod too early or too late, we will sample at the bit transition and have problems (Figure 3).</p><p> Figure 3. UART receive sampling range.</p><p> In reality, we can't (reliably) sampl
21、e close to the bit transition point. The dominant reason for this is the finite (and typically slow) transmission rise and fall times, made even slower if overly capacitive cabling is used. A long bus incurs high attenua
22、tion, reducing noise margin, making it more important to sample when the bit level has settled. It is difficult to assess a worst case acceptable sampling range across a bit's period in a quantitive manner. EIA/TIA-2
23、32-F does specify a 4% of b</p><p> For Figures 4 and 5 we can determine that the error budget is ±25% and ±37.5% from the optimal bit-centre sampling point for the nasty and normal scenarios resp
24、ectively. This error is equivalent to ±4 or ±6 periods of the x16 UART receive clock. Another error to include in this budget is the synchronization error when the falling edge of the Start bit is detected. The
25、 UART will most likely be designed to start on the next rising edge of its 16x clock after Start bit detection. Since the 16x cloc</p><p> We will presume that short-term clock errors (essentially, jitter)
26、are very small, and therefore we are only considering mid-term and long-term errors. These errors boil down to mismatch in the transmit UART and receive UART timing that is consistent during a frame. Since the timing is
27、synchronized at the falling edge of the Start bit, the worst case timing error will be at the last data sampling point, which is the Stop bit. The optimum sampling point for the Stop bit is are its bit-centre, whi</p&
28、gt;<p> Now we can calculate our allowable error as a percentage. For the normal scenario, the clock mismatch error can be ±5/152 = ±3.3%, and for the nasty scenario it can be ±3/152 = ±2%. As
29、 hinted earlier, although the problem will materialize at the receive end of the link, clock mismatch is actually a tolerance issue shared between the transmit and receive UARTs. So presuming that both UARTs are attempti
30、ng to communicate at exactly the same bit rate (baud), then the allowable error can be shared, i</p><p> Making use of the allowable error budget is helped in systems where both ends of the link are being d
31、esigned at the same time, partly because the tolerance of both ends will be known, and partly because tradeoffs and cost saving can be made. In general a standard, low cost, ceramic resonator with ±0.5% accuracy and
32、 a further ±0.5% drift over temperature and life can be used for the clock source at both ends of the link. This meets the 2% nasty scenario discussed earlier. If the system uses a mas</p><p> 1. It ma
33、y appear odd that the Stop bit is sampled, but it is. If the Stop bit is detected as a low level instead of the expected high level, UARTs typically report a Frame Error.</p><p><b> 英文譯文 </b><
34、;/p><p> 時(shí)鐘精度要求確定為UART的通訊</p><p> 文摘:本應(yīng)用筆記討論時(shí)間要求,常用的串行通信協(xié)議執(zhí)行UARTs同步,并展示了如何確定寬容UART源兩端的時(shí)鐘的同步連接。</p><p><b> 背景,</b></p><p> 這個(gè)RS-232規(guī)格可追溯至1962年,當(dāng)它首先被釋放的環(huán)境影響評(píng)
35、價(jià)(電子工業(yè)協(xié)會(huì))。規(guī)格已經(jīng)改變了,隨著時(shí)間的推移,高數(shù)據(jù)率將關(guān)閉相容性之間的差距(電信行業(yè)協(xié)會(huì)的癥狀及國(guó)際(ITU)標(biāo)準(zhǔn),國(guó)際標(biāo)準(zhǔn)化組織(ISO)。當(dāng)前版本的RS-232規(guī)格環(huán)評(píng)/ TIA-232-F約會(huì),1997年10月。</p><p> 這個(gè)協(xié)議中獲益的芯片的中型從20世紀(jì)70年代的復(fù)雜性來(lái)處理這個(gè)標(biāo)準(zhǔn),能以合理的價(jià)格。這些電路是一般稱為UARTs(通用異步接收傳輸)。許多大規(guī)模集成電路芯片(包括微控制
36、器)現(xiàn)在包括功能。</p><p> 通常情況下,UARTs把工業(yè)用RS-232串行協(xié)議在non-RS-232方式。常見的例子是RS-485傳輸,opto-isolated變速箱、變速器結(jié)束單人賽物理層(如下。0 - 3.3V代替±5伏或±10伏特)。這張封面一般時(shí)間方面的串行接口,不申請(qǐng)的細(xì)微差別,或?qū)嶓w層,握手,適用于所有的程序。UART廣義</p><p>&l
37、t;b> UART時(shí)間</b></p><p> 一個(gè)典型的UART架載于本許可證圖1。它包括一個(gè)起始位元,8位元的資料,并停止位。也可能在其他變量的數(shù)據(jù)包RS-232應(yīng)用-可5、6、7位長(zhǎng)的話,將會(huì)有2個(gè)停止位、一同等值位可以插入的數(shù)據(jù)間的包,停止位為基本錯(cuò)誤檢測(cè)。圖1顯示如圖一個(gè)UART信號(hào)傳輸數(shù)據(jù)的TXD(或RXD(接收數(shù)據(jù))。公共汽車司機(jī)RS-232反演以及水平移動(dòng),所以一個(gè)邏輯1負(fù)
38、電壓在公共汽車上,一個(gè)邏輯0是一個(gè)積極的電壓。</p><p> 圖1。一個(gè)典型的UART數(shù)據(jù)幀。</p><p> 當(dāng)兩個(gè)UARTs溝通,它是一種已知的事實(shí)都發(fā)射機(jī)和接收機(jī)信號(hào)速度。知道接收者不知道當(dāng)一個(gè)包,就會(huì)發(fā)送給接受者的鐘,于是這個(gè)協(xié)議是異步的。相應(yīng)的接收機(jī)電路是更復(fù)雜的發(fā)射機(jī)。而從發(fā)射機(jī)只需要簡(jiǎn)單地洗牌一幀的數(shù)據(jù)在一個(gè)定義編碼傳輸率、接收器已認(rèn)識(shí)到開始的幀同步,確定最佳的數(shù)據(jù)
39、采集的最高。</p><p> 圖2所示的常用方法采用同步UART接收機(jī)收到的框架。用一個(gè)時(shí)鐘的接收UART的數(shù)據(jù)速率16倍。一個(gè)新的框架是公認(rèn)的下降沿active-low之初,當(dāng)信號(hào)的起始位高電平次數(shù)的變化的停止位或巴士閑置狀態(tài)。接收UART重置其柜臺(tái)邊,并且希望這個(gè)下降中發(fā)生在8點(diǎn)開始,中期時(shí)鐘周期后續(xù)的每一個(gè)點(diǎn)對(duì)點(diǎn)出現(xiàn)每16時(shí)鐘周期。一開始是典型的采樣點(diǎn)的時(shí)間來(lái)檢查中期的水平仍然很低,確保檢測(cè)是起始位下降
40、沿不是噪音。另一個(gè)常見的進(jìn)步是抽樣檢查每一點(diǎn)不只是一次中期位(時(shí)鐘計(jì)數(shù)8個(gè)),但三次(時(shí)鐘計(jì)數(shù)7、8、9 / 16)。</p><p> 圖2。收到幀同步和數(shù)據(jù)的UART采樣點(diǎn)。</p><p><b> 時(shí)間精度</b></p><p> 所以問(wèn)題是:如何精確的接收UART時(shí)鐘都必須確信接收數(shù)據(jù)的正確嗎?實(shí)際上,一個(gè)更好的問(wèn)題(就是問(wèn)迥
41、然不同的傳輸和接收UART鐘可以,因?yàn)榻^對(duì)的時(shí)鐘頻率是無(wú)足輕重的精確的接待。在這之后。)要回答這個(gè)問(wèn)題,首先是要了解:因?yàn)閁ART接收器本身的同步、每幀,我們只關(guān)心精確的數(shù)據(jù)采集在一架。沒(méi)有任何累積誤差超過(guò)了框架的停止位、簡(jiǎn)化分析,因?yàn)槲覀儾坏貌豢紤]一幀作為最壞的情況。</p><p> 當(dāng)我們得到一個(gè)計(jì)時(shí)誤差transmit-receive時(shí)鐘匹配嗎?好了,我們都試圖在中期,每點(diǎn)樣點(diǎn)(圖2)。如果我們樣品經(jīng)過(guò)
42、一點(diǎn)一點(diǎn)時(shí)期太早或太遲了,我們將樣品,過(guò)渡和有問(wèn)題(圖3)。</p><p> 圖3。接受抽樣范圍。UART</p><p> 事實(shí)上,我們不能(可靠)樣品到發(fā)際線。主導(dǎo)的原因是有限的(通常是慢傳輸?shù)纳仙拖陆?甚至如果過(guò)度電容式布線是慢。很長(zhǎng)一段時(shí)間,減少汽車亦高噪音衰減,使它更重要的邊緣點(diǎn)樣時(shí)的水平已經(jīng)得到解決。很難評(píng)估一個(gè)壞的情況下,可接受的取樣范圍橫跨一點(diǎn)點(diǎn)定量方式的時(shí)期。TI
43、A-232-F做環(huán)評(píng)/指定一個(gè)4%的位周期的一段時(shí)間內(nèi)殺死傳播最多,但是這是難以達(dá)到的,在192k / bits-1長(zhǎng)跑。但讓我們定義兩個(gè)數(shù)據(jù)路徑場(chǎng)景的目的都是為了這張紙條?!绑a臟的情況考慮,只能從可靠的中期50%的位元時(shí)間(圖4)。這等同于一個(gè)長(zhǎng)、電容RS-232跑?!罢!笨梢栽趫?chǎng)景中75%的位元時(shí)間(圖5),就是到相對(duì)溫和的公共汽車(如一米或兩運(yùn)行緩沖CMOS邏輯層次或RS-485微分副)在設(shè)備上。</p><
44、p> 圖4?!绑a臟的鏈接的UART獲得50%的取值范圍。</p><p> 圖5?!罢5倪B接的接受UART 75%的取值范圍。</p><p> 對(duì)數(shù)字第四項(xiàng)、第五項(xiàng)我們能確定這些錯(cuò)誤的預(yù)算是±10%,且±37.5%從優(yōu)化bit-centre取樣點(diǎn)為急和正常的情景。這個(gè)錯(cuò)誤是相當(dāng)于±4或6期的接收光陰一去不復(fù)返?;謴?fù)UART另一個(gè)錯(cuò)誤,包括預(yù)算同
45、步誤差時(shí)的起始位元的下降沿檢測(cè)。最有可能的UART來(lái)開始下一次設(shè)計(jì)的上升沿起始位檢測(cè)后分別鐘。自從分別時(shí)鐘和收到數(shù)據(jù)流是異步,開始點(diǎn)的下降沿后會(huì)發(fā)生分別上升沿,或只是鐘之前,但卻沒(méi)有與足夠的啟動(dòng)時(shí)間去使用它。這意味著UART有±1比特同步誤差在建造。那么我們從預(yù)算減少誤差±4或6時(shí)鐘周期±3或±5期。</p><p> 我們會(huì)認(rèn)為短期時(shí)鐘錯(cuò)誤(基本上,抖動(dòng))非常小,所以我
46、們只考慮中期和長(zhǎng)期的錯(cuò)誤。這些錯(cuò)誤歸結(jié)為匹配的傳輸和接收UART UART期間定時(shí)一致。自從在時(shí)間同步的下降沿起始位元,最壞的情況下,時(shí)間將會(huì)在最后的錯(cuò)誤數(shù)據(jù)采集,停止位。最佳采樣點(diǎn)停止位,是其bit-centre(16×9.5)= 152 UART接受治療后的時(shí)鐘的下降沿起始位元。</p><p> 現(xiàn)在,我們可以計(jì)算出我們的允許誤差作為一個(gè)百分比。對(duì)于普通的情形下,時(shí)鐘匹配誤差±5/15
47、2 =可以,為±3.3%的惡劣情形可以±3/152 =±2%。早些時(shí)候,盡管作為暗示問(wèn)題總會(huì)在接收端,鐘不匹配問(wèn)題實(shí)際上是一個(gè)寬容之間共享的傳輸和接收UARTs。所以就算這兩UARTs正試圖溝通在相同的比特率(波特),然后在誤差允許可以分享,在任何UARTs兩個(gè)人之間的比例。</p><p> 利用誤差允許的預(yù)算是幫助的兩端連接設(shè)計(jì)的同時(shí),部分是因?yàn)閷捜莸膬啥?就會(huì)知道,部分是因?yàn)?/p>
48、交易、節(jié)約成本。在一般的標(biāo)準(zhǔn)、低成本、陶瓷諧振器和±0.5%的準(zhǔn)確性和進(jìn)一步±0.5%的過(guò)熱和生活的漂移可用于時(shí)鐘源的兩端連接。惡劣的情況之前所討論的2%。如果該系統(tǒng)采用了一個(gè)主控制器(通常是一個(gè)單片機(jī)和PC機(jī)),使用一個(gè)標(biāo)準(zhǔn)100ppm晶體振蕩器的UART時(shí)鐘來(lái)源,差不多一半的鏈接錯(cuò)誤。小心微控制器綜合進(jìn)行內(nèi)部UARTs波特的頻率。根據(jù)選擇的單片機(jī)時(shí)鐘,波特率不可能準(zhǔn)確。如果錯(cuò)誤可以確定,它可以很容易地包含在鏈接錯(cuò)
溫馨提示
- 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 眾賞文庫(kù)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 數(shù)字時(shí)鐘外文翻譯
- 畢業(yè)論文----基于fpga的uart設(shè)計(jì)(含外文翻譯)
- 串行通訊原理說(shuō)明--rs232uart
- 外文翻譯----通訊連接項(xiàng)目
- 關(guān)于xxx同志確定為確定為發(fā)展對(duì)象群眾座談會(huì)議記錄全文
- 畢業(yè)論文--基于fpga的uart設(shè)計(jì)(含外文翻譯)
- 確定為積極分子當(dāng)時(shí)的主要表現(xiàn)
- 時(shí)鐘模塊外文文獻(xiàn)及翻譯
- 外文翻譯資料---電子時(shí)鐘設(shè)計(jì)
- 確定為入黨積極分子主要表現(xiàn)
- 基于時(shí)鐘精度差和小波分析的時(shí)鐘同步.pdf
- 外文翻譯-- 數(shù)控機(jī)床精度的檢測(cè)
- 確定為入黨積極分子情況公示表
- 2022確定為發(fā)展對(duì)象思想?yún)R報(bào)
- 確定為入黨積極分子會(huì)議議程
- 外文翻譯----等精度頻率計(jì)
- 外文翻譯--高精度頻率計(jì)
- 電子時(shí)鐘畢業(yè)設(shè)計(jì)(含外文翻譯)
- 外文翻譯--高精度頻率計(jì)
- 外文翻譯--- 高精度溫度測(cè)量裝置的設(shè)計(jì)
評(píng)論
0/150
提交評(píng)論