{"id":591,"date":"2020-12-24T21:23:20","date_gmt":"2020-12-24T13:23:20","guid":{"rendered":"http:\/\/124.244.86.40:8080\/wordpress\/?p=591"},"modified":"2020-12-24T21:24:29","modified_gmt":"2020-12-24T13:24:29","slug":"go-%e8%aa%9e%e8%a8%80%e5%9c%a8-linux-iot-%e9%96%8b%e7%99%bc%e6%9d%bf%e4%b8%8a%e8%99%95%e7%90%86%e5%a4%a7%e6%aa%94%e6%a1%88%e4%b8%8a%e5%82%b3%e7%9a%84%e8%a7%a3%e6%b1%ba%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/imuslab.com\/wordpress\/2020\/12\/24\/go-%e8%aa%9e%e8%a8%80%e5%9c%a8-linux-iot-%e9%96%8b%e7%99%bc%e6%9d%bf%e4%b8%8a%e8%99%95%e7%90%86%e5%a4%a7%e6%aa%94%e6%a1%88%e4%b8%8a%e5%82%b3%e7%9a%84%e8%a7%a3%e6%b1%ba%e6%96%b9%e6%b3%95\/","title":{"rendered":"Go \u8a9e\u8a00\u5728 Linux IoT \u958b\u767c\u677f\u4e0a\u8655\u7406\u5927\u6a94\u6848\u4e0a\u50b3\u7684\u89e3\u6c7a\u65b9\u6cd5"},"content":{"rendered":"\n<p>\u8fd1\u5e74\u4f86\u4e0d\u5c11\u672c\u4f86\u7528\u65bc\u7269\u806f\u7db2\u958b\u767c\u7684\u4e3b\u677f\u5df2\u7d93\u5dee\u4e0d\u591a\u5177\u5099 10 \u5e74\u524d\u96fb\u8166\u4e3b\u6a5f\u7684 IO \u901f\u5ea6\u548c\u8655\u7406\u6c34\u5e73\u4e86\u3002\u5728\u7db2\u4e0a\u4e0d\u96e3\u770b\u5230\u5177\u5099 1000Mbps \u7db2\u7d61\u63a5\u53e3\u4e26\u540c\u6642\u4f7f\u7528\u591a\u6838\u5fc3\u7684\u8655\u7406\u5668\u7684\u55ae\u7247\u96fb\u8166\uff08SBC\uff09\uff0c\u50f9\u683c\u4e0a\u4e5f\u4e0d\u592a\u8cb4\uff08\u7d04 100 &#8211; 120HKD \u4e00\u584a\uff09\uff0c\u53ef\u73a9\u6027\u9084\u662f\u5f88\u9ad8\u7684\u3002<\/p>\n\n\n\n<figure class=\"wp-block-gallery columns-2 is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex\"><ul class=\"blocks-gallery-grid\"><li class=\"blocks-gallery-item\"><figure><img loading=\"lazy\" decoding=\"async\" width=\"334\" height=\"329\" src=\"http:\/\/124.244.86.40:8080\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-16.png\" alt=\"\" data-id=\"592\" class=\"wp-image-592\" srcset=\"https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-16.png 334w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-16-300x296.png 300w\" sizes=\"auto, (max-width: 334px) 100vw, 334px\" \/><\/figure><\/li><li class=\"blocks-gallery-item\"><figure><img loading=\"lazy\" decoding=\"async\" width=\"375\" height=\"324\" src=\"http:\/\/124.244.86.40:8080\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-41.png\" alt=\"\" data-id=\"593\" data-full-url=\"http:\/\/124.244.86.40:8080\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-41.png\" data-link=\"http:\/\/124.244.86.40:8080\/wordpress\/?attachment_id=593\" class=\"wp-image-593\" srcset=\"https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-41.png 375w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_20-39-41-300x259.png 300w\" sizes=\"auto, (max-width: 375px) 100vw, 375px\" \/><\/figure><\/li><\/ul><figcaption class=\"blocks-gallery-caption\">\u5176\u4e2d\u6211\u4f7f\u7528\u904e\u7684\u5169\u7a2e\u958b\u767c\u677f\uff1aZeroPi \u8ddf OrangePi Zero Plus<\/figcaption><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">\u7136\u5f8c\uff0c\u6211\u60f3\u7528\u5b83\u4f86\u7d44\u7db2\u7d61\u5132\u5b58\u7cfb\u7d71<\/h4>\n\n\n\n<p>\u5c0d\uff0c\u7406\u8ad6\u4e0a\u4f60\u662f\u53ef\u4ee5\u7528\u9019\u7a2e SBC \u4f86\u505a\u7db2\u7d61\u5132\u5b58\u5668\uff08NAS\uff09\uff0c\u6211\u5011\u4e00\u500b\u4e00\u500b\u4f86\u770b\uff1a<br><\/p>\n\n\n\n<ol class=\"wp-block-list\"><li> \u2714\ufe0f  CPU: H3 \/ H5 \u8655\u7406\u5668 ( 1.3Ghz \uff0c\u4e00\u822c\u4f5c\u70ba\u6587\u4ef6\u4f3a\u670d\u5668\u5b8c\u5168\u6c92\u554f\u984c)<\/li><li> \u2714\ufe0f  1000Mbps Ethernet \/ \u7db2\u7d61\u63a5\u53e3<\/li><li> \u2714\ufe0f  USB2.0 \u63a5\u53e3\uff08480Mbps\uff0c\u5c0d\u65bc\u5bb6\u4e2d\u53ea\u6709 100Mbps \u4e0a\u4e0b\u8f09\u7684\u6211\u4f86\u8aaa\u5b8c\u8db3\u5920\uff09<\/li><li> \u2714\ufe0f  40 x 42 cm\uff0c\u53ef\u4ee5\u76f4\u63a5\u9ecf\u5728\u786c\u789f\u76d2\u5f8c\u9762<\/li><li> \u2714\ufe0f \u904b\u884c\u6642\u53ea\u9700\u8981 5V 0.2 &#8211; 0.3A\uff0c\u8d85\u7d1a\u7701\u96fb<\/li><\/ol>\n\n\n\n<h4 class=\"wp-block-heading\">\u53ef\u662f\u554f\u984c\u5c31\u662f\u5b83\u53ea\u6709 512MB \u7684 RAM \u554a\uff01\uff01\uff01<\/h4>\n\n\n\n<p>\u73fe\u5728\u9019\u5e74\u4ee3\u9023\u6700\u4fbf\u5b9c\u7684 Synology DS118 \u90fd\u8981\u6bd4\u5b83\u591a 512MB RAM \u554a\uff01 <\/p>\n\n\n\n<p>\u53ef\u662f\uff0c\u8981\u9019\u9ebc\u591a RAM \u5230\u5e95\u7528\u4f86\u5e79\u9ebc\uff1f<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Golang \u7db2\u9801\u4f3a\u670d\u5668\u7684\u6587\u4ef6\u4e0a\u8f09\u7684\u904b\u4f5c\u539f\u7406<\/h3>\n\n\n\n<p>\u4e00\u822c\u4f86\u8aaa\u4f7f\u7528 Golang \u8655\u7406\u6587\u4ef6\u4e0a\u8f09\u7684\u908f\u8f2f\u90fd\u9577\u9019\u6a23<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\nr.ParseMultipartForm(10 &lt;&lt; 20)\n\n file, handler, err := r.FormFile(\"myFile\")\n if err != nil {\n    fmt.Println(\"Error Retrieving the File\")\n    fmt.Println(err)\n    return\n}\ndefer file.Close()\n\n\/\/\u7136\u5f8c\u7528 io.Copy \u628a\u66ab\u5b58\u6a94\u6848\u8907\u5236\u5230\u76ee\u7684\u5730\uff0c\u9019\u88e1\u6211\u5c31\u4e0d\u4ed4\u7d30\u5beb\u4e86\n<\/code><\/pre>\n\n\n\n<p>\u5728\u4e00\u822c\u96fb\u8166\u4e0a\u904b\u884c\u9019\u6bb5\u4ee3\u78bc\u662f\u5b8c\u5168 OK \u7684\uff0c\u5728\u4e0a\u8f09\u6a94\u6848\u6642 Golang \u6703\u628a multipart form data \u4e2d\u7684\u6a94\u6848\u7de9\u5b58\u5230 RAM\uff0c\u7136\u5f8c\u5728 io.Copy \u4e4b\u5f8c\uff0cdefer \u7684 file.Close() \u6703\u628a Reader \u95dc\u6389\uff0c\u4e4b\u5f8c\u4ea4\u7531 GC \u8655\u7406\u522a\u9664\u3002<\/p>\n\n\n\n<p>\u9019\u60c5\u6cc1\u53ea\u80fd\u9069\u7528\u65bc\u4e0a\u8f09\u7684\u6a94\u6848\u6bd4\u7cfb\u7d71\u80fd\u7528\u7684 RAM \u9084\u8981\u7d30\u7684\u60c5\u6cc1\uff0c\u5c0d\u65bc\u50cf ZeroPi  \/ Orange Pi \u9019\u7a2e SBC \u8981\u4e0a\u8f09\u5927\u578b\u6a94\u6848\uff0c\u5c31\u4e0d\u80fd\u7528\u9019\u50b3\u7d71\u7684\u65b9\u6cd5\uff0c\u800c\u9700\u8981\u7279\u5225\u8655\u7406\u4e86\u3002\u4e0d\u7136\u5c31\u6703\u51fa\u73fe\u4ee5\u4e0b\u60c5\u6cc1<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"618\" height=\"137\" src=\"http:\/\/124.244.86.40:8080\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_11-02-54.png\" alt=\"\" class=\"wp-image-594\" srcset=\"https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_11-02-54.png 618w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_11-02-54-300x67.png 300w\" sizes=\"auto, (max-width: 618px) 100vw, 618px\" \/><figcaption>\u5c31\u662f\u6240\u8b02\u7684\u300c\u7206 RAM\u300d<\/figcaption><\/figure>\n\n\n\n<p>\u90a3\u8b93\u6211\u5011\u5148\u4f86\u4e86\u89e3\u4e00\u4e0b parseMultipartForm \u7684\u539f\u7406\u5427\uff0c\u7c21\u55ae\u4f86\u8aaa\u662f<\/p>\n\n\n\n<ol class=\"wp-block-list\"><li>\u4f60\u7684 browser \u628a\u6a94\u6848\u585e\u5230\u4e86\u4e00\u500b HTTP FORM \u88e1\u9762<\/li><li>browser \u628a FORM \u7684\u8cc7\u6599\u9023\u540c\u4f60\u8981\u7684\u6a94\u6848\u5728\u540c\u4e00\u500b\uff08\u6216\u591a\u500b\uff09 Request \u88e1\u9762\u9001\u5230\u4f3a\u670d\u5668<\/li><li>\u56e0\u70ba\u6a94\u6848\u592a\u5927\uff0c\u6c92\u6709\u8fa6\u6cd5\u4f7f\u7528\u540c\u4e00\u500b HTTP REQUEST \u8655\u7406\uff0c\u6240\u4ee5\u5230\u9054\u7684\u6642\u5019\u6a94\u6848\u53ef\u80fd\u88ab\u5207\u6210\u5e7e\u500b \u300c\u5340\u584a\u300d\uff0c\u800c\u9019\u500b\u5c31\u662f Multipart Form<\/li><li>Golang \u628a\u9019\u4e9b\u300c \u5340\u584a \u300d\u5beb\u5230 RAM \u88e1\u9762\uff08\u5728 Debian \u7684\u60c5\u6cc1\u4e0b\u5c31\u662f\u5beb\u5230 \/tmp \u88e1\u9762\uff09<\/li><li>\u7136\u5f8c\u5982\u679c\u6a94\u6848\u5927\u5c0f\u6bd4RAM \u5927\uff0c\/tmp \u5c31\u6703\u88ab\u585e\u7206\uff0c\u51fa\u73fe\u300cno space left on device\u300d\u932f\u8aa4<\/li><li>\u5982\u679c Golang \u7e7c\u7e8c\u628a\u6771\u897f\u585e\u9032\u53bb\uff0c\u5b83\u5c31\u6703\u88ab\u4f5c\u696d\u7cfb\u7d71\u6bba\u6389\uff08Killed\uff09<\/li><\/ol>\n\n\n\n<p>\u8981\u89e3\u6c7a\u9019\u500b\u554f\u984c\uff0c\u6211\u5011\u53ef\u4ee5\u4f7f\u7528\u5169\u500b\u65b9\u6cd5\uff0c\u9996\u5148\u662f\u4e0d\u8981\u4f7f\u7528 Golang \u5167\u7f6e\u7684 Request library\uff0c\u81ea\u5df1\u91cd\u65b0\u5beb\u4e00\u500b\u3002\u4f46\u662f\u90a3\u6a23\u5be6\u5728\u592a\u9ebb\u7169\u4e86\uff0c\u6240\u4ee5\u6211\u6c7a\u5b9a\u76f4\u63a5\u5728\u524d\u7aef\u4f5c\u66f4\u6539<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">WebSocket \u662f\u500b\u597d\u6771\u897f<\/h3>\n\n\n\n<p>\u8aaa\u5230 WebSocket \u5f88\u591a\u4eba\u6703\u60f3\u8d77\u985e\u4f3c Chatroom \u6216\u662f Web \u7684 online game \u4e4b\u985e\uff0c\u4f46\u662f WebSocket \u9664\u4e86\u80fd\u767c plain text \u4e4b\u5916\u9084\u80fd\u767c binary \u5594\uff01<\/p>\n\n\n\n<p>\u6240\u4ee5\uff0c\u65b0\u7684\u505a\u6cd5\u5c31\u5f88\u7c21\u55ae\uff1a<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">\u6211\u5011\u628a\u6a94\u6848\u5207\u6210\u597d\u5e7e\u5341\u5206\u5c0f\u7684\u5340\u584a\u50b3\u5230\u4f3a\u670d\u5668\u7aef\u518d\u7d44\u5408\u8d77\u4f86\u4e0d\u5c31\u884c\u4e86\u55ce\uff1f<\/h4>\n\n\n\n<p>\u5c0d\uff0c\u800c\u4e14\u9019\u4e5f\u5f88\u7c21\u55ae\uff0c\u53ea\u8981\u628a\u4e0a\u8f09\u7684 file object \u6839\u64da\u5927\u5c0f\u5207\u6210\u5c0f\u5340\u584a\u5c31\u53ef\u4ee5\u4e86\u3002\u6211\u9019\u88e1\u5074\u662f\u6839\u64da Hadoop Distributed File System \u7684\u5927\u6a94\u6848\u9810\u8a2d\u5207\u6210 4MB \u4e00\u500b\u5340\u584a\uff0c\u7136\u5f8c\u4e0a\u8f09\u5230\u4f3a\u670d\u5668 \/ Golang \u7684 endpoint<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>let socket = new WebSocket(\"\/api\/upload\");\nlet currentSendingIndex = 0;\nlet chunks = Math.ceil(file.size\/uploadFileChunkSize,uploadFileChunkSize);\n\n\/\/\u767c\u9001\u5340\u584a\u7684\u529f\u80fd\nfunction sendChunk(id){\n\tvar offsetStart = id*uploadFileChunkSize;\n\tvar offsetEnd = id*uploadFileChunkSize + uploadFileChunkSize;\n\tvar thisblob = file.slice(offsetStart,offsetEnd);\n\tsocket.send(thisblob);\n\n\t\/\/Update progress to first percentage\n\tvar progress = id \/ (chunks-1) * 100.0;\n\tif (progress > 100){\n\t\tprogress = 100;\n\t}\n\tconsole.log(\"Progress (%): \", progress)\n\t\n}<\/code><\/pre>\n\n\n\n<p>\u597d\u4e86\uff0c\u4e4b\u5f8c\u5c31\u5230\u5b89\u6392\u767c\u9001\u4e86\u3002\u7136\u800c\uff0c\u5176\u4e2d\u4e00\u500b\u91cd\u8981\u7684\u554f\u984c\u662f\uff1a<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">socket.Send() \u539f\u4f86\u662f async \u7684\u529f\u80fd\u6b38\uff01\uff1f<\/h4>\n\n\n\n<p>\u6240\u4ee5\uff0c\u70ba\u4e86\u89e3\u6c7a\u7528 for loop \u4f86\u9032\u884c sendChunk \u6703\u8b93\u592a\u591a\u500b\u5340\u584a\u540c\u6642\u767c\u9001\u7684\u554f\u984c\uff0c\u6211\u5011\u8981\u5148\u7b49\u5f85\u4f3a\u670d\u5668\u56de\u50b3\u4e00\u500b keyword \u6211\u5011\u518d\u767c\u4e0b\u4e00\u500b\u5340\u584a\uff0c\u904e\u7a0b\u5927\u7d04\u9019\u6a23\uff1a<\/p>\n\n\n\n<ol class=\"wp-block-list\"><li>\u7b49\u5f85 socket connection \u958b\u555f<\/li><li>\u958b\u555f\u5b8c\u6210\uff0c\u767c\u9001 0 \u865f\u5340\u584a<\/li><li>\u7b49\u5f85\u4f3a\u670d\u5668\u56de\u50b3 &#8220;next&#8221; \u5b57\u7b26<\/li><li>\u6536\u5230 &#8220;next&#8221; \u5b57\u7b26\uff0c\u767c\u9001 1\u865f\u5340\u584a<\/li><li>\u91cd\u8907 2 \u76f4\u5230\u6240\u6709\u5340\u584a\u5df2\u7d93\u767c\u9001\u5b8c\u7562<\/li><li>\u767c\u9001 &#8220;done&#8221;\uff0c\u544a\u8a34\u4f3a\u670d\u5668\u53ef\u4ee5\u958b\u59cb\u628a\u6a94\u6848\u5340\u584a\u7d44\u5408<\/li><li>\u7b49\u5f85\u4f3a\u670d\u5668\u56de\u50b3 &#8220;ok&#8221; \u4f5c\u70ba\u300c\u5b8c\u6210\u300d\u4fe1\u865f<\/li><li>\u95dc\u9589 socket connection<\/li><\/ol>\n\n\n\n<p>\u5ba2\u6236\u7aef\u7684 JavaScript \u5927\u6982\u9577\u9019\u6a23<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code> \/\/Start sending\nsocket.onopen = function(e) {\n\t\/\/Send the first chunk\n\tsendChunk(0);\n\tcurrentSendingIndex++;\n};\n\n\/\/On Server -> Client message\nsocket.onmessage = function(event) {\n\t\/\/Append to the send index\n\tvar incomingValue = event.data;\n\n\tif (incomingValue == \"next\"){\n\t\tif (currentSendingIndex == chunks + 1){\n\t\t\t\/\/Already finished\n\t\t\tsocket.send(\"done\");\n\t\t}else{\n\t\t\t\/\/Send next chunk\n\t\t\tsendChunk(currentSendingIndex);\n\t\t\tcurrentSendingIndex++;\n\t\t}\n\t  \n\t}else if (incomingValue == \"OK\"){\n\t\tconsole.log(\"Upload Completed!\");\n\t}\n\t\n}<\/code><\/pre>\n\n\n\n<p>\u800c\u5728 Golang \u7aef\uff0c\u6211\u662f\u4f7f\u7528 gorilla\/websocket \u9032\u884c\u958b\u767c\u7684\u3002\u8a73\u60c5\u898b <a href=\"https:\/\/github.com\/gorilla\/websocket\">https:\/\/github.com\/gorilla\/websocket <\/a><\/p>\n\n\n\n<p>\u9019\u88e1\u6211\u53ea\u628a\u91cd\u8981\u7684\u90e8\u5206\u986f\u793a\u51fa\u4f86\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/Define upload task paramters\nuploadFolder := \".\/upload\/\" + taskUUID\nchunkName := []string{}\n\n\/\/Start websocket connection\nvar upgrader = websocket.Upgrader{}\nc, err := upgrader.Upgrade(w, r, nil)\ndefer c.Close()\n\n\/\/Listen for incoming blob \/ string\nfor {\n\tmt, message, err := c.ReadMessage()\n\tif err != nil {\n\t\t\/\/Connection closed by client. Clear the tmp folder and exit\n\t\tlog.Println(\"Upload terminated by client. Cleaning tmp folder.\")\n\t\t\/\/Clear the tmp folder\n\t\ttime.Sleep(1 * time.Second)\n\t\tos.RemoveAll(uploadFolder)\n\t\treturn\n\t}\n\t\/\/The mt should be 2 = binary for file upload and 1 for control syntax\n\tif mt == 1 {\n\t\tmsg := strings.TrimSpace(string(message))\n\t\tif msg == \"done\" {\n\t\t\t\/\/Start the merging process\n\t\t\tlog.Println(userinfo.Username + \" uploaded a file: \" + targetUploadLocation)\n\t\t\tbreak\n\t\t} else {\n\t\t\t\/\/Unknown operations\n\n\t\t}\n\t} else if mt == 2 {\n\t\t\/\/File block. Save it to tmp folder\n\t\tchunkName = append(chunkName, filepath.Join(uploadFolder, \"upld_\"+strconv.Itoa(blockCounter)))\n\t\tioutil.WriteFile(filepath.Join(uploadFolder, \"upld_\"+strconv.Itoa(blockCounter)), message, 0700)\n\t\tblockCounter++\n\n\t\t\/\/Update the last upload chunk time\n\t\tlastChunkArrivalTime = time.Now().Unix()\n\n\t\t\/\/Request client to send the next chunk\n\t\tc.WriteMessage(1, []byte(\"next\"))\n\t}\n\t\/\/log.Println(\"recv:\", len(message), \"type\", mt)\n}\n\n\/\/Merge the file, please handle the error yourself!\nout, _ := os.OpenFile(targetUploadLocation, os.O_CREATE|os.O_WRONLY, 0755)\ndefer out.Close()\nfor _, filesrc := range chunkName {\n\tsrcChunkReader, err := os.Open(filesrc)\n\tif err != nil {\n\t\tlog.Println(\"Failed to open Source Chunk\", filesrc, \" with error \", err.Error())\n\t\tc.WriteMessage(1, []byte(`{\\\"error\\\":\\\"Failed to open Source Chunk\\\"}`))\n\t\treturn\n\t}\n\tio.Copy(out, srcChunkReader)\n\tsrcChunkReader.Close()\n}\n\n\/\/Return complete signal\nc.WriteMessage(1, []byte(\"OK\"))\n\t\n\/\/Clear the tmp folder\nos.RemoveAll(uploadFolder)\n\n\/\/Close WebSocket connection after finished\nc.WriteControl(8, []byte{}, time.Now().Add(time.Second))\nc.Close()\n\t<\/code><\/pre>\n\n\n\n<p>\u5c31\u662f\u9019\u6a23\uff0c\u6211\u5011\u5c31\u80fd\u6210\u529f\u7684\u5728 512MB \u7684\u958b\u767c\u677f\u4e0a\u4e0a\u8f09\u8d85\u904e RAM \u5bb9\u91cf\u7684\u6a94\u6848\u4e86\uff08\u6e2c\u8a66\u904e 1 &#8211; 2 GB \u7684\u6a94\u6848\u4e5f\u5b8c\u5168\u6c92\u554f\u984c\uff01\uff09<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"551\" src=\"http:\/\/124.244.86.40:8080\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_21-22-12-1024x551.png\" alt=\"\" class=\"wp-image-597\" srcset=\"https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_21-22-12-1024x551.png 1024w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_21-22-12-300x161.png 300w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_21-22-12-768x413.png 768w, https:\/\/imuslab.com\/wordpress\/wp-content\/uploads\/2020\/12\/2020-12-24_21-22-12.png 1074w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><figcaption>\u5728 512MB \u7684 ArozOS \u4e2d\u4f7f\u7528\u6b64\u65b9\u6cd5\u4e0a\u50b3\u4e00\u500b 1.05GB \u7684\u6a94\u6848 <\/figcaption><\/figure>\n\n\n\n<p>\u800c\u4e0a\u8f09\u901f\u5ea6\u561b\u2026 \u7531\u65bc\u6c92\u6709\u4e86 RAM \u7684\u7de9\u5b58\uff0c\u6240\u4ee5\u5c31\u770b\u4f60\u7684 SD \u5361\u901f\u5ea6\u56c9<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8fd1\u5e74\u4f86\u4e0d\u5c11\u672c\u4f86\u7528\u65bc\u7269\u806f\u7db2\u958b\u767c\u7684\u4e3b\u677f\u5df2\u7d93\u5dee\u4e0d\u591a\u5177\u5099 10 \u5e74\u524d\u96fb\u8166\u4e3b\u6a5f\u7684 IO \u901f\u5ea6\u548c\u8655\u7406\u6c34\u5e73\u4e86\u3002\u5728\u7db2\u4e0a\u4e0d\u96e3\u770b\u5230\u5177\u5099 1000Mbps \u7db2\u7d61\u63a5\u53e3\u4e26\u540c\u6642\u4f7f\u7528\u591a\u6838\u5fc3\u7684\u8655\u7406\u5668\u7684\u55ae\u7247\u96fb\u8166\uff08SBC\uff09\uff0c\u50f9\u683c\u4e0a\u4e5f\u4e0d\u592a\u8cb4\uff08\u7d04 100 &#8211; 120HKD \u4e00\u584a\uff09\uff0c\u53ef\u73a9\u6027\u9084\u662f\u5f88\u9ad8\u7684\u3002 \u7136\u5f8c\uff0c\u6211\u60f3\u7528\u5b83\u4f86\u7d44\u7db2\u7d61\u5132\u5b58\u7cfb\u7d71 \u5c0d\uff0c\u7406\u8ad6\u4e0a\u4f60\u662f\u53ef\u4ee5\u7528\u9019\u7a2e SBC \u4f86\u505a\u7db2\u7d61\u5132\u5b58\u5668\uff08NAS\uff09\uff0c\u6211\u5011\u4e00\u500b\u4e00\u500b\u4f86\u770b\uff1a \u2714\ufe0f CPU: H3 \/ H5 \u8655\u7406\u5668 ( 1.3Ghz \uff0c\u4e00\u822c\u4f5c\u70ba\u6587\u4ef6\u4f3a\u670d\u5668\u5b8c\u5168\u6c92\u554f\u984c) \u2714\ufe0f 1000Mbps Ethernet \/ \u7db2\u7d61\u63a5\u53e3 \u2714\ufe0f USB2.0 \u63a5\u53e3\uff08480Mbps\uff0c\u5c0d\u65bc\u5bb6\u4e2d\u53ea\u6709 100Mbps \u4e0a\u4e0b\u8f09\u7684\u6211\u4f86\u8aaa\u5b8c\u8db3\u5920\uff09 \u2714\ufe0f 40 x 42 cm\uff0c\u53ef\u4ee5\u76f4\u63a5\u9ecf\u5728\u786c\u789f\u76d2\u5f8c\u9762 \u2714\ufe0f \u904b\u884c\u6642\u53ea\u9700\u8981 5V 0.2 &#8211; 0.3A\uff0c\u8d85\u7d1a\u7701\u96fb \u53ef\u662f\u554f\u984c\u5c31\u662f\u5b83\u53ea\u6709 512MB \u7684 RAM \u554a\uff01\uff01\uff01 \u73fe\u5728\u9019\u5e74\u4ee3\u9023\u6700\u4fbf\u5b9c\u7684 Synology DS118 \u90fd\u8981\u6bd4\u5b83\u591a 512MB [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[29,3],"tags":[],"class_list":["post-591","post","type-post","status-publish","format-standard","hentry","category-aroz-online-system","category-instructions-and-information"],"_links":{"self":[{"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/posts\/591","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/comments?post=591"}],"version-history":[{"count":4,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/posts\/591\/revisions"}],"predecessor-version":[{"id":599,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/posts\/591\/revisions\/599"}],"wp:attachment":[{"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/media?parent=591"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/categories?post=591"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/imuslab.com\/wordpress\/wp-json\/wp\/v2\/tags?post=591"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}