{"id":291317,"date":"2024-05-03T05:23:10","date_gmt":"2024-05-02T21:23:10","guid":{"rendered":"https:\/\/lrxjmw.cn\/srljqrslxtzs.html"},"modified":"2024-05-03T05:23:10","modified_gmt":"2024-05-02T21:23:10","slug":"srljqrslxtzs","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/srljqrslxtzs.html","title":{"rendered":"\u6df1\u5165\u7406\u89e3\u5d4c\u5165\u5f0fLinux\u7cfb\u7edf\u4e2dSPI\u9a71\u52a8\u7a0b\u5e8f\u7684\u539f\u7406\u3001\u64cd\u4f5c\u6a21\u5f0f\u3001\u5f00\u53d1\u6b65\u9aa4\u53ca\u5e38\u89c1\u95ee\u9898"},"content":{"rendered":"

\u5728\u5d4c\u5165\u5f0fLinux<\/a>\u7cfb\u7edf<\/a>\u7814\u53d1\u8fc7\u7a0b\u4e2d\uff0cSPI(\u4e32\u884c\u5916\u8bbe\u63a5\u53e3)\u9a71\u52a8\u7a0b\u5e8f\u7684\u91cd\u8981\u6027\u4e0d\u53ef\u5ffd\u89c6\u3002\u672c\u6587\u5c06\u7740\u91cd\u9610\u8ff0SPI\u9a71\u52a8\u539f\u7406\u3001\u64cd\u4f5c\u6a21\u5f0f\u3001\u5f00\u53d1\u6b65\u9aa4\u53ca\u5e38\u89c1\u95ee\u9898\u7684\u5e94\u5bf9\u7b56\u7565\uff0c\u671f\u671b\u534f\u52a9\u8bfb\u8005\u6df1\u5316\u5bf9SPI\u7f16\u7a0b\u6280\u672f\u7684\u7406\u89e3\u5e76\u7eaf\u719f\u9a7e\u9a6d\u3002<\/p>\n

1.SPI\u9a71\u52a8\u6982\u8ff0<\/b><\/p>\n

\u5728\u5d4c\u5165\u5f0f\u7cfb\u7edf\u7684\u6280\u672f\u9886\u57df\u4e2d\uff0cSPI\u534f\u8bae\u88ab\u666e\u904d\u5e94\u7528\u4e8e\u5404\u7c7b\u5fae\u63a7\u5236\u5668\u3001\u4f20\u611f\u5668\u4ee5\u53ca\u5b58\u50a8\u5668\u7b49\u5916\u8bbe\u95f4\u7684\u4e32\u884c\u901a\u4fe1\u3002\u5176\u6838\u5fc3\u8fd0\u4f5c\u539f\u7406\u4e3b\u8981\u901a\u8fc7\u56db\u4e2a\u5173\u952e\u7ebf\u8def\u5b9e\u73b0\uff1a\u5373\u65f6\u949f\u4fe1\u53f7\u7ebf\uff08SCLK\uff09\u3001\u4e3b\u8bbe\u5907\u6570\u636e\u8f93\u51fa\u7ebf\uff08MOSI\uff09\u3001\u4e3b\u8bbe\u5907\u6570\u636e\u8f93\u5165\u7ebf\uff08MISO\uff09\u4ee5\u53ca\u82af\u7247\u9009\u62e9\u4fe1\u53f7\u7ebf\uff08SS\uff09\u3002<\/p>\n

\u5728Linux\u6838\u5fc3\u67b6\u6784\u5185\uff0cSPI\u9a71\u52a8\u5668\u4e3b\u5bfcSPI\u603b\u7ebf\u7ba1\u7406\u804c\u80fd\uff0c\u5176\u9ad8\u9636\u5b57\u7b26\u8a2d\u5099\u754c\u9eb5\u4fbf\u5229\u7528\u6236\u64cd\u4f5c\uff0c\u540c\u6642\u8207\u786c\u9ad4SPI\u63a7\u5236\u5668\u5efa\u7acb\u901a\u4fe1\u9023\u63a5\u3002\u9019\u4e9b\u8a2d\u5099\u5e38\u88ab\u8996\u70ba\u5167\u7f6e\u5b57\u7b26\u8a2d\u5099\uff0c\u901a\u904e\u6587\u4ef6\u7cfb\u7d71\u4ecb\u9762\u5be6\u73fe\u5b58\u53d6\u53ca\u63a7\u5236\u529f\u80fd\u3002<\/p>\n

2.SPI\u8bbe\u5907\u9a71\u52a8\u5f00\u53d1\u6d41\u7a0b<\/b><\/p>\n

linux\u9a71\u52a8\u7a0b\u5e8f\u5b9e\u9a8c_\u9a71\u52a8linux_linux spi\u9a71\u52a8\u4f8b\u7a0b<\/p>\n

SPI\u8bbe\u5907\u9a71\u52a8\u7684\u5f00\u53d1\u4e3b\u8981\u5305\u62ec\u4ee5\u4e0b\u51e0\u4e2a\u6b65\u9aa4\uff1a<\/p>\n

-SPI\u603b\u7ebf\u521d\u59cb\u914d\u7f6e\uff1a\u5728\u9a71\u52a8\u7a0b\u5e8f\u542f\u52a8\u671f\u95f4\uff0c\u987b\u5b8c\u6210SPI\u603b\u7ebf\u7684\u6ce8\u518c\u4ee5\u53ca\u8bbe\u5b9a\u5982\u5de5\u4f5c\u6a21\u5f0f\u548c\u65f6\u949f\u9891\u7387\u7b49\u91cd\u8981\u53c2\u6570\u3002<\/p>\n

-\u5b9e\u73b0SPI\u8bbe\u5907\u6ce8\u518c\u529f\u80fd\uff1a\u4fdd\u8bc1\u8bbe\u5907\u4e0e\u9a71\u52a8\u7a0b\u5e8f\u65e0\u7f1d\u8854\u63a5\uff0c\u8d4b\u7ed9\u5176\u552f\u4e00\u6807\u8bc6\u7b26\u4ee5\u987a\u5229\u7eb3\u5165\u7cfb\u7edf\u7ba1\u63a7\u3002<\/p>\n

-SPI\u8bbe\u5907\u5b57\u7b26\u8bbe\u5907\u63a5\u53e3\u7814\u5236\uff1a\u6211\u4eec\u81f4\u529b\u4e8e\u6784\u9020\u5177\u5907\u5b8c\u5907\u5f00\u653e\u3001\u5173\u95ed\u3001\u8bfb\u53d6\u4ee5\u53ca\u5199\u5165\u7b49\u529f\u80fd\u7684SPI\u8bbe\u5907\u5b57\u7b26\u8bbe\u5907\u63a5\u53e3\uff0c\u4ece\u800c\u5411\u7528\u6237\u7a7a\u95f4\u5e94\u7528\u7a0b\u5e8f\u63d0\u4f9b\u4e00\u79cd\u4fbf\u6377\u4e14\u9ad8\u6548\u7684\u8bbe\u5907\u8bbf\u95ee\u548c\u63a7\u5236\u65b9\u5f0f\u3002<\/p>\n

linux\u9a71\u52a8\u7a0b\u5e8f\u5b9e\u9a8c_linux spi\u9a71\u52a8\u4f8b\u7a0b_\u9a71\u52a8linux<\/p>\n

-\u6570\u636e\u4f20\u8f93\uff1a\u5b9e\u73b0SPI\u6570\u636e\u4f20\u8f93\u673a\u5236\uff0c\u6db5\u76d6\u4fe1\u606f\u6536\u53d1\u8fc7\u7a0blinux\u5b89\u88c5\u6559\u7a0b\uff0c\u901a\u8fc7API\u8c03\u7528SPI\u63a7\u5236\u6a21\u5757\u5b8c\u6210\u6570\u636e\u4ea4\u4e92\u3002<\/p>\n

\u4e3a\u4e86\u63d0\u5347\u4e2d\u65ad\u5904\u7406\u6548\u7387\uff0c\u6784\u5efa\u4e00\u5957\u4e13\u7528\u4e8eSEMI\u8bbe\u5907\u4ea7\u751f\u7684\u4e2d\u65ad\u4e8b\u4ef6\u7684\u5904\u7406\u673a\u5236\u548c\u51fd\u6570\u81f3\u5173\u91cd\u8981\u3002<\/p>\n

3.SPI\u9a71\u52a8\u7f16\u7a0b\u6280\u672f<\/b><\/p>\n

\u4e3a\u4e86\u63d0\u9ad8SPI\u9a71\u52a8\u7684\u6027\u80fd\u548c\u7a33\u5b9a\u6027\uff0c\u4ee5\u4e0b\u5b9e\u7528\u6280\u5de7\u503c\u5f97\u501f\u9274\uff1a<\/p>\n

-DMA\u9ad8\u901f\u6570\u636e\u4f20\u8f93\uff1a\u8fd0\u7528\u5c16\u7aef\u7684DMA\uff08\u76f4\u63a5\u5b58\u50a8\u5b58\u53d6\uff09\u4f20\u8f93\u6a21\u5f0f\uff0c\u53ef\u5927\u5e45\u5206\u62c5CPU\u8d1f\u62c5\uff0c\u63d0\u9ad8\u6570\u636e\u4f20\u8f93\u901f\u7387\u3002\u7ecf\u8fc7\u7cbe\u5fc3\u914d\u7f6e\u7684SPI\u63a7\u5236\u4e0eDMA\u5f15\u64ce\u534f\u540c\u8fd0\u4f5c\uff0c\u4e3a\u9ad8\u901f\u6570\u636e\u4f20\u8f93\u94fa\u5e73\u9053\u8def\u3002<\/p>\n

-\u8bbe\u5907\u6811\u6346\u7ed1\u6280\u6cd5\uff1a\u901a\u8fc7\u5de7\u5999\u8fd0\u7528\u8bbe\u5907\u6811\uff0c\u6211\u4eec\u80fd\u8be6\u7ec6\u63cf\u7ed8SPI\u8bbe\u5907\u53caSPI\u63a7\u5236\u5668\uff0c\u4ece\u800c\u5b9e\u73b0\u81ea\u52a8\u8fa8\u8bc6\u4e0e\u914d\u7f6e\u786c\u4ef6\u8d44\u6e90\u7684\u529f\u80fd\uff0c\u8fdb\u800c\u5927\u5e45\u7f29\u51cf\u9a71\u52a8\u7a0b\u5e8f\u7814\u53d1\u5468\u671f\u3002<\/p>\n

-\u9501\u5b9a\u7b56\u7565\uff1a\u4e3a\u786e\u4fdd\u5b89\u5168\u6027\u5982\u4f55\u5b89\u88c5LINUX\uff0c\u9632\u8303\u5171\u4eab\u8d44\u6e90\u56e0\u6570\u636e\u51b2\u7a81\u53ca\u610f\u5916\u72b6\u51b5\u53d7\u635f\uff0c\u5e94\u5b9e\u65bd\u9501\u56fa\u7b56\u7565\u3002<\/p>\n

-\u589e\u5f3a\u9519\u8bef\u5904\u7406\u673a\u5236\uff1a\u9a71\u52a8\u7a0b\u5e8f\u9700\u62e5\u6709\u9ad8\u6548\u7cbe\u51c6\u7684\u9519\u8bef\u5904\u7406\u80fd\u529b\uff0c\u4ee5\u4fbf\u8fc5\u901f\u54cd\u5e94\u5e76\u89e3\u51b3\u6f5c\u5728\u95ee\u9898\uff0c\u4ece\u800c\u63d0\u5347\u6574\u4f53\u7cfb\u7edf\u7684\u7a33\u5b9a\u6027\u53ca\u5176\u53ef\u9760\u6027\u3002<\/p>\n

4.\u5e38\u89c1\u95ee\u9898\u89e3\u51b3\u65b9\u6848<\/b><\/p>\n

\u5728SPI\u9a71\u52a8\u7f16\u5199\u5386\u7a0b\u4e2d\uff0c\u4e0d\u53ef\u907f\u514d\u5730\u9762\u4e34\u7740\u8bf8\u591a\u96be\u9898\u3002\u4ee5\u4e0b\u5217\u4e3e\u4e86\u4e00\u4e9b\u5e38\u89c1\u95ee\u9898\u53ca\u6709\u6548\u5bf9\u7b56\uff1a<\/p>\n

-\u65f6\u5e8f\u4fee\u6b63\uff1a\u5982\u9047\u6570\u636e\u4f20\u8f93\u8bef\u5dee\u6216\u65f6\u5e8f\u504f\u5dee\uff0c\u7528\u4e8e\u6392\u67e5\u95ee\u9898\u7684\u5e38\u7528\u6280\u672f\u5305\u62ec\u65f6\u5e8f\u5206\u6790\u4eea\u4e0e\u903b\u8f91\u5206\u6790\u5668linux spi\u9a71\u52a8\u4f8b\u7a0b<\/strong>\uff0c\u901a\u8fc7\u5bf9\u4fe1\u53f7\u6ce2\u5f62\u53ca\u5176\u65f6\u5e8f\u5173\u7cfb\u7684\u7ec6\u81f4\u89c2\u5bdf\u6765\u5b9a\u4f4d\u6545\u969c\u3002<\/p>\n

\u4e2d\u65ad\u63aa\u65bd\uff1a\u5728\u5904\u7406\u73af\u8282\u65e0\u6cd5\u83b7\u5f97\u9002\u5f53\u3001\u6709\u6548\u7684\u4e2d\u65ad\u6216\u8005\u662f\u5426\u5b58\u5728\u7f3a\u9677\u7684\u72b6\u51b5\u4e0b\uff0c\u9700\u8981\u4e25\u8c28\u5730\u5ba1\u67e5\u4e2d\u65ad\u63a7\u5236\u5668\u7684\u914d\u7f6e\u53ca\u5176\u4e2d\u65ad\u5904\u7406\u51fd\u6570\u7684\u8bbe\u8ba1\uff0c\u4ee5\u4fdd\u8bc1\u7cbe\u786e\u89e6\u53d1\u548c\u9ad8\u6548\u5904\u7406\u4e2d\u65ad\u3002<\/p>\n

\u9a71\u52a8linux_linux\u9a71\u52a8\u7a0b\u5e8f\u5b9e\u9a8c_linux spi\u9a71\u52a8\u4f8b\u7a0b<\/p>\n

-DMA\u4fee\u6574\uff1a\u82e5\u9047\u6570\u636e\u4e22\u5931\u6216DMA\u95ee\u9898\uff0c\u5e94\u68c0\u67e5\u548c\u8c03\u8282DMA\u5f15\u64ce\u53c2\u6570\u53ca\u89e6\u53d1\u6761\u4ef6linux spi\u9a71\u52a8\u4f8b\u7a0b<\/strong>\uff0c\u8fdb\u884c\u91cd\u8bbe\u4ee5\u89e3\u51b3\u6545\u969c\u3002<\/p>\n

5.\u7ed3\u8bed\u4e0e\u5c55\u671b<\/b><\/p>\n

\u672c\u6587\u901a\u8fc7\u6df1\u5ea6\u89e3\u6790\uff0c\u4f7f\u8bfb\u8005\u5bf9LinuxSPI\u9a71\u52a8\u7a0b\u5e8f\u8bbe\u8ba1\u6709\u4e86\u5b8c\u6574\u800c\u6df1\u523b\u7684\u7406\u89e3\u3002\u5b83\u662f\u5d4c\u5165\u5f0f\u7cfb\u7edf\u4e2d\u5173\u952e\u7684\u7ec4\u4ef6\u4e4b\u4e00\uff0c\u5bf9\u4e8e\u786c\u4ef6\u63a7\u5236\u4e0e\u5916\u8bbe\u901a\u4fe1\u5177\u6709\u4e3e\u8db3\u8f7b\u91cd\u7684\u5730\u4f4d\u3002\u5c55\u671b\u672a\u6765\uff0c\u968f\u7740\u5d4c\u5165\u5f0f\u7cfb\u7edf\u53ca\u786c\u4ef6\u6280\u672f\u7684\u6301\u7eed\u8fdb\u6b65\uff0cSPI\u9a71\u52a8\u6280\u672f\u53ca\u5176\u6027\u80fd\u4e5f\u5c06\u5f97\u5230\u8fdb\u4e00\u6b65\u63d0\u9ad8\uff0c\u4e3a\u66f4\u7a33\u5b9a\u3001\u9ad8\u6548\u7684\u5d4c\u5165\u5f0f\u7cfb\u7edf\u5e94\u7528\u63d0\u4f9b\u6709\u529b\u652f\u6301\u3002<\/p>\n

\u7591\u96be\u4e0e\u5c55\u671b\uff1a\u60a8\u5728SPI\u9a71\u52a8\u9879\u76ee\u5b9e\u65bd\u8fc7\u7a0b\u4e2d\u6709\u5426\u9047\u5230\u96be\u9898\uff1f\u5bf9\u4e8eSPI\u9a71\u6280\u672f\u7684\u53d1\u5c55\u8d8b\u52bf\uff0c\u53c8\u505a\u4f55\u9884\u671f\uff1f<\/p>\n","protected":false},"excerpt":{"rendered":"

\u5728\u5d4c\u5165\u5f0fLinux\u7cfb\u7edf\u7814\u53d1\u8fc7\u7a0b\u4e2d\uff0cSPI(\u4e32\u884c\u5916\u8bbe\u63a5\u53e3)\u9a71\u52a8\u7a0b\u5e8f\u7684\u91cd\u8981\u6027\u4e0d\u53ef\u5ffd\u89c6\u3002\u672c\u6587\u5c06\u7740\u91cd\u9610\u8ff0SPI\u9a71\u52a8\u539f\u7406\u3001\u64cd\u4f5c\u6a21\u5f0f\u3001\u5f00\u53d1\u6b65\u9aa4\u53ca\u5e38\u89c1\u95ee\u9898\u7684\u5e94\u5bf9\u7b56\u7565\uff0c\u671f\u671b\u534f\u52a9\u8bfb\u8005\u6df1\u5316\u5bf9SPI\u7f16\u7a0b\u6280\u672f\u7684\u7406\u89e3\u5e76\u7eaf\u719f\u9a7e\u9a6d\u3002SPI\u8bbe\u5907\u9a71\u52a8\u7684\u5f00\u53d1\u4e3b\u8981\u5305\u62ec\u4ee5\u4e0b\u51e0\u4e2a\u6b65\u9aa4\uff1a<\/p>\n","protected":false},"author":1,"featured_media":291318,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[988],"tags":[999],"class_list":["post-291317","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tougao","tag-999"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/291317","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=291317"}],"version-history":[{"count":0,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/291317\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/291318"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=291317"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=291317"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=291317"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}