<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>mocchipa</author_name>
  <author_url>https://blog.hatena.ne.jp/mocchipa/</author_url>
  <blog_title>Rich Richer Richest</blog_title>
  <blog_url>https://www.richardh.work/</blog_url>
  <categories>
    <anon>Raspberry pi</anon>
  </categories>
  <description>LED制御のプログラムをpythonでプログラミングしたんですが、LEDが付きっぱなしになっちゃう問題が起こり解決したのでシェアします。 ctl + C でプログラムを強制終了した際、2度目に動かすとエラーがでて2度目はプログラムを実行できないばかりかLEDがつながったポートがHIGHになりっぱなしで困ってしまいました。 解決策は トライキャッチの処理をいれる事でした。 try: while True: #異常信号検知でLED点灯 if GPIO.input(PIN_ART) == GPIO.HIGH : GPIO.output(PIN_LED , GPIO.HIGH) #リセットボタンが押さ…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fwww.richardh.work%2Fentry%2F2020%2F03%2F21%2F193952&quot; title=&quot;【備忘録】GPIOを制御するときはGPIOを解放を忘れずに - Rich Richer Richest&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>https://cdn-ak.f.st-hatena.com/images/fotolife/m/mocchipa/20200321/20200321161500.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-03-21 19:39:52</published>
  <title>【備忘録】GPIOを制御するときはGPIOを解放を忘れずに</title>
  <type>rich</type>
  <url>https://www.richardh.work/entry/2020/03/21/193952</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
