📄 linux 下串口编程入门.htm
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0067)http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html -->
<HTML><HEAD><TITLE>Linux 下串口编程入门</TITLE><!--XSLT stylesheet used to transform this file: dw-document-html-4.1.xsl-->
<META http-equiv=Content-Type content="text/html; charset=UTF-8">
<META http-equiv=PICS-Label
content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))'>
<META http-equiv=Expires content=0>
<META content="Linux, 串口编程" name=KEYWORDS>
<META content="Linux 操作系统从一开始就对串行口提供了很好的支持,本文就 Linux 下的串行口通讯编程进行简单的介绍。"
name=ABSTRACT>
<META content="Linux 操作系统从一开始就对串行口提供了很好的支持,本文就 Linux 下的串行口通讯编程进行简单的介绍。"
name=DESCRIPTION>
<META
content=https://www-130.ibm.com/developerworks/secure/feedback.jsp?domain=dwchina
name=OWNER>
<META scheme=iso8601 content=2003-07-03 name=DC.Date>
<META scheme=rfc1766 content=zh-cn name=DC.Language>
<META content=cn name=IBM.Country>
<META content="" name="Last update">
<META content=Public name=SECURITY>
<META content="Copyright (c) 2003 by IBM Corporation" name=DC.Rights>
<META content=index,follow name=ROBOTS>
<SCRIPT language=JavaScript src="Linux 下串口编程入门.files/dwcss.js"
type=text/javascript><noscript><link type="text/css" href="/developerworks/cn/css/r1ss.css" rel="stylesheet"/></noscript><script src="/developerworks/js/spinbox.js" language="JavaScript" type="text/javascript"></SCRIPT>
<SCRIPT language=JavaScript
type=text/javascript>var title = "Linux 下串口编程入门"; </SCRIPT>
<SCRIPT language=JavaScript type=text/javascript>var forumURL = ""; </SCRIPT>
<SCRIPT language=JavaScript
type=text/javascript>var contentAreaList = ""; </SCRIPT>
<SCRIPT language=JavaScript src="Linux 下串口编程入门.files/forumwindow.js"
type=text/javascript></SCRIPT>
<SCRIPT language=JavaScript type=text/javascript>var emailAbstract = "Linux 操作系统从一开始就对串行口提供了很好的支持,本文就 Linux 下的串行口通讯编程进行简单的介绍。"; </SCRIPT>
<SCRIPT language=JavaScript src="Linux 下串口编程入门.files/grabtitle.js"
type=text/javascript></SCRIPT>
<SCRIPT language=JavaScript src="" type=text/javascript></SCRIPT>
<META content="MSHTML 6.00.2600.0" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff leftMargin=2 topMargin=2 marginheight="2" marginwidth="2">
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR vAlign=top>
<TD class=bbg width=110><A href="http://www.ibm.com/cn/"><IMG height=52
alt=IBM® src="Linux 下串口编程入门.files/ibm-logo.gif" width=110 border=0></A></TD>
<TD class=bbg><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=1
border=0></TD>
<TD class=mbbg align=right width=650>
<TABLE cellSpacing=0 cellPadding=0 align=right border=0>
<TBODY>
<TR class=cty-tou>
<TD class=upper-masthead-corner width=17 rowSpan=2><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#main"><IMG
height=1 alt="Skip to main content" src="Linux 下串口编程入门.files/c.gif"
width=1 border=0></A></TD>
<TD align=left>
<TABLE cellSpacing=0 cellPadding=0 align=left border=0>
<TBODY>
<TR>
<TD><SPAN class=spacer> </SPAN><B
class=country>中国</B><SPAN class=spacer> [</SPAN> <A
class=ur-link
href="http://www.ibm.com/developerworks/cn/country/">选择</A><SPAN
class=spacer>]</SPAN></TD>
<TD class=upper-masthead-divider
width=29> </TD>
<TD align=left><A class=ur-link
href="http://www.ibm.com/legal/cn/">使用条款</A></TD></TR></TBODY></TABLE></TD>
<TD width=40> </TD></TR>
<TR>
<TD class=cty-tou-border colSpan=2 height=1><IMG height=1 alt=""
src="Linux 下串口编程入门.files/c.gif" width=1></TD></TR>
<TR>
<TD colSpan=3><IMG height=8 alt="" src="Linux 下串口编程入门.files/c.gif"
width=1></TD></TR>
<TR>
<TD> </TD>
<TD align=middle colSpan=2>
<FORM id=form1 name=form1
action=http://www-128.ibm.com/developerworks/search/searchResults.jsp
method=get><INPUT type=hidden value=1 name=searchType><INPUT
type=hidden value=dWChina name=searchSite><INPUT type=hidden
value=zh name=pageLang><INPUT type=hidden value=UTF8
name=langEncoding>
<TABLE cellSpacing=0 cellPadding=0 border=0>
<TBODY>
<TR>
<TD width=1><IMG height=1 alt="Select a scope:"
src="Linux 下串口编程入门.files/c.gif" width=1></TD>
<TD align=right><LABEL for=sq><SELECT class=input-scope id=sq
name=searchScope> <OPTION value=dW selected>dW 全部内容</OPTION>
<OPTION value=dW>-----------------</OPTION> <OPTION
value=dmdd> DB2</OPTION> <OPTION
value=lotusdd> Lotus</OPTION> <OPTION
value=tivolidd> Tivoli</OPTION> <OPTION
value=wsdd> WebSphere</OPTION> <OPTION
value=dW>-----------------</OPTION> <OPTION
value=javaZ> Java 技术</OPTION> <OPTION
value=linuxZ> Linux</OPTION> <OPTION
value=opensrcZ> Open source</OPTION> <OPTION
value=securityZ> Security</OPTION> <OPTION
value=webservZ> SOA & Web services</OPTION>
<OPTION value=webarchZ> Web architecture</OPTION>
<OPTION value=wirelessZ> Wireless</OPTION>
<OPTION value=xmlZ> XML</OPTION> <OPTION
value=dW>-----------------</OPTION> <OPTION value=all>IBM
全部内容</OPTION></SELECT> </LABEL></TD>
<TD align=right width=1><IMG height=1 alt="Search for:"
src="Linux 下串口编程入门.files/c.gif" width=1> </TD>
<TD align=right><INPUT class=input id=q maxLength=100 size=15
name=query> </TD>
<TD width=7> </TD>
<TD><LABEL for=q><INPUT type=image alt=搜索
src="Linux 下串口编程入门.files/search.gif" value=搜索 name=Search>
</LABEL></TD>
<TD
width=20> </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR>
<TR>
<TD class=blbg colSpan=3>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=0 border=0>
<TBODY>
<TR>
<TD><SPAN class=spacer> </SPAN> </TD>
<TD><A class=masthead-mainlink
href="http://www.ibm.com/cn/">首页</A> </TD>
<TD class=masthead-divider
width=27> </TD>
<TD><A class=masthead-mainlink
href="http://www.ibm.com/products/cn/">产品</A> </TD>
<TD class=masthead-divider
width=27> </TD>
<TD><A class=masthead-mainlink
href="http://www.ibm.com/servicessolutions/cn/">服务与解决方案</A>
</TD>
<TD class=masthead-divider
width=27> </TD>
<TD><A class=masthead-mainlink
href="http://www.ibm.com/support/cn/">支持与下载</A> </TD>
<TD class=masthead-divider
width=27> </TD>
<TD><A class=masthead-mainlink
href="http://www.ibm.com/account/cn/">个性化服务</A> </TD>
<TD><SPAN class=spacer> </SPAN>
</TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE><!--
<script src="//www.ibm.com/common/v14/pmh.js" language="JavaScript" type="text/javascript"></script>
--><!-- end masthead dw liquid -->
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR vAlign=top>
<TD width=5><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=5
border=0></TD>
<TD width="100%">
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR vAlign=top>
<TD width="100%"><IMG height=4 alt=""
src="Linux 下串口编程入门.files/c.gif" width=2 border=0><BR><A class=bctl
href="http://www-128.ibm.com/developerworks/cn/">developerWorks
中国</A><SPAN class=bct> > </SPAN><A class=bctl
href="http://www-128.ibm.com/developerworks/cn/linux/">Linux</A>
<SPAN class=bct>> </SPAN></TD>
<TD align=right width=136><A
href="http://www-128.ibm.com/developerworks/cn/"><IMG height=24
alt=developerWorks src="Linux 下串口编程入门.files/dwlogo-small.gif"
width=136 border=0></A></TD>
<TD width=5><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif"
width=5 border=0></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE><A
name=main></A><A name=top></A>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR vAlign=top>
<TD colSpan=5><IMG height=15 alt="" src="Linux 下串口编程入门.files/c.gif"
width=5 border=0></TD></TR>
<TR vAlign=top>
<TD width=2><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=2
border=0></TD>
<TD><SPAN class=atitle>Linux 下串口编程入门</SPAN></TD>
<TD width=8><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=8
border=0></TD>
<TD align=right width=180><NOBR>
<TABLE cellSpacing=0 cellPadding=0>
<TBODY>
<TR vAlign=top>
<TD align=right></TD>
<TD width=46>
<FORM
action=https://www-130.ibm.com/developerworks/secure/email-it.jsp><INPUT
type=hidden
value="Linux 操作系统从一开始就对串行口提供了很好的支持,本文就 Linux 下的串行口通讯编程进行简单的介绍。"
name=body><INPUT type=hidden value="Linux 下串口编程入门"
name=subject><INPUT type=hidden value=cn name=lang><INPUT type=image
src="Linux 下串口编程入门.files/icon-email.gif" border=0
name=email></FORM></TD></TR></TBODY></TABLE></NOBR></TD>
<TD width=6><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=6
border=0></TD></TR>
<TR vAlign=top>
<TD bgColor=#000000 colSpan=5><IMG height=1 alt=""
src="Linux 下串口编程入门.files/c.gif" width=100 border=0></TD></TR>
<TR vAlign=top>
<TD bgColor=#ffffff colSpan=5><IMG height=8 alt=""
src="Linux 下串口编程入门.files/c.gif" width=100 border=0></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR vAlign=top>
<TD width=5><IMG height=1 alt="" src="Linux 下串口编程入门.files/c.gif" width=5
border=0></TD>
<TD width="100%">
<TABLE cellSpacing=0 cellPadding=0 width=168 align=right border=0>
<TBODY>
<TR>
<TD width=8><IMG height=21 alt="" src="Linux 下串口编程入门.files/c.gif"
width=5></TD>
<TD width=160>
<TABLE cellSpacing=0 cellPadding=0 width=160 border=0>
<TBODY>
<TR>
<TD width=160 bgColor=#000000 height=1><IMG height=1 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD align=middle background="Linux 下串口编程入门.files/bg-gold.gif"
height=5><B>内容:</B></TD></TR>
<TR>
<TD width=160 bgColor=#666666 height=1><IMG height=1 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=0 width=160 border=0>
<TBODY>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N10049">串口简介</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N1014A">串口操作</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N1015C">打开串口</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N10177">设置串口</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N10232">读写串口</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N10252">关闭串口</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#N10264">例子</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR><!--Standard links for every dw-article-->
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#resources">参考资料
</A></TD></TR>
<TR>
<TD height=1><IMG height=5 alt=""
src="Linux 下串口编程入门.files/c.gif" width=160></TD></TR>
<TR>
<TD><A
href="http://www-128.ibm.com/developerworks/cn/linux/l-serials/index.html#author1">关于作者</A></TD></TR>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -