{"id":10116,"date":"2020-10-06T09:00:00","date_gmt":"2020-10-06T00:00:00","guid":{"rendered":"http:\/\/www.mizutan.com\/wordpress\/?p=10116"},"modified":"2025-03-23T12:27:20","modified_gmt":"2025-03-23T03:27:20","slug":"post-10116","status":"publish","type":"post","link":"https:\/\/www.mizutan.com\/wordpress\/?p=10116","title":{"rendered":"yahoo!\u5929\u6c17rss\u30c7\u30fc\u30bf\u3068\u5929\u6c17\u30de\u30fc\u30af\u8ffd\u52a0\u3067\u96fb\u5149\u63b2\u793a\u677f\u5929\u6c17\u4e88\u5831\u8868\u793aPG\u30ea\u30d7\u30ec\u30fc\u30b9"},"content":{"rendered":"\n<p>livedoor \u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u914d\u4fe1\u306e\u30b5\u30fc\u30d3\u30b9\u304c\uff17\u670831\u65e5\u306b\u7d42\u4e86\u3057\u305f\u3053\u3068\u3067\u3001\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u304c\u51fa\u6765\u306a\u304f\u306a\u308a\u3001\u304b\u3064\u3001\u96fb\u5149\u63b2\u793a\u677f\u3078\u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u8868\u793a\u304c\u3001\u305a\u3063\u3068\uff17\u670831\u65e5\u306e\u3082\u306e\u306b\u306a\u3063\u305f\u4ef6\u306f\u3001<a href=\"https:\/\/www.mizutan.com\/wordpress\/?p=10106\" data-type=\"post\" target=\"_blank\" rel=\"noreferrer noopener\">\u5148\u306e\u8a18\u4e8b<\/a>\u3067\u304a\u77e5\u3089\u305b\u3057\u307e\u3057\u305f\u3002<br><br>\u5929\u6c17\u4e88\u5831\u306e\u914d\u4fe1\u304c\u6b21\u3005\u3068\u6b62\u307e\u308a\u3001\u305d\u306e\u5ea6\u3054\u3068\u306b\u624b\u3092\u5165\u308c\u308b\u306e\u306f\u9762\u5012\u304f\u3055\u304f\u3066\u3057\u3088\u3046\u304c\u306a\u3044\u3093\u3067\u3059\u304c\u4f7f\u7528\u304c\u3042\u308a\u307e\u305b\u3093\u3002<br><br>\u3053\u306e\u969b\u3001\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u306ePython\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u8a02\u6b63\u3057\u3001\u5929\u6c17\u4e88\u5831\u306b\u3064\u3044\u3066\u306f\u7121\u4e8b\u558b\u3063\u3066\u304f\u308c\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\u3002<br><br>\u7d9a\u3051\u3066\u3001\u96fb\u5149\u63b2\u793a\u677f\u3078\u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u8868\u793a\u306b\u3064\u3044\u3066\u306e\u8a02\u6b63\u3092\u5b9f\u65bd\u3057\u307e\u3059\u3002<br><br>\u662f\u975e\u3001\u5185\u5bb9\u3092\u3054\u89a7\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<!-- WP QUADS v. 2.0.98  Shortcode Ad -->\n<div class=\"quads-location quads-ad\" id=\"quads-ad\" style=\"float:none;margin:0px 0 0px 0;text-align:center;\">\n\u30b9\u30dd\u30f3\u30b5\u30fc\u30ea\u30f3\u30af\r\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-1169427325398969\"\r\n     crossorigin=\"anonymous\"><\/script>\r\n<!-- www_\u30a4\u30f3\u30c8\u30ed -->\r\n<ins class=\"adsbygoogle\"\r\n     style=\"display:block\"\r\n     data-ad-client=\"ca-pub-1169427325398969\"\r\n     data-ad-slot=\"1208333098\"\r\n     data-ad-format=\"rectangle\"\r\n     data-full-width-responsive=\"true\"><\/ins>\r\n<script>\r\n     (adsbygoogle = window.adsbygoogle || []).push({});\r\n<\/script><br><\/div>\n\n\n\n\n<h2 class=\"wp-block-heading is-style-vk-heading-double_black\">\u96fb\u5149\u63b2\u793a\u677f\u5929\u6c17\u4e88\u5831PG\u30ea\u30d7\u30ec\u30fc\u30b9<\/h2>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"300\" src=\"https:\/\/www.mizutan.com\/wordpress\/wp-content\/uploads\/2019\/03\/tenki3.jpg\" alt=\"\" class=\"wp-image-7574\"\/><\/figure>\n<\/div>\n\n\n<p>\u3055\u3066\u3001\u96fb\u5149\u63b2\u793a\u677f\u5929\u6c17\u4e88\u5831\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u8a02\u6b63\u7b87\u6240\u3067\u3059\u304c\u6b21\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u30c7\u30fc\u30bf\u53d6\u51fa\u3057\u90e8\u5206<\/strong><\/li>\n\n\n\n<li><strong>\u304a\u5929\u6c17\u30de\u30fc\u30af\u8ffd\u52a0<\/strong><\/li>\n\n\n\n<li><strong>\u304a\u5929\u6c17\u30de\u30fc\u30af\u691c\u7d22\u51e6\u7406<\/strong><\/li>\n\n\n\n<li><strong>title\u8a02\u6b63<\/strong><\/li>\n\n\n\n<li><strong>\u305d\u306e\u4ed6\u306e\u5bfe\u5fdc<\/strong><\/li>\n<\/ol>\n\n\n\n<p>\u305d\u308c\u305e\u308c\u306e\u8a02\u6b63\u7b87\u6240\u306b\u3064\u3044\u3066\u7d30\u304b\u304f\u89e3\u8aac\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u30c7\u30fc\u30bf\u53d6\u51fa\u3057\u90e8\u5206<\/h3>\n\n\n\n<p>rss\u5f62\u5f0f\u306e\u30c7\u30fc\u30bf\u3092\u53d6\u51fa\u3059\u90e8\u5206\u3067\u3059\u304c\u3001\u3053\u3061\u3089\u306f\u3001\u524d\u56de\u8a18\u4e8b\u3068\u540c\u69d8\u306b\u3001\u53c2\u8003\u8cc7\u6599\u2461\u306e\u5185\u5bb9\u3092\u4e38\u3005\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u3067\u53ef\u80fd\u3067\u3059\u3002<br><br>\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u3068\u5168\u304f\u540c\u3058\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-vk-blocks-alert vk_alert alert alert-info\"><div class=\"vk_alert_content\">\n<p>\u3010\u8a02\u6b63\u524d\u3011<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-python\" data-lang=\"Python\"><code>    json_url = &#39;https:\/\/weather.livedoor.com\/forecast\/webservice\/json\/v1&#39; #API URL\n\n        r =  urllib.request.urlopen(&#39;%s?city=%s&#39; % (json_url, city) )\n        obj = json.loads( r.read().decode(&#39;utf-8&#39;) )<\/code><\/pre><\/div>\n\n\n\n<div class=\"wp-block-vk-blocks-alert vk_alert alert alert-info\"><div class=\"vk_alert_content\">\n<p>\u3010\u8a02\u6b63\u5f8c\u3011<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-python\" data-lang=\"Python\"><code>## Parser : \u5929\u6c17\u60c5\u5831Web\u30da\u30fc\u30b8\u306eHTML\u30bf\u30b0\u304b\u3089\u5929\u6c17\u60c5\u5831\u3092\u62bd\u51fa\u3057\u3066\u30d1\u30fc\u30b9\u3059\u308b\u30e1\u30bd\u30c3\u30c9 ####################\ndef Parser(rssurl):\n   with urllib.request.urlopen(rssurl) as res:\n      xml = res.read()\n      soup = BeautifulSoup(xml, &quot;html.parser&quot;)\n      for item in soup.find_all(&quot;item&quot;):\n         title = item.find(&quot;title&quot;).string\n         description = item.find(&quot;description&quot;).string\n         if title.find(&quot;[ PR ]&quot;) == -1:\n            tenki.append(title)\n            detail.append(description)\n\n### Execute\n# \u62bd\u51fa\u5bfe\u8c61\u306eRSS(\u795e\u5948\u5ddd\u770c\u6a2a\u6d5c\u5e02)\nrssurl = &quot;https:\/\/rss-weather.yahoo.co.jp\/rss\/days\/4610.xml&quot;<\/code><\/pre><\/div>\n\n\n\n<p>\u3054\u89a7\u306e\u3088\u3046\u306b\u3001\u30b3\u30fc\u30c9\u304c\u30ac\u30e9\u30c3\u3068\u5909\u308f\u308a\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<!-- WP QUADS v. 2.0.98  Shortcode Ad -->\n<div class=\"quads-location quads-ad\" id=\"quads-ad\" style=\"float:none;margin:0px 0 0px 0;text-align:center;\">\n\u30b9\u30dd\u30f3\u30b5\u30fc\u30ea\u30f3\u30af\r\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-1169427325398969\"\r\n     crossorigin=\"anonymous\"><\/script>\r\n<ins class=\"adsbygoogle\"\r\n     style=\"display:block; text-align:center;\"\r\n     data-ad-layout=\"in-article\"\r\n     data-ad-format=\"fluid\"\r\n     data-ad-client=\"ca-pub-1169427325398969\"\r\n     data-ad-slot=\"8169621401\"><\/ins>\r\n<script>\r\n     (adsbygoogle = window.adsbygoogle || []).push({});\r\n<\/script><br><\/div>\n\n\n\n\n<h3 class=\"wp-block-heading\">\u304a\u5929\u6c17\u30de\u30fc\u30af\u306e\u8ffd\u52a0<\/h3>\n\n\n\n<p>\u4ee5\u524d\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u306f\u3001json\u5f62\u5f0f\u306e\u4e2d\u306b\u3042\u308b\u304a\u5929\u6c17\u30de\u30fc\u30af\u3092\u53d6\u308a\u8fbc\u3080\u3053\u3068\u304c\u51fa\u6765\u305f\u306e\u3067\u3059\u304c\u3001<span data-color=\"#ffff00\" style=\"background: linear-gradient(transparent 60%,rgba(255, 255, 0, 0.7) 0);\" class=\"vk_highlighter\">Yahoo!\u5929\u6c17\u306e rss\u5f62\u5f0f\u306e\u30c7\u30fc\u30bf\u306b\u306f\u3001\u304a\u5929\u6c17\u30de\u30fc\u30af\u304c\u306a\u3044\u305f\u3081\u3001\u53d6\u308a\u8fbc\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u305b\u3093\u3002<\/span><br><br>\u305d\u306e\u305f\u3081\u3001<strong><mark style=\"background-color:rgba(0, 0, 0, 0);color:#fe0000\" class=\"has-inline-color\">\u81ea\u5206\u3067\u304a\u5929\u6c17\u30de\u30fc\u30af\u3092\u6e96\u5099\u3059\u308b\u5fc5\u8981<\/mark><\/strong>\u304c\u3042\u308a\u307e\u3059\u3002<br><br>60\u723a\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u304a\u5929\u6c17\u30de\u30fc\u30af\u3092\u4f5c\u6210\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"320\" height=\"242\" src=\"https:\/\/www.mizutan.com\/wordpress\/wp-content\/uploads\/2020\/08\/mark.jpg\" alt=\"\" class=\"wp-image-10117\" srcset=\"https:\/\/www.mizutan.com\/wordpress\/wp-content\/uploads\/2020\/08\/mark.jpg 320w, https:\/\/www.mizutan.com\/wordpress\/wp-content\/uploads\/2020\/08\/mark-300x227.jpg 300w\" sizes=\"auto, (max-width: 320px) 100vw, 320px\" \/><\/figure>\n<\/div>\n\n\n<p>\u6e96\u5099\u304c\u51fa\u6765\u305f\u3089\u3001<strong>\u304a\u5929\u6c17\u30de\u30fc\u30af\u7528\u306e\u30d5\u30a9\u30eb\u30c0\u3092\u7528\u610f\u3057\u683c\u7d0d<\/strong>\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u304a\u5929\u6c17\u30de\u30fc\u30af\u691c\u7d22\u51e6\u7406<\/h3>\n\n\n\n<p>\u6b21\u306b\u3001\u53c2\u8003\u8cc7\u6599\u2461\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u4e00\u90e8\u3092\u501f\u7528\u3057\u3001<strong><mark style=\"background-color:rgba(0, 0, 0, 0);color:#fe0000\" class=\"has-inline-color\">\u4eca\u65e5\u306e\u5929\u6c17\u3001\u660e\u65e5\u306e\u5929\u6c17\u304b\u3089\u8a72\u5f53\u3059\u308b\u304a\u5929\u6c17\u30de\u30fc\u30af\u3092\u691c\u7d22\u3059\u308b\u51e6\u7406\u3092\u4f5c\u6210<\/mark><\/strong>\u3057\u307e\u3059\u3002<br><br>60\u723a\u306f\u3001<strong>\u304a\u5929\u6c17\u30de\u30fc\u30af\u691c\u7d22\u5f8c\u3001\u51fa\u529b\u30d5\u30a1\u30a4\u30eb\u306b\u66f8\u304d\u51fa\u3059<\/strong>\u3088\u3046\u306b\u3057\u307e\u3057\u305f\u3002<br><br>\u691c\u7d22\u51e6\u7406\u306f\u6b21\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\uff08<span data-color=\"#ffff00\" style=\"background: linear-gradient(transparent 60%,rgba(255, 255, 0, 0.7) 0);\" class=\"vk_highlighter\">\u53c2\u8003\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u5929\u6c17\u306b\u8a72\u5f53\u3057\u306a\u3044\u6587\u8a00\u304c\u6765\u305f\u969b\u3001\u4f55\u6545\u304b\u300c\u66b4\u98a8\u96e8\u300d\u30de\u30fc\u30af\u304c\u51fa\u308b\u306e\u3067\u3001\u78ba\u8a8d\u3057\u305f\u3068\u3053\u308d\u3001\u300c\u66b4\u98a8\u96e8\u300d\u3068\u300c\u66b4\u98a8\u96ea\u300d\u306e\u5224\u5b9a\u6761\u4ef6\u306b\u8aa4\u308a\u304c\u3042\u308a\u307e\u3057\u305f<\/span>\u306e\u3067\u8a02\u6b63\u3057\u307e\u3057\u305f\uff09\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-python\" data-lang=\"Python\"><code>## ck_Weather : \u53d6\u5f97\u3057\u305f\u5929\u6c17\u60c5\u5831\u3068\u305d\u308c\u306b\u5fdc\u3058\u305f\u30a2\u30a4\u30b3\u30f3\u3092\u51fa\u529b\u3059\u308b\u30e1\u30bd\u30c3\u30c9 ################################\ndef ck_Weather(i, detail):\n\n   if (detail[i].find(&quot;\u6674&quot;)) != -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Sun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;SunToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;SunToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;SunToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Cloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;CloudToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;CloudToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;CloudToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Rain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;RainToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;RainToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;RainToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1:\n       files = icon_path + &quot;Snow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;SnowToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;SnowToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;SnowToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66b4\u98a8\u96e8&quot;)) != -1:\n       files = icon_path + &quot;Typhon.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66b4\u98a8\u96ea&quot;)) != -1:\n       files = icon_path + &quot;HeavySnow.jpg&quot;\n\n   else:\n       files = icon_path + &quot;404.jpg&quot;\n\n\n   print(&#39;icon=&#39;,files)\n   if i == 0:\n       cmd = &quot;convert %s \/home\/pi\/work\/file3.jpg&quot; % files\n       res = subprocess.call( cmd.strip().split(&quot; &quot;) )\n       print(&#39;file3.gif&#39;)\n   else:\n       cmd = &quot;convert %s \/home\/pi\/work\/file5.jpg&quot; % files\n       res = subprocess.call( cmd.strip().split(&quot; &quot;) )\n       print(&#39;file5.gif&#39;)<\/code><\/pre><\/div>\n\n\n\n<p>\u307e\u305f\u3001\u5224\u5b9a\u4ee5\u5916\u306e\u30c7\u30fc\u30bf\u304c\u6765\u305f\u3068\u304d\u306f\u3001404.jpg\uff08\u4e0a\u8a18\u304a\u5929\u6c17\u30de\u30fc\u30af\u306e\u5148\u982d\u306b\u3042\u308b\u6ce2\u306e\u30de\u30fc\u30af\u3067\u3059\uff09\u3092\u8868\u793a\u3059\u308b\u3088\u3046\u306b\u3057\u307e\u3057\u305f\u3002<br><br>\u304a\u305d\u3089\u304f\u3001\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u30df\u30b9\u4ee5\u5916\u306f\u3042\u308a\u3048\u306a\u3044\u306f\u305a\u3067\u3059\u304c\u2025\u3002<\/p>\n\n\n\n<!-- WP QUADS v. 2.0.98  Shortcode Ad -->\n<div class=\"quads-location quads-ad\" id=\"quads-ad\" style=\"float:none;margin:0px 0 0px 0;text-align:center;\">\n\u30b9\u30dd\u30f3\u30b5\u30fc\u30ea\u30f3\u30af\r\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-1169427325398969\"\r\n     crossorigin=\"anonymous\"><\/script>\r\n<ins class=\"adsbygoogle\"\r\n     style=\"display:block; text-align:center;\"\r\n     data-ad-layout=\"in-article\"\r\n     data-ad-format=\"fluid\"\r\n     data-ad-client=\"ca-pub-1169427325398969\"\r\n     data-ad-slot=\"9186857477\"><\/ins>\r\n<script>\r\n     (adsbygoogle = window.adsbygoogle || []).push({});\r\n<\/script><\/div>\n\n\n\n\n<h3 class=\"wp-block-heading\">title \u8a2d\u5b9a<\/h3>\n\n\n\n<p>title \u306b\u3064\u3044\u3066\u306f\u3001\u5148\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u30ea\u30d7\u30ec\u30fc\u30b9\u3067\u3082\u8ff0\u3079\u307e\u3057\u305f\u304c\u3001<strong><mark style=\"background-color:rgba(0, 0, 0, 0);color:#fe0000\" class=\"has-inline-color\">livedoor\u306e\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u306a\u3044\u305f\u3081\u30ea\u30c6\u30e9\u30eb\u3067\u5bfe\u5fdc<\/mark><\/strong>\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-python\" data-lang=\"Python\"><code>    title = u&#39;\u795e\u5948\u5ddd\u770c\u6a2a\u6d5c\u306e\u5929\u6c17&#39;<\/code><\/pre><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">\u305d\u306e\u4ed6\u306e\u5bfe\u5fdc<\/h3>\n\n\n\n<p>\u96fb\u5149\u63b2\u793a\u677f\u306e\u8868\u793a\u3092\u884c\u3063\u3066\u3044\u308b\u30e9\u30ba\u30d1\u30a4\u306f\u3001\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u306e\u30e9\u30ba\u30d1\u30a4\u3068\u9055\u3046\u3082\u306e\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002<br><br>\u3053\u306e\u305f\u3081\u3001\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u3067\u5b9f\u65bd\u3057\u305f  BeautifulSoup \u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3092\u5b9f\u65bd\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-bash\" data-lang=\"Bash\"><code>sudo pip3 install beautifulsoup4<\/code><\/pre><\/div>\n\n\n\n<h2 class=\"wp-block-heading is-style-vk-heading-double_black\">\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u8ffd\u52a0\u8868\u793a<\/h2>\n\n\n\n<p><strong>\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u3067\u884c\u3063\u305f\u3088\u3046\u306b\u3001\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u8ffd\u52a0\u8868\u793a\u3092\u8ffd\u52a0<\/strong>\u3057\u3088\u3046\u3068\u601d\u3044\u307e\u3059\u3002<br><br>\u305d\u306e\u305f\u3081\u3001<strong><mark style=\"background-color:rgba(0, 0, 0, 0);color:#fe0000\" class=\"has-inline-color\">\u5929\u6c17\u4e88\u5831\u8868\u793a\u7528\u306e\u30b7\u30a7\u30eb\u3092\u898b\u76f4\u3057\u305f\u3093\u3067\u3059\u304c\u3001\u3061\u3087\u3063\u3068\u9762\u5012\u304f\u3055\u3044<\/mark><\/strong>\u3053\u3068\u304c\u308f\u304b\u308a\u307e\u3057\u305f\u3002<br><br>\u305d\u306e\u7406\u7531\u3092\u8ff0\u3079\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u5929\u6c17\u4e88\u5831\u8868\u793a\u306e\u624b\u9806<\/h3>\n\n\n\n<p>\u5929\u6c17\u4e88\u5831\u3092\u96fb\u5149\u63b2\u793a\u677f\u306b\u8868\u793a\u3059\u308b\u624b\u9806\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<br><br>\u3053\u308c\u3089\u306f\u30b7\u30a7\u30eb\u3068\u3057\u3066\u767b\u9332\u3055\u308c\u3001\u5b9a\u6642\u306b\u306a\u308b\u3068\u8d77\u52d5\u3055\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\uff1a10\u500b\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<\/strong><\/li>\n\n\n\n<li><strong>txt\u2192gif \u5909\u63db\uff1a\uff16\u500b\u306e txt \u30d5\u30a1\u30a4\u30eb\u3092 gif \u30d5\u30a1\u30a4\u30eb\u306b\u30b3\u30f3\u30d0\u30fc\u30c8<\/strong><\/li>\n\n\n\n<li><strong>border \u8ffd\u52a0\uff1a\u898b\u51fa\u3057\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u67a0\u3092\u8ffd\u52a0\u3057\u307e\u3059<\/strong><\/li>\n\n\n\n<li><strong>size change\uff1aborder\u8ffd\u52a0\u30d5\u30a1\u30a4\u30eb\u3001\u4eca\u65e5\u3001\u660e\u65e5\u306e\u304a\u5929\u6c17\u30de\u30fc\u30af\u306e\u30b5\u30a4\u30ba\u5909\u63db<\/strong><\/li>\n\n\n\n<li><strong>gif \u9023\u7d50\uff1a\u51fa\u6765\u4e0a\u304c\u3063\u305f\u30d5\u30a1\u30a4\u30eb10\u500b\u3092\u9023\u7d50\u3057\u3066\u8868\u793a\u7528\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210<\/strong><\/li>\n\n\n\n<li><strong>\u5929\u6c17\u4e88\u5831\u8868\u793a\uff1a\u8868\u793a\u7528\u30d5\u30a1\u30a4\u30eb\u3092\u96fb\u5149\u63b2\u793a\u677f\u306b\u6d41\u3059<\/strong><\/li>\n\n\n\n<li><strong>LED PANEL RESET\uff1a\u96fb\u5149\u63b2\u793a\u677f\u30ea\u30bb\u30c3\u30c8<\/strong><\/li>\n<\/ol>\n\n\n\n<p>1.\u3067\u8ff0\u3079\u305f\u30d7\u30ed\u30b0\u30e9\u30e0\u306f\u3001\u624b\u9806\u306e\u4e00\u756a\u982d\u306b\u3042\u308b\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u3067\u3059\u3002\u4e0a\u8ff0\u3057\u305f\u3088\u3046\u306b10\u500b\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059\u3002<br><br>\u3053\u3053\u3067\u51fa\u6765\u305f\u30d5\u30a1\u30a4\u30eb\u3092\u3001<span data-color=\"#ffff00\" style=\"background: linear-gradient(transparent 60%,rgba(255, 255, 0, 0.7) 0);\" class=\"vk_highlighter\">gif\u5909\u63db\u3001\u67a0\u4ed8\u3051\u3084\u30b5\u30a4\u30ba\u5909\u66f4\u3092\u884c\u3044\u3001\u6700\u5f8c\u306b\u9023\u7d50\u3057\u3066\u96fb\u5149\u63b2\u793a\u677f\u8868\u793a\u7528\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3057\u3066\u3044\u308b<\/span>\u308f\u3051\u3067\u3059\u3002<br><br>\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u306e\uff12\u9805\u76ee\u3092\u8ffd\u52a0\u3059\u308b\u306b\u306f\u6b21\u306e\u5909\u66f4\u304c\u5fc5\u8981\u3067\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u30d7\u30ed\u30b0\u30e9\u30e0\u5909\u66f4<\/strong><\/li>\n\n\n\n<li><strong>txt\u2192gif \u5909\u63db<\/strong><\/li>\n\n\n\n<li><strong>gif \u9023\u7d50<\/strong><\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u30d7\u30ed\u30b0\u30e9\u30e0\u5909\u66f4<\/h3>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0);color:#fe0000\" class=\"has-inline-color\">\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u306f\u3001\u660e\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u3068\u540c\u3058\u3088\u3046\u306b\u6c17\u6e29\u306b\u3088\u308a\u3001\u6587\u5b57\u8272\u3092\u5909\u3048\u308b\u5fc5\u8981<\/mark><\/strong>\u304c\u3042\u308a\u307e\u3059\u3002<br><br>\u305d\u306e\u305f\u3081\u3001<strong>\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\u3001\u6700\u4f4e\u6c17\u6e29\u3092\u51fa\u529b\u30d5\u30a1\u30a4\u30eb\uff08gif\uff09\u3068\u3057\u3066\u8ffd\u52a0<\/strong>\u3057\u307e\u3059\u3002<br><br>\u305d\u3057\u3066\u3001<span data-color=\"#ffff00\" style=\"background: linear-gradient(transparent 60%,rgba(255, 255, 0, 0.7) 0);\" class=\"vk_highlighter\">\u3053\u308c\u3089\uff12\u3064\u306e\u6c17\u6e29\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u3001\u30c6\u30ad\u30b9\u30c8\u5185\u5bb9\u306b\u5909\u66f4\u304c\u767a\u751f\u3059\u308b\u306e\u3067\u3001\u30d5\u30a1\u30a4\u30eb\u51fa\u529b\uff08\u8a02\u6b63\uff09\u304c\u5fc5\u8981<\/span>\u3067\u3059\u3002<br><br>\u4ee5\u4e0b\u3001\u51fa\u529b\u30d5\u30a1\u30a4\u30eb\u306e\u4e00\u89a7\u306b\u307e\u3068\u3081\u307e\u3059\u3002\u7d50\u5c40\u3001\u30d5\u30a1\u30a4\u30eb\u51fa\u529b\u306f 10 \u21d2 14 \u3068\u306a\u308a\u3001\uff14\u3064\u306e\u30d5\u30a1\u30a4\u30eb\u8ffd\u52a0\u306b\u306a\u308a\u307e\u3057\u305f\u3002<br><br>\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb\u8a02\u6b63\u306f\u3001\u3072\u3068\u3064\u3067\u6e08\u307f\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<figure class=\"wp-block-table is-style-vk-table-border-stripes\"><table><tbody><tr><td>file1.txt<\/td><td>\u201d8\u670820\u65e5\u300117\u66420\u520620\u79d2 \u795e\u5948\u5ddd\u770c\u6a2a\u6d5c\u306e\u5929\u6c17\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file2.txt<\/td><td>\u201d\u4eca\u65e5\u306e\u5929\u6c17\u306f\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file3.jpg<\/td><td>\u4eca\u65e5\u306e\u5929\u6c17\u306e\u5929\u6c17\u30de\u30fc\u30af<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file4.txt<\/td><td>\u201d\u3067\u3059\u3002\u4eca\u65e5\u306e\u4e88\u60f3\u6700\u9ad8\u6c17\u6e29\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\u8a02\u6b63<\/td><\/tr><tr><td>file4_1.gif<\/td><td>\u4eca\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\uff08\u8272\u4ed8\u304d\uff09<\/td><td class=\"has-text-align-center\" data-align=\"center\">\u8ffd\u52a0<\/td><\/tr><tr><td>file4_2.txt<\/td><td>\u201d\u3001\u4e88\u60f3\u6700\u4f4e\u6c17\u6e29\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\u8ffd\u52a0<\/td><\/tr><tr><td>file4_3.gif<\/td><td>\u4eca\u65e5\u306e\u6700\u4f4e\u6c17\u6e29\uff08\u8272\u4ed8\u304d\uff09<\/td><td class=\"has-text-align-center\" data-align=\"center\">\u8ffd\u52a0<\/td><\/tr><tr><td>file4_4.txt<\/td><td>\u201d\u3067\u3059\u3002\u660e\u65e5\u306e\u5929\u6c17\u306f\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\u8ffd\u52a0<\/td><\/tr><tr><td>file5.jpg<\/td><td>\u660e\u65e5\u306e\u5929\u6c17\u306e\u5929\u6c17\u30de\u30fc\u30af<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file6.txt<\/td><td>\u201d\u3067\u3059\u3002\u660e\u65e5\u306e\u4e88\u60f3\u6700\u9ad8\u6c17\u6e29\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file7.gif<\/td><td>\u660e\u65e5\u306e\u6700\u9ad8\u6c17\u6e29\uff08\u8272\u4ed8\u304d\uff09<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file8.txt<\/td><td>\u201d\u3001\u4e88\u60f3\u6700\u4f4e\u6c17\u6e29\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file9.gif<\/td><td>\u660e\u65e5\u306e\u6700\u4f4e\u6c17\u6e29\uff08\u8272\u4ed8\u304d\uff09<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><tr><td>file10.txt<\/td><td>\u201d\u3067\u3059\u3002\u201d<\/td><td class=\"has-text-align-center\" data-align=\"center\">\uff0d<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">txt\u2192gif \u5909\u63db<\/h3>\n\n\n\n<p>\u4e0a\u8a18\u4e00\u89a7\u3067\u8ffd\u52a0\u3068\u306a\u3063\u305f file4_2.txt \u53ca\u3073 file4_4.txt \u306e gif \u5909\u63db\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">gif \u9023\u7d50<\/h3>\n\n\n\n<p>\u8ffd\u52a0\u3057\u305f\u30d5\u30a1\u30a4\u30eb\u3092\u9023\u7d50\u3059\u308b\u306e\u3067\u8a02\u6b63\u304c\u767a\u751f\u3057\u307e\u3059\u3002<br><br>\u30d5\u30a1\u30a4\u30eb\u306e\u9023\u7d50\u7d14\u306f\u6b21\u306e\u901a\u308a\u3067\u3059\u3002\u3053\u308c\u3089\u3092\u9023\u7d50\u3057\u305f\u7d50\u679c\u304c\u3001\u96fb\u5149\u63b2\u793a\u677f\u8868\u793a\u7528\u30d5\u30a1\u30a4\u30eb tenki.gif \u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-vk-blocks-alert vk_alert alert alert-info\"><div class=\"vk_alert_content\">\n<p>file1_border1.gif \uff0b file2.gif \uff0b file3_2.jpg \uff0b<br>file4.gif \uff0b file4_1.gif \uff0b file4_2.gif \uff0b<br>4_3.gif \uff0b file4_4.gif \uff0b file5_2.jpg \uff0b file6.gif \uff0b<br>file7.gif \uff0b file8.gif \uff0b file9.gif \uff0b file10.gif<\/p>\n<\/div><\/div>\n\n\n\n<!-- WP QUADS v. 2.0.98  Shortcode Ad -->\n<div class=\"quads-location quads-ad\" id=\"quads-ad\" style=\"float:none;margin:0px 0 0px 0;text-align:center;\">\n\u30b9\u30dd\u30f3\u30b5\u30fc\u30ea\u30f3\u30af\r\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-1169427325398969\"\r\n     crossorigin=\"anonymous\"><\/script>\r\n<!-- www_\u8a18\u4e8b\u4e2d\uff13 -->\r\n<ins class=\"adsbygoogle\"\r\n     style=\"display:block\"\r\n     data-ad-client=\"ca-pub-1169427325398969\"\r\n     data-ad-slot=\"8208817721\"\r\n     data-ad-format=\"rectangle\"\r\n     data-full-width-responsive=\"true\"><\/ins>\r\n<script>\r\n     (adsbygoogle = window.adsbygoogle || []).push({});\r\n<\/script><br><\/div>\n\n\n\n\n<h2 class=\"wp-block-heading is-style-vk-heading-double_black\">\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9<\/h2>\n\n\n\n<p>\u6700\u5f8c\u306b\u3001\u8a02\u6b63\u7d42\u4e86\u5f8c\u306e\u30b7\u30a7\u30eb\u3068\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u63b2\u8f09\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u30b7\u30a7\u30eb\u3000tenki_new.sh<\/h3>\n\n\n\n<p>\u8a02\u6b63\u306e\u7d42\u4e86\u3057\u305f\u30b7\u30a7\u30eb\u306e\u30bd\u30fc\u30b9\u3067\u3059\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-bash\" data-lang=\"Bash\"><code># file product\npython3 \/home\/pi\/python-pg\/tenki_file.py\n\n# text --&gt; gif\nconvert -background black -fill green -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file1.txt \/home\/pi\/work\/file1.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file2.txt \/home\/pi\/work\/file2.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file4.txt \/home\/pi\/work\/file4.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file4_2.txt \/home\/pi\/work\/file4_2.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file4_4.txt \/home\/pi\/work\/file4_4.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file6.txt \/home\/pi\/work\/file6.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file8.txt \/home\/pi\/work\/file8.gif\n\nconvert -background black -fill yellow -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:@\/home\/pi\/work\/file10.txt \/home\/pi\/work\/file10.gif\necho &quot;convert end&quot;\n# gif1 add border\nconvert   -border 1x1 -bordercolor red \/home\/pi\/work\/file1.gif \/home\/pi\/work\/file1_border.gif\n\necho &quot;add border end&quot;\n\n# gif --&gt; size change\nconvert \/home\/pi\/work\/file1_border.gif -resize x16 \/home\/pi\/work\/file1_border1.gif\n\nconvert \/home\/pi\/work\/file3.jpg -resize x16 \/home\/pi\/work\/file3_2.jpg\n\nconvert \/home\/pi\/work\/file5.jpg -resize x16 \/home\/pi\/work\/file5_2.jpg\n\necho &quot;size change end&quot;\n# file\u3000add\nconvert +append \/home\/pi\/work\/file1_border1.gif \/home\/pi\/work\/file2.gif \/home\/pi\/work\/file3_2.jpg \/home\/pi\/work\/file4.gif \/home\/pi\/work\/file4_1.gif \/home\/pi\/work\/file4_2.gif \/home\/pi\/work\/file4_3.gif \/home\/pi\/work\/file4_4.gif \/home\/pi\/work\/file5_2.jpg \/home\/pi\/work\/file6.gif \/home\/pi\/work\/file7.gif \/home\/pi\/work\/file8.gif \/home\/pi\/work\/file9.gif \/home\/pi\/work\/file10.gif \/home\/pi\/work\/tenki.gif\n\n# imagescroller\nsudo timeout 60 sudo python3 \/home\/pi\/rpi-rgb-led-matrix\/bindings\/python\/samples\/image-scroller.py -r 16 --led-no-hardware-pulse yes -c 2  -i \/home\/pi\/work\/tenki.gif\n\n#demo run for LED PANEL reset\nsudo \/home\/pi\/rpi-rgb-led-matrix\/examples-api-use\/demo -D 1 -t 1 \/home\/pi\/rpi-rgb-led-matrix\/examples-api-use\/runtext16.ppm --led-rows=16 --led-no-hardware-pulse --led-chain=2<\/code><\/pre><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u30d7\u30ed\u30b0\u30e9\u30e0<\/h3>\n\n\n\n<p>\u8a02\u6b63\u306e\u7d42\u308f\u3063\u305f\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u3059\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-python\" data-lang=\"Python\"><code>#!\/usr\/bin\/env python3\n# -*- coding:utf-8 -*-\n\nfrom datetime import datetime\n\nimport  urllib.request\nfrom bs4 import BeautifulSoup\n\nimport shlex\nimport subprocess\n\ndef main():\n    print (&#39;start&#39;)\n    txt_weather()\n    return\n\ndef file_out(name,naiyo):\n\n    f = open(name,&#39;w&#39;)\n    f.write(naiyo)\n    f.close()\n\n    return\n\ndef img_file_out(color, ondo, file):\n\n    print(color,ondo,file)\n\n    cmd = &quot;convert -background black -fill %s -font \/usr\/share\/fonts\/truetype\/fonts-japanese-gothic.ttf -pointsize 16 label:%s\u2103 \/home\/pi\/work\/%s.gif&quot; % (color, ondo , file)\n\n    try:\n        res = subprocess.call( cmd.strip().split(&quot; &quot;) )\n    except:\n        print(&quot;Error. test&quot;)\n\n    return\n\ndef txt_weather():\n\n    weather_text = u&#39;%s\u306e\u5929\u6c17\u306f&#39;\n    temperature_text = u&#39;\u3067\u3059\u3002%s\u306e\u4e88\u60f3\u6700\u9ad8\u6c17\u6e29\u3001%s\u2103\u3001\u4e88\u60f3\u6700\u4f4e\u6c17\u6e29\u3001%s\u2103\u3067\u3059\u3002&#39;\n    file4_01text = &#39;\u3067\u3059\u3002\u4eca\u65e5\u306e\u4e88\u60f3\u6700\u9ad8\u6c17\u6e29 &#39;\n    file6_text = &#39;\u3067\u3059\u3002\u660e\u65e5\u306e\u4e88\u60f3\u6700\u9ad8\u6c17\u6e29 &#39;\n    file8_text = &#39;\u3001\u4e88\u60f3\u6700\u4f4e\u6c17\u6e29 &#39;\n    file10_text = &#39;\u3067\u3059\u3002&#39;\n\n    Parser(rssurl) # \u5929\u6c17\u4e88\u5831\u30b5\u30a4\u30c8\u306eHTML\u30bf\u30b0\u304b\u3089\u5929\u6c17\u60c5\u5831\u3092\u62bd\u51fa\n\n    for i in range(0,2):\n        detail2 = detail[i].split()\n        print(&quot;dtail -= &quot;,detail2)\n        if i == 0:\n    # TODAY\n             kyo_tenki = detail2[i]\n             temp = detail2[2].split(&#39;\/&#39;)\n             kyo_max = temp[0].split(&#39;\u2103&#39;)\n             kyo_min = temp[1].split(&#39;\u2103&#39;)\n             ck_Weather(i, detail)\n             file4_13_out(kyo_max[0],kyo_min[0])\n        else:\n    # TOMMOROW\n             asu_tenki = detail2[i]\n             temp = detail2[2].split(&#39;\/&#39;)\n             temp_num_max = temp[0].split(&#39;\u2103&#39;)\n             temp_num_min = temp[1].split(&#39;\u2103&#39;)\n             ck_Weather(i, detail)\n             file7_9_out(temp_num_max[0],temp_num_min[0])\n\n    title = u&#39;\u795e\u5948\u5ddd\u770c\u6a2a\u6d5c\u306e\u5929\u6c17&#39;\n\n    d = datetime.now()\n    text_day = &#39;%s\u6708%s\u65e5\u3001%s\u6642%s\u5206%s\u79d2&#39; % (d.month, d.day, d.hour, d.minute, d.second)\n\n    today_w_txt = weather_text % &#39;\u4eca\u65e5&#39;\n    tommorow_w_txt = weather_text % &#39;\u660e\u65e5&#39;\n    # text_file set & out\n    file1_text = text_day + &#39; &#39; + title + &#39; &#39;\n    file2_text = today_w_txt + &#39; &#39;\n    file4_text = file4_01text + &#39; &#39;\n    file4_4text = file10_text + tommorow_w_txt + &#39; &#39;\n\n    file_out(&quot;\/home\/pi\/work\/file1.txt&quot;,file1_text)\n    file_out(&quot;\/home\/pi\/work\/file2.txt&quot;,file2_text)\n    file_out(&quot;\/home\/pi\/work\/file4.txt&quot;,file4_text)\n    file_out(&quot;\/home\/pi\/work\/file4_2.txt&quot;,file8_text)\n    file_out(&quot;\/home\/pi\/work\/file4_4.txt&quot;,file4_4text)\n    file_out(&quot;\/home\/pi\/work\/file6.txt&quot;,file6_text)\n    file_out(&quot;\/home\/pi\/work\/file8.txt&quot;,file8_text)\n    file_out(&quot;\/home\/pi\/work\/file10.txt&quot;,file10_text)\n\n    return\n\n## ck_Weather : \u53d6\u5f97\u3057\u305f\u5929\u6c17\u60c5\u5831\u3068\u305d\u308c\u306b\u5fdc\u3058\u305f\u30a2\u30a4\u30b3\u30f3\u3092\u51fa\u529b\u3059\u308b\u30e1\u30bd\u30c3\u30c9 ################################\ndef ck_Weather(i, detail):\n\n   if (detail[i].find(&quot;\u6674&quot;)) != -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Sun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;SunToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;SunToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u6674\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u6674\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u6674\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;SunToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Cloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;CloudToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;CloudToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66c7\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u66c7\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;CloudToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1 and (detail[i].find(&quot;\u96ea&quot;)) == -1:\n       files = icon_path + &quot;Rain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;RainToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;RainToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96e8\u4e00\u6642\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u306e\u3061\u96ea&quot;)) != -1 or (detail[i].find(&quot;\u96e8\u6642\u3005\u96ea&quot;)) != -1:\n       files = icon_path + &quot;RainToSnow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea&quot;)) != -1 and (detail[i].find(&quot;\u6674&quot;)) == -1 and (detail[i].find(&quot;\u96e8&quot;)) == -1 and (detail[i].find(&quot;\u66c7&quot;)) == -1:\n       files = icon_path + &quot;Snow.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u6674&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u6674&quot;)) != -1:\n       files = icon_path + &quot;SnowToSun.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u66c7&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u66c7&quot;)) != -1:\n       files = icon_path + &quot;SnowToCloud.jpg&quot;\n\n   elif (detail[i].find(&quot;\u96ea\u4e00\u6642\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u306e\u3061\u96e8&quot;)) != -1 or (detail[i].find(&quot;\u96ea\u6642\u3005\u96e8&quot;)) != -1:\n       files = icon_path + &quot;SnowToRain.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66b4\u98a8\u96e8&quot;)) != -1:\n       files = icon_path + &quot;Typhon.jpg&quot;\n\n   elif (detail[i].find(&quot;\u66b4\u98a8\u96ea&quot;)) != -1:\n       files = icon_path + &quot;HeavySnow.jpg&quot;\n\n   else:\n       files = icon_path + &quot;404.jpg&quot;\n\n\n   print(&#39;icon=&#39;,files)\n   if i == 0:\n       cmd = &quot;convert %s \/home\/pi\/work\/file3.jpg&quot; % files\n       res = subprocess.call( cmd.strip().split(&quot; &quot;) )\n       print(&#39;file3.gif&#39;)\n   else:\n       cmd = &quot;convert %s \/home\/pi\/work\/file5.jpg&quot; % files\n       res = subprocess.call( cmd.strip().split(&quot; &quot;) )\n       print(&#39;file5.gif&#39;)\n\ndef file4_13_out(temp_max,temp_min):\n# max temp  file7\n    if int(temp_max) &gt;= 25:\n        img_file_out(&quot;red&quot;, temp_max, &quot;file4_1&quot;)\n    elif int(temp_max) &gt;= 20:\n        img_file_out(&quot;orange&quot;, temp_max, &quot;file4_1&quot;)\n    else:\n        img_file_out(&quot;yellow&quot;, temp_max, &quot;file4_1&quot;)\n\n    # mix temp  file9\n    if int(temp_min) &lt; 5:\n        img_file_out(&quot;white&quot;, temp_min, &quot;file4_3&quot;)\n    elif int(temp_min) &lt; 10:\n        img_file_out(&quot;blue&quot;, temp_min, &quot;file4_3&quot;)\n    else:\n        img_file_out(&quot;yellow&quot;, temp_min, &quot;file4_3&quot;)\n\ndef file7_9_out(temp_max,temp_min):\n# max temp  file7\n    if int(temp_max) &gt;= 25:\n        img_file_out(&quot;red&quot;, temp_max, &quot;file7&quot;)\n    elif int(temp_max) &gt;= 20:\n        img_file_out(&quot;orange&quot;, temp_max, &quot;file7&quot;)\n    else:\n        img_file_out(&quot;yellow&quot;, temp_max, &quot;file7&quot;)\n\n    # mix temp  file9\n    if int(temp_min) &lt; 5:\n        img_file_out(&quot;white&quot;, temp_min, &quot;file9&quot;)\n    elif int(temp_min) &lt; 10:\n        img_file_out(&quot;blue&quot;, temp_min, &quot;file9&quot;)\n    else:\n        img_file_out(&quot;yellow&quot;, temp_min, &quot;file9&quot;)\n\n## Parser : \u5929\u6c17\u60c5\u5831Web\u30da\u30fc\u30b8\u306eHTML\u30bf\u30b0\u304b\u3089\u5929\u6c17\u60c5\u5831\u3092\u62bd\u51fa\u3057\u3066\u30d1\u30fc\u30b9\u3059\u308b\u30e1\u30bd\u30c3\u30c9 ####################\ndef Parser(rssurl):\n   with urllib.request.urlopen(rssurl) as res:\n      xml = res.read()\n      soup = BeautifulSoup(xml, &quot;html.parser&quot;)\n      for item in soup.find_all(&quot;item&quot;):\n         title = item.find(&quot;title&quot;).string\n         description = item.find(&quot;description&quot;).string\n         if title.find(&quot;[ PR ]&quot;) == -1:\n            tenki.append(title)\n            detail.append(description)\n\n### Execute\n\nicon_path =&quot;\/home\/pi\/work\/tenki_mark\/&quot;\n\n# \u62bd\u51fa\u5bfe\u8c61\u306eRSS(\u795e\u5948\u5ddd\u770c\u6a2a\u6d5c\u5e02)\nrssurl = &quot;https:\/\/rss-weather.yahoo.co.jp\/rss\/days\/4610.xml&quot;\n\ntenki = []\ndetail = []\ndetail2 = []\ntemp = []\ntemp_num_max = []\ntemp_num_min = []\nkyo_max = []\nkyo_min = []\n\nif __name__ == &quot;__main__&quot;:\n    main()<\/code><\/pre><\/div>\n\n\n\n<p><strong>\u203b\u300c\u96fb\u5149\u63b2\u793a\u677f\u300d\u306e\u4e00\u3064\u524d\u3068\u6b21\u306e\u8a18\u4e8b\u3092\u7d39\u4ecb\u3057\u3066\u3044\u307e\u3059\u3002<\/strong>\u672c\u8a18\u4e8b\u3067\u300c\u96fb\u5149\u63b2\u793a\u677f\u300d\u30b7\u30ea\u30fc\u30ba\u306f\u7d42\u4e86\u3067\u3059\u306e\u3067\u3001next\u306b\u306fpart1\u306e\u8a18\u4e8b\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<br>\u21d2 previous\uff1a<strong><a href=\"https:\/\/www.mizutan.com\/wordpress\/?p=9481\" target=\"_blank\" rel=\"noreferrer noopener\">\u30e9\u30ba\u30d1\u30a4\u96fb\u5149\u63b2\u793a\u677f\u7528\u306eOS\u3092Jessie\u304b\u3089stretch\u306b\u30d0\u30fc\u30b8\u30e7\u30f3\u30a2\u30c3\u30d7\u3057\u305f<\/a><\/strong><br>\u21d2 next\uff1a<strong><a href=\"https:\/\/www.mizutan.com\/wordpress\/?p=1361\" target=\"_blank\" rel=\"noreferrer noopener\">\u30e9\u30ba\u30d1\u30a4\u3067\u96fb\u5149\u63b2\u793a\u677f\u3092\u4f5c\u308b\uff01\u914d\u7dda\u3068\u30c7\u30e2\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u5b9f\u884c\u3057\u3066\u697d\u3057\u3080<\/a><\/strong><\/p>\n\n\n\n<h2 class=\"wp-block-heading is-style-vk-heading-double_black\">\u6700\u5f8c\u306b<\/h2>\n\n\n\n<p>Livedoor\u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u914d\u4fe1\u304c\u7d42\u4e86\u3057\u305f\u3053\u3068\u3067\u3001\u96fb\u5149\u63b2\u793a\u677f\u5929\u6c17\u4e88\u5831\u8868\u793a\u306e\u8a02\u6b63\u3092\u4f59\u5100\u306a\u304f\u3055\u308c\u307e\u3057\u305f\u3002<br><br>\u305d\u306e\u305f\u3081\u3001yahoo!\u5929\u6c17rss\u30c7\u30fc\u30bf\u3068\u5929\u6c17\u30de\u30fc\u30af\u3092\u8ffd\u52a0\u3059\u308b\u3053\u3068\u3067\u96fb\u5149\u63b2\u793a\u677f\u5929\u6c17\u4e88\u5831\u8868\u793a\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u30ea\u30d7\u30ec\u30fc\u30b9\u3092\u884c\u3044\u307e\u3057\u305f\u3002<br><br>\u4eca\u56de\u3001\u305d\u3053\u3067\u5b9f\u65bd\u3057\u305f\u5185\u5bb9\u3092\u63b2\u8f09\u3057\u3066\u3044\u307e\u3059\u3002<br><br>\u3053\u308c\u3067\u3001\u3088\u3046\u3084\u304f\u3001\u96fb\u5149\u63b2\u793a\u677f\u306e\u5929\u6c17\u4e88\u5831\u8868\u793a\u304c\u6b63\u3057\u304f\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p>\u203b\u6c17\u3065\u3051\u3070\u96fb\u5149\u63b2\u793a\u677f\u306e\u8a18\u4e8b\u3082\u5897\u3048\u3066\u304d\u307e\u3057\u305f<\/p>\n\n\n\n<div class=\"blogcard\"><a href=\"https:\/\/www.mizutan.com\/wordpress\/?cat=261\" data-blogcard=\"1\">\u96fb\u5149\u63b2\u793a\u677f<\/a><\/div>\n","protected":false},"excerpt":{"rendered":"<p>livedoor \u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u914d\u4fe1\u306e\u30b5\u30fc\u30d3\u30b9\u304c\uff17\u670831\u65e5\u306b\u7d42\u4e86\u3057\u305f\u3053\u3068\u3067\u3001\u5929\u6c17\u4e88\u5831\u8aad\u307f\u4e0a\u3052\u304c\u51fa\u6765\u306a\u304f\u306a\u308a\u3001\u304b\u3064\u3001\u96fb\u5149\u63b2\u793a\u677f\u3078\u306e\u5929\u6c17\u4e88\u5831\u30c7\u30fc\u30bf\u8868\u793a\u304c\u3001\u305a\u3063\u3068\uff17\u670831\u65e5\u306e\u3082\u306e\u306b\u306a\u3063\u305f\u4ef6\u306f\u3001\u5148\u306e\u8a18\u4e8b\u3067\u304a\u77e5\u3089\u305b\u3057\u307e\u3057\u305f\u3002 \u5929 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":10117,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[261],"tags":[],"class_list":["post-10116","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-electric-bulletin-board"],"_links":{"self":[{"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/10116","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10116"}],"version-history":[{"count":7,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/10116\/revisions"}],"predecessor-version":[{"id":30153,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/10116\/revisions\/30153"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=\/wp\/v2\/media\/10117"}],"wp:attachment":[{"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10116"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10116"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.mizutan.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10116"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}