{"id":4252,"date":"2014-01-19T08:19:41","date_gmt":"2014-01-18T23:19:41","guid":{"rendered":"http:\/\/physicom.digick.jp\/?p=4252"},"modified":"2014-01-19T16:43:56","modified_gmt":"2014-01-19T07:43:56","slug":"aux1%e3%83%9d%e3%83%bc%e3%83%88%e3%81%ae%e3%83%86%e3%82%b9%e3%83%88","status":"publish","type":"post","link":"http:\/\/physicom.digick.jp\/?p=4252","title":{"rendered":"AUX1\u30dd\u30fc\u30c8\u306e\u30c6\u30b9\u30c8"},"content":{"rendered":"<p>\u30d4\u30f3\u30bd\u30b1\u30c3\u30c8\u3092\u4ed8\u3051\u305f\u306e\u3067AUX1\u30dd\u30fc\u30c8\u3092\u30c6\u30b9\u30c8\u3057\u3066\u307f\u305f\u3002<\/p>\n<div id=\"attachment_4258\" style=\"width: 310px\" class=\"wp-caption alignnone\"><a href=\"http:\/\/physicom.digick.jp\/wp-content\/uploads\/2014\/01\/PQ_AUX1.png\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-4258\" src=\"http:\/\/physicom.digick.jp\/wp-content\/uploads\/2014\/01\/PQ_AUX1-300x284.png\" alt=\"AUX1\u306e\u30c6\u30b9\u30c8\u56de\u8def\" width=\"300\" height=\"284\" class=\"size-medium wp-image-4258\" srcset=\"http:\/\/physicom.digick.jp\/wp-content\/uploads\/2014\/01\/PQ_AUX1-300x284.png 300w, http:\/\/physicom.digick.jp\/wp-content\/uploads\/2014\/01\/PQ_AUX1.png 449w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><p id=\"caption-attachment-4258\" class=\"wp-caption-text\">AUX1\u306e\u30c6\u30b9\u30c8\u56de\u8def<\/p><\/div>\n<p>\u30bf\u30af\u30c8\u30b9\u30a4\u30c3\u30c1\u3092\u62bc\u3059\u3068\u9752\u3044LED\u304c\u70b9\u706f\u3059\u308b\u3068\u3044\u3046\u30b9\u30b1\u30c3\u30c1\u3092\u66f8\u3044\u3066\u8ee2\u9001\u3002<\/p>\n<p><iframe loading=\"lazy\" width=\"420\" height=\"236\" src=\"\/\/www.youtube.com\/embed\/N4tpIm5BdKk\" frameborder=\"0\" allowfullscreen><\/iframe><br \/>\n\u52d5\u304b\u3057\u305f\u6642\u306e\u52d5\u753b\u3002<\/p>\n<p>\u57fa\u677f\u306e\u30b7\u30eb\u30af\u5370\u5237\u306bD8\/AUX1\u3068\u3042\u3063\u305f\u306e\u3067\u30c7\u30b8\u30bf\u30eb8\u30d4\u30f3\u3067\u8a66\u3057\u305f\u3089\u5f53\u305f\u3063\u3066\u3044\u305f\u3002<\/p>\n<div style=\"overflow: scroll; width: 425px; height: 300px; white-space: nowrap;\">\n<pre>\r\n\u30fb\u30fb\u30fb\u4ee5\u4e0a\u7565\u30fb\u30fb\u30fb\r\nint aux1Pin = 8;\r\n\r\nvoid setup()\r\n{\r\n  Serial.begin(9600);\r\n  pinMode(aux1Pin, INPUT);\r\n  initOutput();\r\n  initSensors();\r\n}\r\n\r\nvoid loop()\r\n{\r\n  static uint32_t rcTime  = 0;\r\n  \r\n  if (currentTime > rcTime ) { \/\/ 50Hz\r\n    \/\/ RC loop\r\n    rcTime = currentTime + 20000;\r\n    int val = digitalRead(aux1Pin);\r\n    if (val == HIGH) {\r\n      LEDPIN_ON;\r\n    } else {\r\n      LEDPIN_OFF;\r\n    }\r\n  } else {\r\n    \/\/ Not RC loop\r\n  }\r\n\u30fb\u30fb\u30fb\u4ee5\u4e0b\u7565\u30fb\u30fb\u30fb\r\n<\/pre>\n<\/div>\n<p>\u30b9\u30b1\u30c3\u30c1\u306e\u629c\u7c8b\u3002<\/p>\n<p>\u53c2\u8003\uff1a<a href=\"http:\/\/arduino.cc\/en\/Hacking\/PinMapping32u4\" title=\"ATmega32U4\u306e\u30d4\u30f3\u30de\u30c3\u30d4\u30f3\u30b0\" target=\"_blank\">ATmega32U4\u306e\u30d4\u30f3\u30de\u30c3\u30d4\u30f3\u30b0<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30d4\u30f3\u30bd\u30b1\u30c3\u30c8\u3092\u4ed8\u3051\u305f\u306e\u3067AUX1\u30dd\u30fc\u30c8\u3092\u30c6\u30b9\u30c8\u3057\u3066\u307f\u305f\u3002 \u30bf\u30af\u30c8\u30b9\u30a4\u30c3\u30c1\u3092\u62bc\u3059\u3068\u9752\u3044LED\u304c\u70b9\u706f\u3059\u308b\u3068\u3044\u3046\u30b9\u30b1\u30c3\u30c1\u3092\u66f8\u3044\u3066\u8ee2\u9001\u3002 \u52d5\u304b\u3057\u305f\u6642\u306e\u52d5\u753b\u3002 \u57fa\u677f\u306e\u30b7\u30eb\u30af\u5370\u5237\u306bD8\/AUX1\u3068\u3042\u3063\u305f\u306e\u3067\u30c7\u30b8\u30bf\u30eb8\u30d4\u30f3\u3067\u8a66\u3057\u305f\u3089\u5f53 &hellip; <a href=\"http:\/\/physicom.digick.jp\/?p=4252\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[443,141,119],"tags":[442,214,115,120],"class_list":["post-4252","post","type-post","status-publish","format-standard","hentry","category-pocketquad","category-working","category-circuit","tag-pocket-quad-v1-1","tag-sourcecode","tag-115","tag-120"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/posts\/4252","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4252"}],"version-history":[{"count":10,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/posts\/4252\/revisions"}],"predecessor-version":[{"id":4265,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=\/wp\/v2\/posts\/4252\/revisions\/4265"}],"wp:attachment":[{"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4252"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4252"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/physicom.digick.jp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4252"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}