{"id":10640,"date":"2017-02-07T14:02:29","date_gmt":"2017-02-07T05:02:29","guid":{"rendered":"https:\/\/www.appliot.co.jp\/lazurite-jp\/?p=10640"},"modified":"2017-02-07T14:02:29","modified_gmt":"2017-02-07T05:02:29","slug":"%e3%82%89%e3%81%9a%e3%82%89%e3%81%84%e3%81%a8%e5%a7%ab%e3%81%ae%e6%8c%91%e6%88%a6%e6%97%a5%e8%a8%98%ef%bc%88%e7%ac%ac%ef%bc%93%ef%bc%96%e5%9b%9e%ef%bc%89%ef%bd%9e%e6%96%87%e5%ad%97%e5%88%97%ef%bd%9e","status":"publish","type":"post","link":"https:\/\/www.appliot.co.jp\/lazurite-jp\/%e3%82%89%e3%81%9a%e3%82%89%e3%81%84%e3%81%a8%e5%a7%ab%e3%81%ae%e6%8c%91%e6%88%a6%e6%97%a5%e8%a8%98\/10640.html","title":{"rendered":"\u3089\u305a\u3089\u3044\u3068\u59eb\u306e\u6311\u6226\u65e5\u8a18\uff08\u7b2c\uff13\uff16\u56de\uff09\uff5e\u6587\u5b57\u5217\uff5e"},"content":{"rendered":"<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1216.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10659\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1216-300x188.png\" alt=\"12\" width=\"300\" height=\"188\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1216-300x188.png 300w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1216.png 462w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<h2>\u30b3\u30d4\u30fc<\/h2>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/150.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10649\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/150-190x200.png\" alt=\"1\" width=\"190\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/150-190x200.png 190w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/150.png 340w\" sizes=\"auto, (max-width: 190px) 100vw, 190px\" \/><\/a><\/p>\n<p>A[n]\u3068\u3044\u3046\u914d\u5217\u3092B[n]\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002<\/p>\n<p>B[n]=A[n] \u00a0\u2192\u3000\u2613\u3000\u307e\u3068\u3081\u3066\u914d\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u305b\u3093\u3002<\/p>\n<p>B[0]=A[0]\u30fbB[1]=A[1]\u3000\u2192\u3000\u25cb\u3000\uff11\u30d0\u30a4\u30c8\u305a\u3064\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u306f\u51fa\u6765\u307e\u3059\u304c\u3001\u5927\u5909\u3067\u3059\u3002<\/p>\n<h4><strong><span style=\"text-decoration: underline;\">\u307e\u3068\u3081\u3066\u30b3\u30d4\u30fc\u3059\u308b\u65b9\u6cd5<\/span><\/strong><\/h4>\n<h3>memcpy(B,A,sizeof(B)):\u3000A\u3092B\u306bB\u306e\u30b5\u30a4\u30ba\u5206\u30b3\u30d4\u30fc\u3059\u308b<\/h3>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/225.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10650\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/225-193x200.png\" alt=\"2\" width=\"193\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/225-193x200.png 193w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/225.png 350w\" sizes=\"auto, (max-width: 193px) 100vw, 193px\" \/><\/a><\/p>\n<h3>memcpy(B,A,3):\u3000A\u3092B\u306b\uff13\u30d0\u30a4\u30c8\u5206\u30b3\u30d4\u30fc\u3059\u308b<\/h3>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1114.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10653\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1114-189x200.png\" alt=\"11\" width=\"189\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1114-189x200.png 189w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1114.png 336w\" sizes=\"auto, (max-width: 189px) 100vw, 189px\" \/><\/a><\/p>\n<h3>memset(B,0,sizeof(B)):\u3000B\u306bB\u306e\u30b5\u30a4\u30ba\u5206\uff10\uff08\u30bc\u30ed\uff09\u3092\u66f8\u304f<\/h3>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/419.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10652\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/419-67x200.png\" alt=\"4\" width=\"67\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/419-67x200.png 67w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/419.png 120w\" sizes=\"auto, (max-width: 67px) 100vw, 67px\" \/><\/a><\/p>\n<h3>strcpy(B,&#8221;Hello&#8221;): \u914d\u5217B\u306b&#8221;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b<\/h3>\n<p>\u305f\u3060\u3057\u3001\u914d\u5217B\u304c&#8221;Hello&#8221;\u3088\u308a\u3082\u77ed\u3044\u5834\u5408\u306bstrcpy\u3092\u4f7f\u7528\u3059\u308b\u3068\u914d\u5217B\u306e\u30b5\u30a4\u30ba\u3092\u8d85\u3048\u3066\u201dHELLO\u201d\u304c\u66f8\u304d\u8fbc\u307e\u308c\u3066\u3057\u307e\u3044\u307e\u3059\u3002\u914d\u5217B\u306e\u7d9a\u304d\u306e\u30e1\u30e2\u30ea\u306f\u5225\u306e\u76ee\u7684\u3067\u4f7f\u7528\u3055\u308c\u3066\u3044\u308b\u30c7\u30fc\u30bf\u304c\u5165\u3063\u3066\u3044\u308b\u306e\u3067\u3001\u4ed6\u306e\u30c7\u30fc\u30bf\u3092\u58ca\u3057\u3066\u3057\u307e\u3046\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/712.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10645\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/712-300x161.png\" alt=\"7\" width=\"300\" height=\"161\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/712-300x161.png 300w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/712.png 500w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>strcpy\u306f\u3001\u660e\u3089\u304b\u306b\u6587\u5b57\u5217\u304c\u914d\u5217\u3088\u308a\u3082\u5c0f\u3055\u3044\u5834\u5408\u306b\u3060\u3051\u4f7f\u7528\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>strncpy(B,&#8221;Hello&#8221;,sizeof(B)): \u914d\u5217B\u306b&#8221;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b<\/h3>\n<p>&#8220;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u304c\u914d\u5217B\u3088\u308a\u9577\u3044\u5834\u5408\u3001\u914d\u5217B\u306e\u30b5\u30a4\u30ba\u307e\u3067\u3057\u304b\u30b3\u30d4\u30fc\u3057\u307e\u305b\u3093\u3002strncpy\u306f\u3088\u308a\u5b89\u5168\u306b\u30c7\u30fc\u30bf\u3092\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u304c\u51fa\u6765\u307e\u3059\u3002<\/p>\n<h2>\u6bd4\u8f03\u7528\u95a2\u6570<\/h2>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/815.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10646\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/815-63x200.png\" alt=\"8\" width=\"63\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/815-63x200.png 63w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/815.png 112w\" sizes=\"auto, (max-width: 63px) 100vw, 63px\" \/><\/a><\/p>\n<p>A\u304c\u201dHELLO\u201d\u304b\u3092\u77e5\u308a\u305f\u3044\u3002<\/p>\n<p>A\u3068\u201dHELLO\u201d\u3092\u6bd4\u8f03\u3059\u308b\u65b9\u6cd5\u306f\uff12\u3064\u3042\u308a\u307e\u3059\u3002<\/p>\n<h4>\u2460strcmp(A,\u201dHELLO\u201d):\u3000A\u3092\u201dHELLO\u201d\u3068\u6bd4\u8f03\u3059\u308b<\/h4>\n<h4>\u2461strncmp(A,\u201dHELLO\u201d,sizeof(A)):\u3000A\u304c\u201dHELLO\u201d\u304b\u3092A\u306e\u30b5\u30a4\u30ba\u5206\u3060\u3051\u6bd4\u8f03\u3059\u308b<\/h4>\n<p>\u3044\u305a\u308c\u3082null\u30b3\u30fc\u30c9\u304c\u51fa\u3066\u304f\u308b\u307e\u3067\u6bd4\u8f03\u3092\u7d9a\u3051\u307e\u3059\u3002\u6587\u5b57\u5316\u3051\u304c\u767a\u751f\u3057\u3066\u3057\u307e\u3044null\u30b3\u30fc\u30c9\u304c\u306a\u304f\u306a\u3063\u3066\u3057\u307e\u3063\u305f\u5834\u5408\u306f\u3001strcmp\u306fnull\u304c\u898b\u3064\u304b\u308b\u307e\u3067\u6bd4\u8f03\u3092\u7d9a\u3051\u307e\u3059\u304c\u3001strncmp\u306f\u914d\u5217\u306e\u30b5\u30a4\u30ba\u3067\u5fc5\u305a\u7d42\u4e86\u3057\u307e\u3059\u3002<\/p>\n<h2>\u6587\u5b57\u3092\u6570\u5b57\u306b\u5909\u63db\u3059\u308b<\/h2>\n<p>\u6570\u5024\u3092\u6587\u5b57\u5217\u306b\u5909\u63db\u3059\u308b\u306e\u306f\u3001strtol\u3092\u4f7f\u7528\u3059\u308b\u306e\u304c\u4fbf\u5229\u3067\u3059\u3002<\/p>\n<p>strtol(\u6587\u5b57\u5217\u3001NULL\u30010)<\/p>\n<p>\u7b2c\u4e00\u5f15\u6570\uff1a\u3000\u6587\u5b57\u5217\u304c\u683c\u7d0d\u3055\u308c\u3066\u3044\u308b\u914d\u5217\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<br \/>\n\u7b2c\u4e8c\u5f15\u6570\uff1a\u3000\u6587\u5b57\u5217\u306e\u7d42\u4e86\u30dd\u30a4\u30f3\u30bf\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002NULL\u3092\u6307\u5b9a\u3057\u3066\u304a\u304f\u3068\u81ea\u52d5\u8a8d\u8b58\u3068\u306a\u308a\u307e\u3059\u3002<br \/>\n\u7b2c\u4e09\u5f15\u6570\uff1a\u3000\u6587\u5b57\u5217\u306e\u6570\u5b57\u306e\u57fa\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u30020\u306b\u3059\u308b\u3068\u81ea\u52d5\u8a8d\u8b58\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u4f8b\u3048\u3070\u3001<\/p>\n<p>long l = strtok(&#8220;100&#8221;,NULL,0);<br \/>\n\u3092\u5b9f\u884c\u3059\u308b\u3068\u3001l\u306b\u306f10\u9032\u6570\u306e100\u304c\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/913.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-10647\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/913.png\" alt=\"9\" width=\"215\" height=\"94\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/913.png 379w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/913-300x131.png 300w\" sizes=\"auto, (max-width: 215px) 100vw, 215px\" \/><\/a><\/p>\n<p>\u7d9a\u3044\u3066\u3001\u6b21\u306e\u95a2\u6570\u3092\u5b9f\u884c\u3057\u3066\u307f\u308b\u3068\u3001l\u306b\u306f10\u9032\u6570\u306e16\u300116\u9032\u6570\u306e0x10\u304c\u5165\u308a\u307e\u3059\u3002<\/p>\n<h3>long i = strtol(&#8220;0x10&#8221;,NULL,0)<\/h3>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1016.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-10648\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1016-215x200.png\" alt=\"10\" width=\"215\" height=\"200\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1016-215x200.png 215w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1016.png 382w\" sizes=\"auto, (max-width: 215px) 100vw, 215px\" \/><\/a><\/p>\n<p>strtol\u95a2\u6570\u306f\u300110\u9032\u6570\/8\u9032\u6570\/16\u9032\u6570\u306a\u3069\u306e\u57fa\u6570\u3092\u6307\u5b9a\u3057\u306a\u304f\u3066\u3082\u81ea\u52d5\u3067\u8a8d\u8b58\u3057\u3066\u304f\u308c\u308b\u306e\u3067\u3001\u6587\u5b57\u5217\u3092\u7c21\u5358\u306b\u6570\u5024\u5909\u63db\u3057\u3066\u304f\u308c\u307e\u3059\u3002<\/p>\n<h2>\u305d\u306e\u4ed6<\/h2>\n<p>\u305d\u306e\u307b\u304b\u306b\u4fbf\u5229\u306a\u95a2\u6570\u306f\u3001strtok\u3067\u3059\u3002CSV\u30d5\u30a1\u30a4\u30eb\uff08\u30ab\u30f3\u30de\u533a\u5207\u308a)\u306e\u6587\u5b57\u5217\u3092\u5206\u89e3\u3057\u3066\u3001\u305d\u308c\u305e\u308c\u3092\u6570\u5024\u306b\u76f4\u3059\u6642\u306b\u4fbf\u5229\u3067\u3059\u3002<\/p>\n<h2>\u8272\u3005\u3068\u8a66\u3057\u3066\u307f\u307e\u3057\u305f<\/h2>\n<p>\u4eca\u307e\u3067\u306e\u3053\u3068\u3092\u30d7\u30ed\u30b0\u30e9\u30e0\u306b\u307e\u3068\u3081\u3066\u307f\u307e\u3057\u305f\u306e\u3067\u3001\u6d3b\u7528\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u306d\u3002<\/p>\n<h5>\u30d7\u30ed\u30b0\u30e9\u30e0<\/h5>\n<p>[c]<\/p>\n<p>#include &quot;hime_mojiretsu_ide.h&quot; \/\/ Additional Header<\/p>\n<p>#include &quot;stdlib.h&quot;<\/p>\n<p>char A[32] = &quot;HELLO&quot;;<br \/>\nchar B[32] = {&quot;&quot;};;<\/p>\n<p>void setup() {<br \/>\n \/\/ put your setup code here, to run once:<br \/>\n int i;<br \/>\n long l;<br \/>\n char* data[8];<br \/>\n Serial.begin(115200);<\/p>\n<p>Serial.print(&quot;A[] = &quot;);<br \/>\n Serial.println(A);<\/p>\n<p> Serial.print(&quot;B[] = &quot;);<br \/>\n Serial.println(B);<\/p>\n<p>\/\/ \u6587\u5b57\u5217\u306e\u30b3\u30d4\u30fc\u3000<br \/>\n A[8] = 1; \/\/ \u30c0\u30df\u30fc\u30679\u30d0\u30a4\u30c8\u76ee\u306b1\u3092\u4ee3\u5165\u3057\u307e\u3057\u305f\u3002<\/p>\n<p> memcpy(B,A,sizeof(B)); \/\/ \u914d\u5217A\u3092\u914d\u5217B\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002<br \/>\n Serial.print(&quot;B[] = &quot;);<br \/>\n for(i=0;i&amp;lt;16;i++) \/\/ 9\u30d0\u30a4\u30c8\u76ee\u306b1\u304c\u5165\u3063\u3066\u3044\u307e\u3059<br \/>\n {<br \/>\n Serial.print_long(B[i],DEC);<br \/>\n Serial.print(&quot;,&quot;);<br \/>\n }<br \/>\n Serial.println(&quot;&quot;);<\/p>\n<p>memset(B,0,sizeof(B)); \/\/ \u914d\u5217\u30920\u306b\u30ea\u30bb\u30c3\u30c8\u3057\u307e\u3059<\/p>\n<p>Serial.print(&quot;B[] = &quot;); \/\/ \u914d\u5217B\u304c0\u306b\u30af\u30ea\u30a2\u3055\u308c\u307e\u3057\u305f<br \/>\n for(i=0;i&amp;lt;16;i++)<br \/>\n {<br \/>\n Serial.print_long(B[i],DEC);<br \/>\n Serial.print(&quot;,&quot;);<br \/>\n }<br \/>\n Serial.println(&quot;&quot;);<\/p>\n<p> strcpy(B,A); \/\/ \u914d\u5217A\u3092\u6587\u5b57\u5217\u3068\u3057\u3066B\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002<br \/>\n Serial.print(&quot;B[] = &quot;); \/\/ NULL\u30b3\u30fc\u30c9\u307e\u3067\u3057\u304b\u30b3\u30d4\u30fc\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002<br \/>\n for(i=0;i&amp;lt;16;i++)<br \/>\n {<br \/>\n Serial.print_long(B[i],DEC);<br \/>\n Serial.print(&quot;,&quot;);<br \/>\n }<br \/>\n Serial.println(&quot;&quot;);<\/p>\n<p>memset(B,0,sizeof(B)); \/\/ \u914d\u5217\u30920\u306b\u30ea\u30bb\u30c3\u30c8\u3057\u307e\u3059<\/p>\n<p>strncpy(B,A,3); \/\/ \u914d\u5217A\u3092\u6587\u5b57\u5217\u3068\u3057\u3066B\u306b\u6700\u59273\u6587\u5b57\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002<br \/>\n Serial.print(&quot;B[] = &quot;);<br \/>\n Serial.println(B);<\/p>\n<p>memset(B,0,sizeof(0));<\/p>\n<p>\/\/ \u6587\u5b57\u5217\u306e\u6bd4\u8f03\u3092\u884c\u3044\u307e\u3059\u3002<br \/>\n if (strcmp(B,A) == 0) Serial.println(&quot;B = A&quot;); \/\/ B=&quot;HE&quot;, A=&quot;HELLO&quot;\u3067\u6bd4\u8f03\u3092\u884c\u3044\u307e\u3059<br \/>\n else Serial.println(&quot;B != A&quot;);<\/p>\n<p>strcpy(B,A);<br \/>\n if (strcmp(B,A) == 0) Serial.println(&quot;B = A&quot;); \/\/ B=&quot;HELLO&quot;, A=&quot;HELLO&quot;\u3067\u6bd4\u8f03\u3092\u884c\u3044\u307e\uff53\u3002<br \/>\n else Serial.println(&quot;B != A&quot;);<\/p>\n<p>\/\/ \u6587\u5b57\u5217\u3092\u6570\u5024\u306b\u5909\u63db\u3057\u307e\u3059\u3002<br \/>\n l = strtol(&quot;100&quot;,NULL,0);<br \/>\n Serial.print(&quot;l = &quot;);<br \/>\n Serial.println_long(l,DEC);<\/p>\n<p>l = strtol(&quot;0x10&quot;,NULL,0);<br \/>\n Serial.print(&quot;l = &quot;);<br \/>\n Serial.println_long(l,DEC);<\/p>\n<p>\/\/ \u6700\u5f8c\u306bCSV\u5f62\u5f0f\u3092\u6570\u5024\u306b\u5909\u63db\u3002<br \/>\n strcpy(A,&quot;100,0&#215;100,0100&quot;);<br \/>\n Serial.print(&quot;A = &quot;);<br \/>\n Serial.println(A);<\/p>\n<p>data[0] = strtok(A,&quot;,\\r\\n&quot;); \/\/ \u914d\u5217A\u3092\u30ab\u30f3\u30de\u3001\u307e\u305f\u306f\u6539\u884c\u30de\u30fc\u30af\u3067\u533a\u5207\u308a\u307e\u3059<br \/>\n l = strtol(data[0],NULL,0);<br \/>\n Serial.print(&quot;data[0] = &quot;);<br \/>\n Serial.println_long(l,DEC);<\/p>\n<p> for(i=1;i&amp;lt;16;i++) {<br \/>\n data[i] = strtok(NULL,&quot;,\\r\\n&quot;); \/\/ \u524d\u56de\u306e\u7d9a\u304d\u304b\u3089\u6b21\u306e\u30ab\u30f3\u30de\u3001\u307e\u305f\u306f\u6539\u884c\u30de\u30fc\u30af\u307e\u3067\u3092\u5207\u308a\u51fa\u3057\u307e\u3059\u3002<\/p>\n<p> if(data[i] == NULL) break; \/\/ \u6587\u5b57\u5217\u304c\u7d42\u308f\u3063\u305f\u3089\u304a\u3057\u307e\u3044<\/p>\n<p>l = strtol(data[i],NULL,0);<br \/>\n Serial.print(&quot;data[&quot;);<br \/>\n Serial.print_long(i,DEC);<br \/>\n Serial.print(&quot;] = &quot;);<br \/>\n Serial.println_long(l,DEC);<br \/>\n }<br \/>\n}<\/p>\n<p>void loop() {<br \/>\n \/\/ put your main code here, to run repeatedly:<\/p>\n<p>}<\/p>\n<p>[\/c]<\/p>\n<h5>\u7d50\u679c<\/h5>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1313.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-10667 size-full\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1313.png\" alt=\"13\" width=\"894\" height=\"419\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1313.png 894w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1313-300x141.png 300w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/1313-640x300.png 640w\" sizes=\"auto, (max-width: 894px) 100vw, 894px\" \/><\/a><\/p>\n<p><a href=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/character_all.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-8039 size-large\" src=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/Laz-princess_footer-640x87.png\" alt=\"Laz-princess_footer\" width=\"640\" height=\"87\" srcset=\"https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/Laz-princess_footer-640x87.png 640w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/Laz-princess_footer-300x41.png 300w, https:\/\/www.appliot.co.jp\/lazurite-jp\/lapis_admin\/wp-content\/uploads\/Laz-princess_footer.png 769w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30b3\u30d4\u30fc A[n]\u3068\u3044\u3046\u914d\u5217\u3092B[n]\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002 B[n]=A[n] \u00a0\u2192\u3000\u2613\u3000\u307e\u3068\u3081\u3066\u914d\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u305b\u3093\u3002 B[0]=A[0]\u30fbB[1]=A[1]\u3000\u2192\u3000\u25cb\u3000\uff11\u30d0\u30a4\u30c8\u305a\u3064\u30b3\u30d4\u30fc\u3059\u308b\u3053\u3068\u306f\u51fa\u6765\u307e\u3059\u304c\u3001\u5927\u5909\u3067\u3059\u3002 \u307e\u3068\u3081\u3066\u30b3\u30d4\u30fc\u3059\u308b\u65b9\u6cd5 memcpy(B,A,sizeof(B)):\u3000A\u3092B\u306bB\u306e\u30b5\u30a4\u30ba\u5206\u30b3\u30d4\u30fc\u3059\u308b memcpy(B,A,3):\u3000A\u3092B\u306b\uff13\u30d0\u30a4\u30c8\u5206\u30b3\u30d4\u30fc\u3059\u308b memset(B,0,sizeof(B)):\u3000B\u306bB\u306e\u30b5\u30a4\u30ba\u5206\uff10\uff08\u30bc\u30ed\uff09\u3092\u66f8\u304f strcpy(B,&#8221;Hello&#8221;): \u914d\u5217B\u306b&#8221;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b \u305f\u3060\u3057\u3001\u914d\u5217B\u304c&#8221;Hello&#8221;\u3088\u308a\u3082\u77ed\u3044\u5834\u5408\u306bstrcpy\u3092\u4f7f\u7528\u3059\u308b\u3068\u914d\u5217B\u306e\u30b5\u30a4\u30ba\u3092\u8d85\u3048\u3066\u201dHELLO\u201d\u304c\u66f8\u304d\u8fbc\u307e\u308c\u3066\u3057\u307e\u3044\u307e\u3059\u3002\u914d\u5217B\u306e\u7d9a\u304d\u306e\u30e1\u30e2\u30ea\u306f\u5225\u306e\u76ee\u7684\u3067\u4f7f\u7528\u3055\u308c\u3066\u3044\u308b\u30c7\u30fc\u30bf\u304c\u5165\u3063\u3066\u3044\u308b\u306e\u3067\u3001\u4ed6\u306e\u30c7\u30fc\u30bf\u3092\u58ca\u3057\u3066\u3057\u307e\u3046\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 strcpy\u306f\u3001\u660e\u3089\u304b\u306b\u6587\u5b57\u5217\u304c\u914d\u5217\u3088\u308a\u3082\u5c0f\u3055\u3044\u5834\u5408\u306b\u3060\u3051\u4f7f\u7528\u3057\u3066\u304f\u3060\u3055\u3044\u3002 strncpy(B,&#8221;Hello&#8221;,sizeof(B)): \u914d\u5217B\u306b&#8221;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u3092\u30b3\u30d4\u30fc\u3059\u308b &#8220;Hello&#8221;\u3068\u3044\u3046\u6587\u5b57\u5217\u304c\u914d\u5217B\u3088\u308a\u9577\u3044\u5834\u5408\u3001\u914d\u5217B\u306e\u30b5\u30a4\u30ba\u307e\u3067\u3057 [&hellip;]<\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"footnotes":""},"categories":[21],"tags":[],"class_list":["post-10640","post","type-post","status-publish","format-standard","hentry","category-21"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/posts\/10640","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/comments?post=10640"}],"version-history":[{"count":0,"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/posts\/10640\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/media?parent=10640"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/categories?post=10640"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appliot.co.jp\/lazurite-jp\/wp-json\/wp\/v2\/tags?post=10640"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}