顯示具有 putty 標籤的文章。 顯示所有文章
顯示具有 putty 標籤的文章。 顯示所有文章

【Ubuntu】putty


在Linux底下,通常都是使用 minicom 來做uart(rs-232)端的通訊工具,不過使用 Putty 也可以達到一樣的功能。

另外putty也有提供ssh的連線功能,非常的簡單直覺,應該都沒什問題,所以就不說了。

我這次是在 VMware 裡面用實體com port 作連線。

【設定】
先把實體 com port mapping 到 vm,如果你是用usb-to-serial cable的話,應該可以跳過。

  1. 選 Use physical port on the host
    image 
  2. 用的是 com1
    image
  3. 加好了
    image

【下載】

  1. 抓一下 putty.exe
    $ wget http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe
  2. 作一個 software link,等等 putty 用的是 com1,也就是實體的 /dev/ttyS0。
    $ ln -s /dev/ttyS0 ~/.wine/dosdevices/com1 
  3. 補充#2,如果是 usb-to-serial cable的話,應該是
    $ln –s /dev/ttyUSB0 ~/.wine/dosdevices/com1
    其中的ttyUSB*,應該針對你的裝置號碼自行更改。
  4. 看看#3的結果,會發現有了一個com1
    $ ls ~/.wine/dosdevices/
    c:  com1  d::  e::  z:

【啟動】

  1. 使用下面指令,用 wine 帶起putty
    $ wine putty.exe
  2. 設一下相對於Target的Baudrate,我的是 com1/57600
    image
  3. 連線成功,Tx/Rx 進來出去都OK。
    image

【設定】

  1. Implicit CR in every LF,把LF延伸成 \r\n
    image
  2. 若有存檔需求,按照你的需求勾選。
    image

Putty 的換行和 log


1. 換行 Putty/Category/Terminal/Implicit CR in every LF 打勾 http://cc-ipcp.icp.ac.ru/Section3.2.html #3.2.3 "Implicit CR in every LF" 2. 打開log Putty/Session/Logging/Session Logging/All session output 打勾 記的Log file name 也須指定 http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter4.html#config-logging
 

Ed32. Copyright 2008 All Rights Reserved Revolution Two Church theme by Brian Gardner Converted into Blogger Template by Bloganol dot com