{"id":88651,"date":"2024-02-19T15:19:38","date_gmt":"2024-02-19T07:19:38","guid":{"rendered":"https:\/\/www.techphant.cn\/?p=88651"},"modified":"2024-03-21T15:08:49","modified_gmt":"2024-03-21T07:08:49","slug":"ahltxddm","status":"publish","type":"post","link":"https:\/\/www.techphant.cn\/blog\/88651.html","title":{"rendered":"Arduino\u548cLoRa\u901a\u4fe1\u7684\u4ee3\u7801"},"content":{"rendered":"

  \u672c\u6587\u5c06\u6df1\u5165\u63a2\u8ba8\u5982\u4f55\u5229\u7528Arduino\u548cLoRa\u901a\u4fe1\u6a21\u5757\u8fdb\u884c\u65e0\u7ebf\u901a\u4fe1\u7684\u5f00\u53d1\uff0c\u4e3a\u4f60\u5e26\u6765\u5168\u65b0\u7684\u7269\u8054\u7f51\u4f53\u9a8c\u3002<\/p>\n

Arduino\u4e0eLoRa\u7684\u65e0\u7ebf\u901a\u4fe1\u6280\u672f<\/h2>\n

  \u7b80\u4ecb<\/h3>\n

  \u5728\u7269\u8054\u7f51\u9886\u57df\uff0cArduino\u4f5c\u4e3a\u4e00\u79cd\u5e38\u7528\u7684\u5f00\u53d1\u677f\uff0c\u7ed3\u5408LoRa\u65e0\u7ebf\u901a\u4fe1\u6280\u672f\uff0c\u4e3a\u8bbe\u5907\u4e4b\u95f4\u7684\u901a\u4fe1\u63d0\u4f9b\u4e86\u5168\u65b0\u7684\u89e3\u51b3\u65b9\u6848\u3002LoRa\u6280\u672f\u5177\u6709\u8fdc\u8ddd\u79bb\u4f20\u8f93\u3001\u4f4e\u529f\u8017\u7b49\u4f18\u52bf\uff0c\u9002\u7528\u4e8e\u5404\u79cd\u73af\u5883\u4e0b\u7684\u6570\u636e\u4f20\u8f93\u9700\u6c42\u3002<\/p>\n

  \u642d\u5efaArduino\u4e0eLoRa\u901a\u4fe1\u73af\u5883<\/h3>\n

  \u9996\u5148\uff0c\u786e\u4fdd\u4f60\u5df2\u7ecf\u51c6\u5907\u597dArduino\u5f00\u53d1\u677f\u3001LoRa\u901a\u4fe1\u6a21\u5757\u4ee5\u53ca\u76f8\u5e94\u7684\u8fde\u63a5\u7ebf\u3002\u7136\u540e\u6309\u7167\u6587\u6863\u6307\u5f15\u8fde\u63a5\u786c\u4ef6\uff0c\u63a5\u901a\u7535\u6e90\u3002<\/p>\n

  \u63a5\u7740\uff0c\u5728Arduino\u96c6\u6210\u5f00\u53d1\u73af\u5883\u4e2d\uff0c\u5bfc\u5165LoRa\u901a\u4fe1\u5e93\uff0c\u7f16\u5199\u901a\u4fe1\u4ee3\u7801\u5e76\u4e0a\u4f20\u5230Arduino\u5f00\u53d1\u677f\u4e2d\u3002<\/p>\n

\u793a\u4f8b\u4ee3\u7801<\/h4>\n
 #include   

    void setup() {<\/p>

     LoRa.begin(433E6);<\/p>

    }<\/p>

    void loop() {<\/p>

     LoRa.beginPacket();<\/p>

     LoRa.print(\"Hello, LoRa!\");<\/p>

     LoRa.endPacket();<\/p>

     delay(1000);<\/p>

    }<\/p><\/lora.h><\/pre>\n

LoRa\u901a\u4fe1\u6570\u636e\u52a0\u5bc6\u4e0e\u89e3\u5bc6<\/h2>\n

  \u6570\u636e\u52a0\u5bc6\u65b9\u6cd5<\/h3>\n

  \u5728\u7269\u8054\u7f51\u5e94\u7528\u4e2d\uff0c\u6570\u636e\u5b89\u5168\u6027\u81f3\u5173\u91cd\u8981\u3002\u7ed3\u5408LoRa\u901a\u4fe1\u7684\u7279\u70b9\uff0c\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528\u52a0\u5bc6\u7b97\u6cd5\u5bf9\u6570\u636e\u8fdb\u884c\u4fdd\u62a4\u3002\u5e38\u7528\u7684\u52a0\u5bc6\u65b9\u6cd5\u5305\u62ecAES\u52a0\u5bc6\u7b49\uff0c\u786e\u4fdd\u6570\u636e\u4f20\u8f93\u7684\u5b89\u5168\u6027\u3002<\/p>\n

  \u6570\u636e\u89e3\u5bc6\u6d41\u7a0b<\/h3>\n

  \u63a5\u6536\u7aef\u63a5\u6536\u5230\u52a0\u5bc6\u6570\u636e\u540e\uff0c\u9700\u8981\u8fdb\u884c\u76f8\u5e94\u7684\u89e3\u5bc6\u64cd\u4f5c\u624d\u80fd\u83b7\u53d6\u539f\u59cb\u6570\u636e\u3002\u5728Arduino\u4e2d\uff0c\u53ef\u4ee5\u5229\u7528\u76f8\u540c\u7684\u52a0\u5bc6\u7b97\u6cd5\u8fdb\u884c\u89e3\u5bc6\u5904\u7406\uff0c\u786e\u4fdd\u6570\u636e\u7684\u5b8c\u6574\u6027\u548c\u51c6\u786e\u6027\u3002<\/p>\n

\u603b\u7ed3<\/h2>\n

  \u901a\u8fc7\u672c\u6587\u7684\u4ecb\u7ecd\uff0c\u4f60\u53ef\u4ee5\u4e86\u89e3\u5230\u5982\u4f55\u5229\u7528Arduino\u548cLoRa\u901a\u4fe1\u6a21\u5757\u8fdb\u884c\u65e0\u7ebf\u901a\u4fe1\u7684\u5f00\u53d1\u3002<\/strong>\u4ece\u642d\u5efa\u901a\u4fe1\u73af\u5883\u5230\u6570\u636e\u52a0\u5bc6\u89e3\u5bc6\uff0c\u4f60\u53ef\u4ee5\u6839\u636e\u5b9e\u9645\u9700\u6c42\u8fdb\u884c\u8c03\u6574\u548c\u4f18\u5316\uff0c\u4e3a\u7269\u8054\u7f51\u9879\u76ee\u63d0\u4f9b\u66f4\u53ef\u9760\u7684\u6570\u636e\u4f20\u8f93\u65b9\u6848\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

\u672c\u6587\u5c06\u6df1\u5165\u63a2\u8ba8\u5982\u4f55\u5229\u7528Arduino\u548cLoRa\u901a\u4fe1\u6a21\u5757\u8fdb\u884c\u65e0\u7ebf\u901a\u4fe1\u7684\u5f00\u53d1\uff0c\u4e3a\u4f60\u5e26\u6765\u5168\u65b0\u7684\u7269\u8054\u7f51\u4f53\u9a8c\u3002Arduino\u4e0eLoRa\u7684\u65e0\u7ebf\u901a\u4fe1\u6280\u672f\u7b80\u4ecb<\/p>\n","protected":false},"author":1,"featured_media":38352,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-global-header-display":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","footnotes":""},"categories":[36],"tags":[54,387],"class_list":["post-88651","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog","tag-l-2","tag-lora_communication"],"_links":{"self":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/88651"}],"collection":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/comments?post=88651"}],"version-history":[{"count":0,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/posts\/88651\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media\/38352"}],"wp:attachment":[{"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/media?parent=88651"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/categories?post=88651"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.techphant.cn\/wp-json\/wp\/v2\/tags?post=88651"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}