﻿{"id":439,"date":"2017-03-06T10:56:43","date_gmt":"2017-03-06T02:56:43","guid":{"rendered":"http:\/\/blog.sway.com.cn\/?p=439"},"modified":"2017-03-06T11:06:01","modified_gmt":"2017-03-06T03:06:01","slug":"%e6%a0%91%e8%8e%93%e6%b4%be3b%e5%bc%80%e5%90%afi2c%e6%80%bb%e7%ba%bf","status":"publish","type":"post","link":"http:\/\/blog.sway.com.cn\/?p=439","title":{"rendered":"\u6811\u8393\u6d3e3B\u5f00\u542fI2C\u603b\u7ebf"},"content":{"rendered":"<p>\u7f16\u8f91\/boot\/config.txt\u6587\u4ef6<\/p>\n<p>\u53bb\u6389\u4e00\u4e0b\u4e24\u884c\u4ee3\u7801\u7684\u6ce8\u91ca\uff1a<\/p>\n<p><strong>dtparam=i2c1=on<br \/>\ndtparam=i2c_arm=on<\/strong><\/p>\n<p>\u91cd\u542f\u6811\u8393\u6d3e\uff0c\u8f93\u5165\u00a0i2cdetect -y -a\u00a01 \u547d\u4ee4\uff0c\u51fa\u73b0\u4ee5\u4e0b\u63d0\u793a\u4e3a\u5f00\u542f\u6210\u529f\uff1a<\/p>\n<pre class=\"lang:sh decode:true \">     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f\r\n00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --\r\n70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --<\/pre>\n<p>\u7136\u540e\u4f7f\u7528\u4ee5\u4e0b\u4ee3\u7801\u5373\u53ef\u83b7\u53d6I2C\u603b\u7ebf\u7528\u4e8e\u7f16\u7a0b\uff1a<\/p>\n<p>I2CBus i2cbus = I2CFactory.getInstance(I2CBus.BUS_1);<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7f16\u8f91\/boot\/config.txt\u6587\u4ef6 \u53bb\u6389\u4e00\u4e0b\u4e24\u884c\u4ee3\u7801\u7684\u6ce8\u91ca\uff1a dtparam=i2c1=on dtpar [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[156],"tags":[],"class_list":["post-439","post","type-post","status-publish","format-standard","hentry","category-156"],"_links":{"self":[{"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/posts\/439","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=439"}],"version-history":[{"count":3,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/posts\/439\/revisions"}],"predecessor-version":[{"id":442,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=\/wp\/v2\/posts\/439\/revisions\/442"}],"wp:attachment":[{"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=439"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=439"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.sway.com.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=439"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}