<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>licheng</author_name>
  <author_url>https://blog.hatena.ne.jp/licheng/</author_url>
  <blog_title>滴了庵日録</blog_title>
  <blog_url>https://lipoyang.hatenablog.com/</blog_url>
  <categories>
    <anon>プログラミング</anon>
  </categories>
  <description>バッファのフラッシュは大事ですね。通信相手の挙動が怪しいときは特に。 // Linuxのシリアル通信プログラムの一部 #include &lt;sys/types.h&gt; #include &lt;sys/stat.h&gt; #include &lt;fcntl.h&gt; #include &lt;termios.h&gt; #include &lt;unistd.h&gt; ... // シリアルポートのハンドラ int handle; if((handle = open(&quot;/dev/tty0&quot;, O_RDWR | O_NOCTTY | O_NONBLOCK))==-1){ printf(&quot;Can not open /dev/tty0\n&quot;)…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Flipoyang.hatenablog.com%2Fentry%2F20140516%2Fp2&quot; title=&quot;シリアル通信のバッファのフラッシュ - 滴了庵日録&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2014-05-16 00:00:01</published>
  <title>シリアル通信のバッファのフラッシュ</title>
  <type>rich</type>
  <url>https://lipoyang.hatenablog.com/entry/20140516/p2</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
