{"id":10999,"date":"2024-04-17T10:28:25","date_gmt":"2024-04-17T01:28:25","guid":{"rendered":"https:\/\/blogs.mathworks.com\/japan-community\/?p=10999"},"modified":"2024-04-18T14:11:45","modified_gmt":"2024-04-18T05:11:45","slug":"embedded-coder-for-beginner","status":"publish","type":"post","link":"https:\/\/blogs.mathworks.com\/japan-community\/2024\/04\/17\/embedded-coder-for-beginner\/","title":{"rendered":"\u521d\u5fc3\u8005\u306e\u305f\u3081\u306e Embedded Coder : \u8a2d\u5b9aTips\u3068\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3092\u307e\u3068\u3081\u3066\u89e3\u8aac"},"content":{"rendered":"<p>\u672c\u65e5\u306f\u3001X (Twitter) \u3067\u3082\u304a\u306a\u3058\u307f\u3001<a href=\"https:\/\/twitter.com\/toshi34780378\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external\">Simulink\u306e\u4e2d\u306e\u4eba<\/a>\u304b\u3089\u306e\u6295\u7a3f\u3067\u3059\u3002<\/p>\n<hr \/>\n<p>\u4eca\u56de\u306f\u3001Embedded Coder \u306e\u6d3b\u7528\u65b9\u6cd5\u306b\u3064\u3044\u3066\u89e3\u8aac\u3057\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u521d\u5fc3\u8005\u306b\u306f\u3068\u3063\u3064\u304d\u306b\u304f\u3044\u30c4\u30fc\u30eb\u3067\u306f\u3042\u308a\u307e\u3059\u304c\u3001\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u30c7\u30b6\u30a4\u30f3\u306e\u4e2d\u6838\u3092\u306a\u3059\u91cd\u8981\u306a\u30c4\u30fc\u30eb\u3067\u3059\u3002\u4f7f\u3044\u3053\u306a\u305b\u308b\u3068\u3001\u958b\u767a\u5de5\u6570\u3092\u5927\u5e45\u306b\u524a\u6e1b\u3067\u304d\u307e\u3059\u306e\u3067\u3001\u662f\u975e\u4f7f\u3044\u3053\u306a\u305b\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u3087\u3046\uff01<\/p>\n<p>Note: \u672c\u8a18\u4e8b\u306e MATLAB, Simulink \u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u306f R2024a \u3092\u7528\u3044\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>\u76ee\u6b21:<\/h3>\n<p><a href=\"#what_is_code_gen\">1. \u30b3\u30fc\u30c9\u751f\u6210\u3068\u306f<\/a><br \/>\n<a href=\"#usefulness_of_code_gen\">\u00a0\u00a01.1. \u30b3\u30fc\u30c9\u751f\u6210\u306e\u3042\u308a\u304c\u305f\u307f<\/a><br \/>\n<a href=\"#embedded_coder_features\">\u00a0\u00a01.2. Embedded Coder \u306e\u7279\u5fb4<\/a><br \/>\n<a href=\"#goal\">2. \u4eca\u56de\u306e\u76ee\u6a19<\/a><br \/>\n<a href=\"#antisway_control\">\u00a0\u00a02.1. \u632f\u5b50\u306e\u632f\u308c\u6b62\u3081\u5236\u5fa1<\/a><br \/>\n<a href=\"#arduino_development_environment\">\u00a0\u00a02.2. Arduino \u958b\u767a\u74b0\u5883<\/a><br \/>\n<a href=\"#timer_interruption\">\u00a0\u00a02.3. \u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u3092\u8a2d\u8a08\u3059\u308b<\/a><br \/>\n<a href=\"#create_simulink_model\">3. Simulink \u30e2\u30c7\u30eb\u69cb\u7bc9<\/a><br \/>\n<a href=\"#simlink_modeling_for_code_gen\">\u00a0\u00a03.1. \u30b3\u30fc\u30c9\u751f\u6210\u306e\u305f\u3081\u306e Simulink \u30e2\u30c7\u30ea\u30f3\u30b0<\/a><br \/>\n<a href=\"#configuration_parameters_setting\">\u00a0\u00a03.2. \u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u8a2d\u5b9a\u65b9\u6cd5<\/a><br \/>\n<a href=\"#simulink_library\">\u00a0\u00a03.3. Simulink \u30e2\u30c7\u30eb\u304b\u3089\u751f\u6210\u3055\u308c\u305f\u30b3\u30fc\u30c9\u3092\u30e9\u30a4\u30d6\u30e9\u30ea\u7684\u306b\u4f7f\u3044\u305f\u3044\u5834\u5408<\/a><br \/>\n<a href=\"#embedded_coder_setting_tips\">\u00a0\u00a03.4. Embedded Coder \u8a2d\u5b9a Tips<\/a><br \/>\n<a href=\"#deploy_and_experiment\">4. \u5b9f\u88c5\u3068\u5b9f\u6a5f\u8a66\u9a13<\/a><br \/>\n<a href=\"#integrate_to_arduino\">\u00a0\u00a04.1. Arduino \u958b\u767a\u74b0\u5883\u3078\u7d71\u5408<\/a><br \/>\n<a href=\"#experiment\">\u00a0\u00a04.2. \u5b9f\u6a5f\u8a66\u9a13<\/a><br \/>\n<a href=\"#conclusion\">5. \u307e\u3068\u3081<\/a><\/p>\n<h1 id=\"what_is_code_gen\">1. \u30b3\u30fc\u30c9\u751f\u6210\u3068\u306f<\/h1>\n<p>\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001\u30b3\u30fc\u30c9\u751f\u6210\u3068\u306f\u4f55\u304b\u306b\u3064\u3044\u3066\u8aac\u660e\u3057\u307e\u3059\u3002<\/p>\n<h2 id=\"usefulness_of_code_gen\">1.1. \u30b3\u30fc\u30c9\u751f\u6210\u306e\u3042\u308a\u304c\u305f\u307f<\/h2>\n<p>\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u30c7\u30b6\u30a4\u30f3\uff08\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u958b\u767a\u3001MBD\uff09\u306f\u3001\u5236\u5fa1\u958b\u767a\u306e\u4e0a\u6d41\u5de5\u7a0b\u306b\u304a\u3044\u3066\u3001\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306b\u5b9f\u88c5\u3059\u308b\u5236\u5fa1\u30e2\u30c7\u30eb\u3068\u3001\u5236\u5fa1\u5bfe\u8c61\u3068\u306a\u308b\u7269\u7406\u30b7\u30b9\u30c6\u30e0\u30e2\u30c7\u30eb\u3092\u7d44\u307f\u5408\u308f\u305b\u305f\u5168\u4f53\u30b7\u30b9\u30c6\u30e0\u3092\u30b7\u30df\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u3067\u8868\u73fe\u3057\u3001\u3075\u308b\u307e\u3044\u3092\u691c\u8a3c\u3059\u308b\u624b\u6cd5\u3067\u3059\u3002\u8a73\u7d30\u306b\u3064\u3044\u3066\u306f\u3001<a href=\"https:\/\/jp.mathworks.com\/discovery\/mbd.html\" target=\"_blank\" rel=\"noopener\">\u3053\u3061\u3089<\/a>\u306e\u30da\u30fc\u30b8\u3092\u3054\u78ba\u8a8d\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u30c7\u30b6\u30a4\u30f3\u306e\u958b\u767a\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u306f\u3001\u4ee5\u4e0b\u306e\u300cV\u5b57\u30e2\u30c7\u30eb\u300d\u3067\u8868\u73fe\u3055\u308c\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1754\" height=\"805\" class=\"aligncenter size-full wp-image-11219\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_V_process.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">V\u5b57\u30e2\u30c7\u30eb<\/p>\n<p>&nbsp;<\/p>\n<p>V\u5b57\u306e\u5de6\u5074\u3067\u306f\u3001\u7269\u7406\u30b7\u30b9\u30c6\u30e0\u3068\u5236\u5fa1\u30b7\u30b9\u30c6\u30e0\u3092\u30b7\u30df\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30e2\u30c7\u30eb\u5316\u3057\u3001\u5b9f\u6a5f\u3092\u4f7f\u308f\u305a\u306b\u6a5f\u80fd\u306e\u691c\u8a3c\u3092\u884c\u3044\u307e\u3059\u3002\u305d\u306e\u5f8c\u3001V\u5b57\u306e\u53f3\u5074\u3067\u3001\u6700\u521d\u306f\u90e8\u5206\u7684\u306b\u5b9f\u6a5f\u3067\u3001\u6700\u5f8c\u306f\u5168\u3066\u5b9f\u6a5f\u3067\u8a66\u9a13\u3092\u884c\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u30b7\u30df\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u3092\u6d3b\u7528\u3057\u3066\u65e9\u671f\u306b\u6a5f\u80fd\u3092\u691c\u8a3c\u3059\u308b\u3053\u3068\u3067\u3001\u5b9f\u6a5f\u691c\u8a3c\u306e\u5de5\u6570\u3092\u524a\u6e1b\u3067\u304d\u308b\u3053\u3068\u304b\u3089\u3001\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u30c7\u30b6\u30a4\u30f3\u306f\u591a\u304f\u306e\u4f01\u696d\u306b\u53d6\u308a\u5165\u308c\u3089\u308c\u3066\u304d\u307e\u3057\u305f\u3002<\/p>\n<p>\u3053\u306eV\u5b57\u306e\u5de6\u5074\u304b\u3089\u53f3\u5074\u3078\u79fb\u884c\u3059\u308b\u6bb5\u968e\u3067\u3001\u5236\u5fa1\u30b7\u30b9\u30c6\u30e0\u3084\u7269\u7406\u30b7\u30b9\u30c6\u30e0\u3092\u5b9f\u6a5f\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3084\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u30b7\u30df\u30e5\u30ec\u30fc\u30bf\u30fc\u306b\u5b9f\u88c5\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u3068\u304d\u6d3b\u8e8d\u3059\u308b\u306e\u304c\u300c\u81ea\u52d5\u30b3\u30fc\u30c9\u751f\u6210\u300d\u3067\u3059\u3002<\/p>\n<h2 id=\"embedded_coder_features\">1.2. Embedded Coder \u306e\u7279\u5fb4<\/h2>\n<p>Embedded Coder \u306f\u3001MATLAB \u30b3\u30fc\u30c9\u3084 Simulink \u30e2\u30c7\u30eb\u3067\u4f5c\u3063\u305f\u6a5f\u80fd\u3092 C\/C++ \u8a00\u8a9e\u3078\u81ea\u52d5\u5909\u63db\u3059\u308b\u30c4\u30fc\u30eb\u30dc\u30c3\u30af\u30b9\u3067\u3059\u3002\u52b9\u7387\u7684\u306a\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3067\u304d\u3001\u307e\u305f\u30b3\u30fc\u30c9\u306e\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3082\u67d4\u8edf\u306b\u884c\u3048\u308b\u3053\u3068\u304b\u3089\u3001\u7d44\u307f\u8fbc\u307f\u30de\u30a4\u30b3\u30f3\u306b\u5b9f\u88c5\u3059\u308b\u76ee\u7684\u3067\u3088\u304f\u4f7f\u308f\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1872\" height=\"877\" class=\"aligncenter size-full wp-image-11222\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_EC_feature.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Embedded Coder\u306e\u7279\u5fb4<\/p>\n<p>&nbsp;<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001\u7269\u7406\u30b7\u30b9\u30c6\u30e0\u30e2\u30c7\u30eb\u3001\u4f8b\u3048\u3070\u300cSimscape\u300d\u3092\u4f7f\u3063\u3066\u4f5c\u3089\u308c\u305f\u30e2\u30c7\u30eb\u3082\u3001\u30b3\u30fc\u30c9\u751f\u6210\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u305f\u3060\u3057\u3001Simulink \u3067\u4f5c\u3089\u308c\u305f\u3082\u306e\u3068\u6bd4\u3079\u308b\u3068\u3001\u6700\u9069\u5316\u306f\u3055\u308c\u306a\u3044\u70b9\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002\uff08\u305d\u308c\u3067\u3082\u3001\u30b7\u30f3\u30d7\u30eb\u306a\u7269\u7406\u30e2\u30c7\u30eb\u3067\u3042\u308c\u3070\u30de\u30a4\u30b3\u30f3\u306b\u3082\u5b9f\u88c5\u3067\u304d\u307e\u3059\u3002\uff09\u4e00\u65b9\u3067\u300c<a href=\"https:\/\/blogs.mathworks.com\/japan-community\/2023\/04\/05\/stateflow-for-beginner\/\" target=\"_blank\" rel=\"noopener\">Stateflow<\/a>\u300d\u306f\u3001Embedded Coder \u3067\u6700\u9069\u306a\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u3082\u3057\u3001\u30b3\u30fc\u30c9\u751f\u6210\u6a5f\u80fd\u304c\u7121\u304b\u3063\u305f\u3089\u3001\u30e2\u30c7\u30eb\u3092\u4f5c\u6210\u3057\u305f\u5f8c\u3001\u305d\u306e\u30e2\u30c7\u30eb\u3068\u540c\u3058\u52d5\u304d\u3092\u3059\u308b\u30b3\u30fc\u30c9\u3092\u66f8\u304b\u306a\u3051\u308c\u3070\u306a\u308a\u307e\u305b\u3093\u3002\u3082\u3046\u4e00\u5ea6\u540c\u3058\u3082\u306e\u3092\u4f5c\u308b\u3068\u3044\u3046\u7121\u99c4\u306a\u4f5c\u696d\u304c\u751f\u3058\u3066\u3057\u307e\u3044\u307e\u3059\u3002\u30b3\u30fc\u30c9\u751f\u6210\u304c\u3042\u308c\u3070\u3001\u305d\u306e\u5de5\u7a0b\u3092\u7701\u7565\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1782\" height=\"928\" class=\"aligncenter size-full wp-image-11225\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_code_gen_merits.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Embedded Coder \u3092\u7528\u3044\u305f\u30bd\u30d5\u30c8\u958b\u767a\u306e\u30e1\u30ea\u30c3\u30c8\u200b<\/p>\n<p>&nbsp;<\/p>\n<p>\u3067\u306f\u3001\u6700\u521d\u304b\u3089 C\/C++ \u3067\u6a5f\u80fd\u3092\u4f5c\u308c\u3070\u3088\u3044\u3001\u3068\u3044\u3046\u53cd\u8ad6\u3082\u3042\u308d\u3046\u304b\u3068\u601d\u3044\u307e\u3059\u3002\u3057\u304b\u3057 MATLAB, Simulink \u306f\u3001\u30e2\u30c7\u30ea\u30f3\u30b0\u3001\u30c7\u30d0\u30c3\u30b0\u3001\u7d50\u679c\u306e\u53ef\u8996\u5316\u6a5f\u80fd\u306b\u512a\u308c\u3066\u3044\u307e\u3059\u3002\u5206\u304b\u308a\u3084\u3059\u304f\u30b0\u30e9\u30d5\u30a3\u30ab\u30eb\u306b\u30e2\u30c7\u30eb\u5316\u3067\u304d\u308b\u3053\u3068\u306b\u3088\u308a\u3001\u4ed6\u8005\u3068\u5171\u6709\u3001\u5171\u540c\u958b\u767a\u3082\u3057\u3084\u3059\u3044\u3067\u3059\u3002<\/p>\n<h1 id=\"goal\">2. \u4eca\u56de\u306e\u76ee\u6a19<\/h1>\n<p>\u4eca\u56de\u306f\u3001Quanser \u793e\u306e <a href=\"https:\/\/www.quanser.com\/products\/qube-servo-2\/\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external\">QUBE \u2013 Servo 2<\/a> \u3068\u3044\u3046\u5012\u7acb\u632f\u5b50\u88c5\u7f6e\u3092\u7528\u3044\u3066\u3001\u632f\u308c\u6b62\u3081\u5236\u5fa1\u3092\u8a2d\u8a08\u3057\u3066\u307f\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002\u5236\u5fa1\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u306e\u4e2d\u8eab\u306b\u3064\u3044\u3066\u306f\u3001\u4ee5\u524d\u306b\u884c\u3044\u307e\u3057\u305f<a href=\"https:\/\/www.youtube.com\/watch?v=_HAnqWwxDBc\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external\">\u3053\u3061\u3089<\/a>\u306e\u30bb\u30df\u30ca\u30fc\u3067\u7528\u3044\u305f\u3082\u306e\u3092\u305d\u306e\u307e\u307e\u6d41\u7528\u3057\u307e\u3059\u3002\u672c\u8a18\u4e8b\u3067\u306f\u3001\u5236\u5fa1\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u306e\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u306b\u30d5\u30a9\u30fc\u30ab\u30b9\u3057\u3066\u8aac\u660e\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<h2 id=\"antisway_control\">2.1. \u632f\u5b50\u306e\u632f\u308c\u6b62\u3081\u5236\u5fa1<\/h2>\n<p>\u5b9f\u6a5f\u306e\u69cb\u6210\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<p style=\"text-align: center;\"><img decoding=\"async\" loading=\"lazy\" width=\"1321\" height=\"892\" class=\"aligncenter size-full wp-image-11228\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_experiment_quanser_scene.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u5b9f\u6a5f\u69cb\u6210\u56f3<\/p>\n<p>&nbsp;<\/p>\n<p>QUBE \u2013 Servo 2 \u306f\u3001SPI\u901a\u4fe1\u3067\u96fb\u5727\u6307\u4ee4\u5024\u3092\u53d7\u3051\u53d6\u308a\u3001\u305d\u306e\u96fb\u5727\u3092PWM\u3067\u5236\u5fa1\u3057\u3001DC\u30e2\u30fc\u30bf\u30fc\u3092\u52d5\u304b\u3057\u307e\u3059\u3002\u305d\u308c\u306b\u3088\u3063\u3066\u6839\u5143\u3068\u632f\u308a\u5b50\u304c\u305d\u308c\u305e\u308c\u56de\u8ee2\u3057\u307e\u3059\u3002\u6839\u5143\u90e8\u5206\u3068\u632f\u308a\u5b50\u90e8\u5206\u306e\u56de\u8ee2\u89d2\u5ea6\u304c\u30a8\u30f3\u30b3\u30fc\u30c0\u30fc\u3067\u8a08\u6e2c\u3055\u308c\u3066\u304a\u308a\u3001\u305d\u306e\u5024\u3092SPI\u901a\u4fe1\u3067\u5916\u90e8\u306b\u51fa\u529b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001\u305d\u306eSPI\u901a\u4fe1\u306e\u76f8\u624b\u3068\u3057\u3066\u300cArduino Due\u300d\u3092\u7528\u3044\u307e\u3059\u3002\u632f\u308c\u6b62\u3081\u5236\u5fa1\u306e\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u306f\u3001Arduino Due \u306b\u5b9f\u88c5\u3057\u307e\u3059\u3002<\/p>\n<h2 id=\"arduino_development_environment\">2.2. Arduino \u958b\u767a\u74b0\u5883<\/h2>\n<p>Arduino\u306f\u300c<a href=\"https:\/\/jp.mathworks.com\/matlabcentral\/fileexchange\/40312-simulink-support-package-for-arduino-hardware\" target=\"_blank\" rel=\"noopener\">Simulink Support Package for Arduino Hardware<\/a>\u300d\u3092\u4f7f\u3048\u3070\u3001\u5168\u304fC\/C++\u30b3\u30fc\u30c9\u306b\u89e6\u308c\u308b\u3053\u3068\u306a\u304f\u5236\u5fa1\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u3092\u5b9f\u88c5\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u958b\u767a\u306e\u73fe\u5834\u3067\u306f\u3001\u91cf\u7523\u88fd\u54c1\u306b Arduino \u3092\u7528\u3044\u308b\u3053\u3068\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u901a\u5e38\u3001\u91cf\u7523\u88fd\u54c1\u306b\u4f7f\u308f\u308c\u308b\u30de\u30a4\u30b3\u30f3\u306b\u306f\u305d\u308c\u305e\u308c\u56fa\u6709\u306e\u958b\u767a\u74b0\u5883\u304c\u3042\u308a\u3001\u305d\u306e\u4e2d\u3067C\/C++\u30b3\u30fc\u30c9\u3092\u66f8\u3044\u3066\u3044\u304f\u3053\u3068\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001Arduino \u3092\u59cb\u3081\u3068\u3057\u3066\u3001\u591a\u304f\u306e\u30de\u30a4\u30b3\u30f3\u306b\u5bfe\u3057\u3066\u4e00\u3064\u306e\u74b0\u5883\u3067\u958b\u767a\u304c\u3067\u304d\u308b\u300cPlatformIO\u300d\u3092\u7528\u3044\u307e\u3059\u3002PlatformIO \u306f\u3001Visual Sudio Code \u306e\u62e1\u5f35\u6a5f\u80fd\u3068\u3057\u3066\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3057\u3066\u3001Visual Sudio Code \u3092\u30d9\u30fc\u30b9\u306b\u958b\u767a\u304c\u3067\u304d\u308b\u306e\u3067\u3068\u3066\u3082\u6709\u96e3\u3044\u30c4\u30fc\u30eb\u3067\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1626\" height=\"951\" class=\"aligncenter size-full wp-image-11231\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_platformio.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">PlatformIO<\/p>\n<p>&nbsp;<\/p>\n<h2 id=\"timer_interruption\">2.3. \u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u3092\u8a2d\u8a08\u3059\u308b<\/h2>\n<p>\u901a\u5e38\u3001PID\u5236\u5fa1\u306a\u3069\u306e\u5236\u5fa1\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u306f\u3001\u4e00\u5b9a\u6642\u9593\u9593\u9694\u3067\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3055\u308c\u308b\u5f62\u3067\u3001\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306b\u5b9f\u88c5\u3055\u308c\u307e\u3059\u3002\u305d\u306e\u305f\u3081\u3001\u307e\u305a\u306f\u300c\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u300d\u3092\u30de\u30a4\u30b3\u30f3\u306b\u5b9f\u88c5\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u306a\u305c\u30bf\u30a4\u30de\u30fc\u5272\u308a\u8fbc\u307f\u304b\u3068\u3044\u3046\u3068\u3001\u901a\u5e38\u306f\u4e00\u5b9a\u9593\u9694\u3067\u6642\u9593\u3092\u523b\u3080\u3068\u3044\u3046\u3053\u3068\u304c\u3001Z\u5909\u63db\u306e\u524d\u63d0\u6761\u4ef6\u3067\u3059\u306e\u3067\u3001\u305d\u308c\u3092\u5b9f\u73fe\u3059\u308b\u305f\u3081\u3067\u3059\u3002\u8a73\u3057\u304f\u306f\u5236\u5fa1\u5de5\u5b66\u306e\u6559\u79d1\u66f8\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u306e\u5b9f\u88c5\u65b9\u6cd5\u306f\u30de\u30a4\u30b3\u30f3\u306b\u3088\u3063\u3066\u5909\u308f\u308a\u307e\u3059\u3002Arduino Due \u3067\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u66f8\u304f\u3053\u3068\u3067\u5b9f\u73fe\u3067\u304d\u307e\u3057\u305f\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1727\" height=\"1021\" class=\"aligncenter size-full wp-image-11237\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_deploy_timer_interrupt.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u306e\u5b9f\u88c5<\/p>\n<p>&nbsp;<\/p>\n<h1 id=\"create_simulink_model\">3. Simulink \u30e2\u30c7\u30eb\u69cb\u7bc9<\/h1>\n<p>\u4eca\u56de\u306e\u30c7\u30e2\u306b\u304a\u3044\u3066\u3001\u5b9f\u88c5\u3057\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u6a5f\u80fd\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<ol>\n<li><strong>SPI\u901a\u4fe1\u3067 Quanser \u304b\u3089\u4fe1\u53f7\u5024\u3092\u53d7\u3051\u53d6\u308b<\/strong><\/li>\n<li><strong>\u53d7\u3051\u53d6\u3063\u305f\u4fe1\u53f7\u5024\u3092\u89d2\u5ea6\u3068\u89d2\u901f\u5ea6\u306e\u5024\u306b\u5909\u63db\u3059\u308b<\/strong><\/li>\n<li><strong>\u89d2\u5ea6\u3068\u89d2\u901f\u5ea6\u306e\u5024\u304b\u3089\u5236\u5fa1\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0\u3092\u8a08\u7b97\u3057\u3001\u6b21\u306e\u6307\u4ee4\u5024\u96fb\u5727\u3092\u5f97\u308b<\/strong><\/li>\n<li><strong>\u6307\u4ee4\u5024\u96fb\u5727\u3092SPI\u901a\u4fe1\u306e\u4fe1\u53f7\u5024\u306b\u5909\u63db\u3059\u308b<\/strong><\/li>\n<li><strong>SPI\u901a\u4fe1\u3067 Quanser \u3078\u4fe1\u53f7\u5024\u3092\u9001\u308b<\/strong><\/li>\n<\/ol>\n<p>\u3053\u308c\u3089\u5168\u3066\u3092\u3001Simulink \u3067\u30e2\u30c7\u30eb\u5316\u3059\u308b\u5fc5\u8981\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u30e2\u30c7\u30eb\u5316\u3059\u3079\u304d\u306a\u306e\u306f\u30012, 3, 4 \u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u306a\u305c\u304b\u3001\u5206\u304b\u308a\u307e\u3059\u3067\u3057\u3087\u3046\u304b\u3002SPI\u901a\u4fe1\u306e\u95a2\u6570\u306a\u3069\u306f\u3001\u30de\u30a4\u30b3\u30f3\u306b\u4f9d\u5b58\u3059\u308b\u51e6\u7406\u3067\u3059\u3002Simulink \u306f\u57fa\u672c\u7684\u306b\u306f\u3001\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306b\u56fa\u6709\u306e\u51e6\u7406\u3092\u5b9f\u88c5\u3059\u308b\u3053\u3068\u3092\u610f\u56f3\u3057\u3066\u3044\u307e\u305b\u3093\u3002\u3084\u308d\u3046\u3068\u601d\u3048\u3070\u3067\u304d\u308b\u306e\u3067\u3059\u304c\u3001\u305d\u3053\u307e\u3067\u3059\u308b\u30e1\u30ea\u30c3\u30c8\u304c\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u7686\u3055\u3093\u306b\u306f\u3001\u662f\u975e\u300c\u6a5f\u80fd\u306e\u62bd\u8c61\u5316\u30ec\u30a4\u30e4\u30fc\u300d\u306e\u8003\u3048\u65b9\u3092\u7406\u89e3\u3057\u3066\u307b\u3057\u3044\u3068\u601d\u3063\u3066\u3044\u307e\u3059\u3002\u6c7a\u307e\u3063\u305f\u5f62\u306f\u7121\u3044\u3067\u3059\u304c\u3001\u4eca\u56de\u306e\u4f8b\u306b\u6cbf\u3063\u3066\u3056\u3063\u304f\u308a\u3057\u305f\u6982\u5ff5\u56f3\u3092\u4ee5\u4e0b\u306b\u63cf\u304d\u307e\u3057\u305f\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1057\" height=\"741\" class=\"aligncenter size-full wp-image-11240\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_abstruction_layer.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u6a5f\u80fd\u306e\u62bd\u8c61\u5316\u30ec\u30a4\u30e4\u30fc<\/p>\n<p>&nbsp;<\/p>\n<p>Simulink \u3067\u30e2\u30c7\u30ea\u30f3\u30b0\u3059\u3079\u304d\u306a\u306e\u306f\u3001\u300c\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u5c64\u300d\u306e\u51e6\u7406\u3067\u3059\u3002\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u5c64\u306f\u3001\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306b\u4f9d\u5b58\u3057\u306a\u3044\u6a5f\u80fd\u3067\u3059\u3002\u4f8b\u3048\u3070\u5c06\u6765\u300c\u5225\u306e\u30de\u30a4\u30b3\u30f3\u306b\u3053\u306e\u6a5f\u80fd\u3092\u5b9f\u88c5\u3057\u305f\u3044\u300d\u3068\u601d\u3063\u305f\u6642\u3001\u4eca\u56de\u4f5c\u6210\u3057\u305f\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u5c64\u306e\u30e2\u30c7\u30eb\u306f\u305d\u306e\u307e\u307e\u30b3\u30fc\u30c9\u751f\u6210\u3057\u3066\u5b9f\u88c5\u3067\u304d\u307e\u3059\u3002\u5225\u306e\u30de\u30a4\u30b3\u30f3\u306b\u5b9f\u88c5\u3059\u308b\u3055\u3044\u306b\u5fc5\u8981\u306b\u306a\u308b\u306e\u306f\u3001\u6a5f\u80fd\u306e\u62bd\u8c61\u5316\u30ec\u30a4\u30e4\u30fc\u56f3\u306b\u304a\u3051\u308b\u300c\u5165\u51fa\u529b\u5c64\u300d\u3084\u300cOS, \u30d7\u30ed\u30bb\u30c3\u30b5\u5c64\u300d\u3092\u3001\u5225\u306e\u30de\u30a4\u30b3\u30f3\u306b\u5bfe\u5fdc\u3057\u305f\u3082\u306e\u306b\u5dee\u3057\u66ff\u3048\u308b\u4f5c\u696d\u3067\u3059\u3002<\/p>\n<p>\u5f93\u3063\u3066\u3001\u6a5f\u80fd\u691c\u8a3c\u306e\u52b9\u7387\u5316\u3084\u8cc7\u7523\u306e\u6d41\u7528\u304c\u3068\u3066\u3082\u3084\u308a\u3084\u3059\u304f\u306a\u308a\u307e\u3059\u3002<\/p>\n<h2 id=\"simlink_modeling_for_code_gen\">3.1. \u30b3\u30fc\u30c9\u751f\u6210\u306e\u305f\u3081\u306e Simulink \u30e2\u30c7\u30ea\u30f3\u30b0<\/h2>\n<p>2.3.\u7bc0\u3067\u8aac\u660e\u3057\u305f\u901a\u308a\u3001\u5236\u5fa1\u30a2\u30d7\u30ea\u306f\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u306b\u3088\u308a\u3001\u4e00\u5b9a\u5468\u671f\u3067\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002\u3064\u307e\u308a\u3001Simulink\u30e2\u30c7\u30eb\u3082\u305d\u306e\u524d\u63d0\u3067\u30e2\u30c7\u30ea\u30f3\u30b0\u3055\u308c\u3066\u3044\u306a\u3051\u308c\u3070\u306a\u308a\u307e\u305b\u3093\u3002\u30e2\u30c7\u30eb\u306e\u30b5\u30f3\u30d7\u30eb\u6642\u9593\u3092\u78ba\u8a8d\u3057\u3001\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u306e\u6642\u9593\u9593\u9694\u3068\u4e00\u81f4\u3057\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1917\" height=\"947\" class=\"aligncenter size-full wp-image-11243\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_check_sampling_time.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b5\u30f3\u30d7\u30ea\u30f3\u30b0\u30bf\u30a4\u30e0\u30b9\u30c6\u30c3\u30d7\u306e\u78ba\u8a8d<\/p>\n<p>&nbsp;<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001\u8907\u6570\u306e\u30b5\u30f3\u30d7\u30eb\u6642\u9593\u3092\u6301\u3064\u30e2\u30c7\u30eb\u3092\u30b3\u30fc\u30c9\u751f\u6210\u3057\u3001\u305d\u308c\u305e\u308c\u306e\u30b5\u30f3\u30d7\u30eb\u6642\u9593\u306e\u30d6\u30ed\u30c3\u30af\u3054\u3068\u306b\u5225\u3005\u306e\u30bf\u30a4\u30de\u30fc\u5272\u8fbc\u307f\u306b\u6e21\u3059\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\u8a73\u3057\u304f\u306f<a href=\"https:\/\/twitter.com\/toshi34780378\/status\/1606062030770917408\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external\">\u3053\u3061\u3089<\/a>\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u6b21\u306b\u3001\u30e2\u30c7\u30eb\u306e\u6700\u4e0a\u4f4d\u968e\u5c64\u306b\u5165\u529b\u30dd\u30fc\u30c8\u3068\u51fa\u529b\u30dd\u30fc\u30c8\u3092\u7528\u610f\u3057\u307e\u3057\u3087\u3046\u3002\u624b\u66f8\u304d\u306e\u30b3\u30fc\u30c9\u3068\u7d50\u5408\u3059\u308b\u6642\u306b\u3001\u30c7\u30fc\u30bf\u3092\u53d7\u3051\u6e21\u3059\u51e6\u7406\u3092\u884c\u3044\u307e\u3059\u3002\u3053\u306e\u6642\u3001\u305d\u306e\u53d7\u3051\u6e21\u3057\u306f Inport \u30d6\u30ed\u30c3\u30af\u3068 Outport \u30d6\u30ed\u30c3\u30af\u3067\u884c\u3044\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1021\" height=\"681\" class=\"aligncenter size-full wp-image-11246\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_inport_and_outport.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Inport\u3068Outport<\/p>\n<p>&nbsp;<\/p>\n<h2 id=\"configuration_parameters_setting\">3.2. \u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u8a2d\u5b9a\u65b9\u6cd5<\/h2>\n<p>Embedded Coder \u306e\u8a2d\u5b9a\u306f\u3001\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u3067\u884c\u3044\u307e\u3059\u3002\u3053\u3053\u3067\u306f\u3001\u57fa\u672c\u7684\u306a\u8a2d\u5b9a\u65b9\u6cd5\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n<p>\u307e\u305a\u3001\u300c\u30bd\u30eb\u30d0\u30fc\u300d\u3067\u3001\u56fa\u5b9a\u30b9\u30c6\u30c3\u30d7\u30bd\u30eb\u30d0\u30fc\u306b\u8a2d\u5b9a\u3057\u3001\u56fa\u5b9a\u30b9\u30c6\u30c3\u30d7\u30b5\u30a4\u30ba\u306b\u30b5\u30f3\u30d7\u30eb\u6642\u9593\u3092\u660e\u793a\u7684\u306b\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1896\" height=\"933\" class=\"aligncenter size-full wp-image-11249\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_config_solver.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u30bd\u30eb\u30d0\u30fc\u8a2d\u5b9a<\/p>\n<p>&nbsp;<\/p>\n<p>\u6b21\u306b\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u3067\u3001\u30b7\u30b9\u30c6\u30e0\u30bf\u30fc\u30b2\u30c3\u30c8\u30d5\u30a1\u30a4\u30eb\u3092\u300cert.tlc\u300d\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u3053\u306e\u8a2d\u5b9a\u306b\u3088\u308a\u3001Embedded Coder\u3092\u4f7f\u3063\u3066\u30b3\u30fc\u30c9\u751f\u6210\u3059\u308b\u3001\u3068\u3044\u3046\u3053\u3068\u3092\u660e\u793a\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1568\" height=\"994\" class=\"aligncenter size-full wp-image-11459\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/04\/EC_config_code_gen.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u30b3\u30fc\u30c9\u751f\u6210<\/p>\n<p>&nbsp;<\/p>\n<p>\u4efb\u610f\u3067\u3059\u304c\u3001\u300c\u30ec\u30dd\u30fc\u30c8\u300d\u306b\u3066\u300c\u30b3\u30fc\u30c9\u751f\u6210\u30ec\u30dd\u30fc\u30c8\u3092\u4f5c\u6210\u300d\u300c\u9759\u7684\u30b3\u30fc\u30c9\u30e1\u30c8\u30ea\u30af\u30b9\u306e\u751f\u6210\u300d\u306b\u30c1\u30a7\u30c3\u30af\u3092\u5165\u308c\u308b\u3053\u3068\u3092\u304a\u3059\u3059\u3081\u3057\u307e\u3059\u3002\u751f\u6210\u3055\u308c\u305f\u30b3\u30fc\u30c9\u304c\u3069\u306e\u3088\u3046\u306b\u69cb\u6210\u3055\u308c\u3066\u3044\u308b\u304b\u3001\u30b0\u30ed\u30fc\u30d0\u30eb\u5909\u6570\u3084\u30b9\u30bf\u30c3\u30af\u306e\u30e1\u30e2\u30ea\u6d88\u8cbb\u91cf\u306e\u898b\u7a4d\u3082\u308a\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1188\" height=\"974\" class=\"aligncenter size-full wp-image-11255\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_config_report.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u30ec\u30dd\u30fc\u30c8<\/p>\n<p>&nbsp;<\/p>\n<p>\u4ee5\u4e0a\u3067\u3001\u57fa\u672c\u7684\u306a\u30b3\u30fc\u30c9\u751f\u6210\u306e\u8a2d\u5b9a\u306f\u5b8c\u4e86\u3057\u307e\u3057\u305f\u3002\u300c\u30a2\u30d7\u30ea\u300d\u30bf\u30d6\u304b\u3089\u300cEmbedded Coder\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3001\u65b0\u3057\u304f\u8868\u308c\u305f\u30bf\u30d6\u304b\u3089\u300c\u30d3\u30eb\u30c9\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u30b3\u30fc\u30c9\u304c\u751f\u6210\u3055\u308c\u3001Simulink\u306e\u30a6\u30a3\u30f3\u30c9\u30a6\u3067\u306f\u3001\u30e2\u30c7\u30eb\u3068\u751f\u6210\u30b3\u30fc\u30c9\u306e\u6bd4\u8f03\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1916\" height=\"878\" class=\"aligncenter size-full wp-image-11258\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_compare_model_and_code.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Simulink\u30e2\u30c7\u30eb\u3001\u30b3\u30fc\u30c9\u306e\u6bd4\u8f03<\/p>\n<p>&nbsp;<\/p>\n<h2 id=\"simulink_library\">3.3. Simulink \u30e2\u30c7\u30eb\u304b\u3089\u751f\u6210\u3055\u308c\u305f\u30b3\u30fc\u30c9\u3092\u30e9\u30a4\u30d6\u30e9\u30ea\u7684\u306b\u4f7f\u3044\u305f\u3044\u5834\u5408<\/h2>\n<p>\u4e00\u822c\u7684\u306b\u3001Simulink \u306f\u6642\u9593\u7684\u306a\u30b7\u30df\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u3092\u884c\u3046\u305f\u3081\u306e\u74b0\u5883\u3067\u3059\u3002\u305d\u306e\u305f\u3081\u3001Simulink \u30e2\u30c7\u30eb\u304b\u3089\u751f\u6210\u3059\u308b\u30b3\u30fc\u30c9\u306f\u3001\u9023\u7d9a\u7684\u306b\u6642\u9593\u7684\u306a\u9032\u5c55\u3092\u884c\u3046\u3053\u3068\u3092\u524d\u63d0\u3068\u3057\u305f\u30b3\u30fc\u30c9\u3068\u306a\u308a\u307e\u3059\u3002\u3064\u307e\u308a\u3001\u30e2\u30c7\u30eb\u4e00\u3064\u304c\u3072\u3068\u307e\u3068\u307e\u308a\u3068\u306a\u3063\u3066\u3001step\u95a2\u6570\u3092\u5b9f\u884c\u3059\u308b\u3054\u3068\u306b\u6642\u9593\u9032\u5c55\u3059\u308b\u30b3\u30fc\u30c9\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3057\u304b\u3057\u4e00\u65b9\u3067\u3001Simulink \u306f\u30c7\u30fc\u30bf\u30d5\u30ed\u30fc\u56f3\u306e\u30e2\u30c7\u30ea\u30f3\u30b0\u30c4\u30fc\u30eb\u3067\u3059\u3002\u5358\u7d14\u306b\u5165\u529b\u3068\u51e6\u7406\u3068\u51fa\u529b\u306e\u95a2\u4fc2\u3092\u30e2\u30c7\u30ea\u30f3\u30b0\u3057\u3001\u305d\u306e\u6a5f\u80fd\u3060\u3051\u3092\u30b3\u30fc\u30c9\u751f\u6210\u3057\u305f\u3044\u5834\u5408\u3082\u3042\u308a\u307e\u3059\u3002\u3064\u307e\u308a\u3001\u30e2\u30c7\u30eb\u5185\u306e\u30b5\u30d6\u30b7\u30b9\u30c6\u30e0\u4e00\u3064\u4e00\u3064\u3092\u95a2\u6570\u3084\u30e9\u30a4\u30d6\u30e9\u30ea\u3068\u3057\u3066\u30b3\u30fc\u30c9\u751f\u6210\u3057\u305f\u3044\u5834\u5408\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u5834\u5408\u306f\u3001\u30e2\u30c7\u30eb\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\u30a4\u30f3\u30b9\u30da\u30af\u30bf\u30fc\u304b\u3089\u300c\u5b9f\u884c\u9818\u57df\u306e\u8a2d\u5b9a\u300d\u300c\u9818\u57df\u300d\u3092\u300c\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u300d\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001Simulink \u30e2\u30c7\u30eb\u306f\u6642\u9593\u306b\u4f9d\u5b58\u3057\u306a\u3044\u30e2\u30c7\u30eb\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1315\" height=\"740\" class=\"aligncenter size-full wp-image-11261\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_set_export_function.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u306b\u8a2d\u5b9a\u3059\u308b<\/p>\n<p>&nbsp;<\/p>\n<p>\u3053\u306e\u72b6\u614b\u306e\u30e2\u30c7\u30eb\u3067\u306f\u3001\u9023\u7d9a\u6642\u9593\u306e\u30d6\u30ed\u30c3\u30af\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u305b\u3093\u3002\u30e2\u30c7\u30eb\u306f\u3001\u6642\u9593\u306b\u4f9d\u5b58\u305b\u305a\u3001\u3042\u3089\u3086\u308b\u30bf\u30a4\u30df\u30f3\u30b0\u3067\u547c\u3073\u51fa\u3055\u308c\u308b\u3001\u3068\u3044\u3046\u524d\u63d0\u3067\u30e2\u30c7\u30ea\u30f3\u30b0\u3055\u308c\u3066\u3044\u306a\u3051\u308c\u3070\u306a\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001Simulink Function\u3068\u3044\u3046\u30b5\u30d6\u30b7\u30b9\u30c6\u30e0\u304c\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u30e2\u30c7\u30eb\u3068\u76f8\u6027\u304c\u3088\u3044\u306e\u3067\u304a\u52e7\u3081\u3067\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1467\" height=\"917\" class=\"aligncenter size-full wp-image-11264\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_export_simulink_function.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u306eSimulink Function<\/p>\n<p>&nbsp;<\/p>\n<p>\u4eca\u56de\u306e\u4f8b\u3067\u306f\u3001SPI\u901a\u4fe1\u306e\u4fe1\u53f7\u3092\u5909\u63db\u3059\u308b\u90e8\u5206\u3092\u3001\u3053\u306e\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u306e\u30e2\u30c7\u30eb\u3067\u4f5c\u6210\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002Simulink Function \u306f\u3001MATLAB\u306e\u95a2\u6570\u306e\u3088\u3046\u306b\u3001\u5165\u529b\u3068\u51fa\u529b\u3092\u8a18\u8ff0\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u306e\u5165\u529b\u3068\u51fa\u529b\u304c\u3001\u300cArgument Inport\u300d\u300cArgument Outport\u300d\u30d6\u30ed\u30c3\u30af\u3068\u3057\u3066\u30b5\u30d6\u30b7\u30b9\u30c6\u30e0\u5185\u306b\u73fe\u308c\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1445\" height=\"638\" class=\"aligncenter size-full wp-image-11267\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_argument_blocks.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Argument\u30d6\u30ed\u30c3\u30af<\/p>\n<p>&nbsp;<\/p>\n<p>\u5185\u90e8\u306e\u51e6\u7406\u3092\u4f5c\u308a\u3001\u30b3\u30fc\u30c9\u751f\u6210\u3092\u884c\u3046\u3068\u3001\u30d6\u30ed\u30c3\u30af\u3054\u3068\u306bC\u8a00\u8a9e\u306e\u95a2\u6570\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1917\" height=\"762\" class=\"aligncenter size-full wp-image-11270\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_c_code_of_export_function.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u306e\u30b3\u30fc\u30c9\u751f\u6210C<\/p>\n<p>&nbsp;<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001C++\u3067\u30b3\u30fc\u30c9\u751f\u6210\u3059\u308b\u3068\u3001\u30e2\u30c7\u30eb\u304c\u4e00\u3064\u306e\u30af\u30e9\u30b9\u3068\u306a\u308a\u3001Simulink Function\u306f\u305d\u306e\u30af\u30e9\u30b9\u306e\u30e1\u30bd\u30c3\u30c9\u306b\u306a\u308b\u306e\u3067\u3001\u7ba1\u7406\u304c\u3057\u3084\u3059\u304f\u306a\u308b\u306e\u3067\u304a\u52e7\u3081\u3067\u3059\u3002C++\u3067\u30b3\u30fc\u30c9\u751f\u6210\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001\u3053\u306e\u5f8c\u306e3.4.3\u7bc0\u3092\u3054\u78ba\u8a8d\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1914\" height=\"823\" class=\"aligncenter size-full wp-image-11273\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_cpp_code_of_export_function.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u95a2\u6570\u306e\u30b3\u30fc\u30c9\u751f\u6210C++<\/p>\n<p>&nbsp;<\/p>\n<h2 id=\"embedded_coder_setting_tips\">3.4. Embedded Coder \u8a2d\u5b9a Tips<\/h2>\n<p>\u3053\u306e\u7bc0\u3067\u306f\u3001\u521d\u5fc3\u8005\u304c\u3064\u307e\u3065\u304f\u30dd\u30a4\u30f3\u30c8\u3084\u3001\u73fe\u5834\u306e\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306b\u5b9f\u88c5\u3059\u308b\u305f\u3081\u306b\u77e5\u3063\u3066\u304a\u304f\u3079\u304d\u304a\u3059\u3059\u3081\u306e\u8a2d\u5b9a\u306a\u3069\u306b\u3064\u3044\u3066\u7d39\u4ecb\u3057\u307e\u3059\u3002\u4ee5\u4e0b\u306b\u6298\u308a\u305f\u305f\u3093\u3067\u3044\u307e\u3059\u306e\u3067\u3001\u8208\u5473\u306e\u3042\u308b\u65b9\u306f\u30af\u30ea\u30c3\u30af\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>&nbsp;<\/p>\n<details>\n<summary>\u3000<span style=\"color: red;\">\u25bd\u3053\u3061\u3089\u3092\u30af\u30ea\u30c3\u30af<\/span><\/summary>\n<p>&nbsp;<\/p>\n<h3>3.4.1. \u300c\u30d3\u30eb\u30c9\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u305f\u6642\u306b\u767a\u751f\u3059\u308b\u30a8\u30e9\u30fc\u306e\u5bfe\u51e6\u6cd5<\/h3>\n<p>\u300c\u30d3\u30eb\u30c9\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u305f\u6642\u3001\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3059\u308b\u5834\u5408\u304c\u3042\u308a\u307e\u3059\u3002\u5178\u578b\u4f8b\u3068\u3057\u3066\u3001\u30b3\u30f3\u30d1\u30a4\u30e9\u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u306a\u3044\u304b\u3089\u3001\u3068\u3044\u3046\u5834\u5408\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u3082\u3057 MATLAB \u306b\u30b3\u30f3\u30d1\u30a4\u30e9\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u3044\u306a\u3044\u65b9\u306f\u3001\u30b3\u30f3\u30d1\u30a4\u30e9\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304f\u3060\u3055\u3044\u3002Windows \u5411\u3051\u306e\u7121\u6599\u30b3\u30f3\u30d1\u30a4\u30e9\u3068\u3057\u3066\u306f <a href=\"https:\/\/jp.mathworks.com\/matlabcentral\/fileexchange\/52848-matlab-support-for-mingw-w64-c-c-fortran-compiler\" target=\"_blank\" rel=\"noopener\">MATLAB Support for MinGW-w64 C\/C++\/Fortran Compiler<\/a> \u304c\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u306a\u305c\u30b3\u30f3\u30d1\u30a4\u30e9\u304c\u5fc5\u8981\u306a\u306e\u304b\u3068\u3044\u3046\u3068\u3001\u300c\u30d3\u30eb\u30c9\u3092\u5b9f\u884c\u3059\u308b\u300d\u3068\u306f\u3001\u305d\u306ePC\u3067\u5b9f\u884c\u3067\u304d\u308b\u5b9f\u884c\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3059\u308b\u3068\u3044\u3046\u3053\u3068\u3060\u304b\u3089\u3067\u3059\u3002\u3064\u307e\u308a\u3001Simulink \u30e2\u30c7\u30eb\u3092\u89e3\u6790\u3001C\/C++\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3001\u751f\u6210\u3057\u305f\u30b3\u30fc\u30c9\u3092\u30b3\u30f3\u30d1\u30a4\u30eb\u3001\u30ea\u30f3\u30af\u3001\u5b9f\u884c\u30d5\u30a1\u30a4\u30eb\u5316\u307e\u3067\u3092\u4e00\u6c17\u306b\u884c\u3046\u306e\u304c\u300c\u30d3\u30eb\u30c9\u300d\u30dc\u30bf\u30f3\u306e\u6a5f\u80fd\u3067\u3059\u3002<\/p>\n<p>\u4e00\u5fdc\u3001\u5b9f\u884c\u30d5\u30a1\u30a4\u30eb\u5316\u307e\u3067\u3084\u3063\u3066\u3057\u307e\u3063\u305f\u65b9\u304c\u3001\u300c\u751f\u6210\u3057\u305f\u30b3\u30fc\u30c9\u304c\u3061\u3083\u3093\u3068\u30a8\u30e9\u30fc\u306a\u304f\u30d3\u30eb\u30c9\u3067\u304d\u3066\u3044\u308b\u300d\u3068\u78ba\u8a8d\u3067\u304d\u308b\u306e\u3067\u3001\u826f\u3044\u9762\u3082\u3042\u308a\u307e\u3059\u3002\u305f\u3060\u3001\u305d\u3053\u307e\u3067\u3057\u306a\u304f\u3066\u3082\u3044\u3044\u5834\u5408\u3082\u3042\u308b\u306e\u3067\u3001\u304a\u597d\u307f\u3067\u305d\u308c\u3092\u3057\u306a\u3044\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u300c\u30d3\u30eb\u30c9\u300d\u30dc\u30bf\u30f3\u306e\u30d7\u30eb\u30c0\u30a6\u30f3\u30e1\u30cb\u30e5\u30fc\u304b\u3089\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002\u3053\u306e\u6a5f\u80fd\u3092\u4f7f\u3046\u3068\u3001\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3059\u308b\u6240\u307e\u3067\u3067\u30b9\u30c8\u30c3\u30d7\u3059\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1037\" height=\"459\" class=\"aligncenter size-full wp-image-11276\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_code_gen_buttion.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30fc\u30c9\u751f\u6210\u306e\u30dc\u30bf\u30f3<\/p>\n<p>&nbsp;<\/p>\n<p>\u3053\u306e\u6642\u3001\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u306e\u8a2d\u5b9a\u3067\u300c\u30b3\u30fc\u30c9\u751f\u6210\u306e\u307f\u300d\u306b\u81ea\u52d5\u7684\u306b\u30c1\u30a7\u30c3\u30af\u304c\u5165\u308a\u307e\u3059\u3002\u3053\u3053\u306b\u30c1\u30a7\u30c3\u30af\u3092\u5165\u308c\u3066\u3044\u308b\u3068\u3001\u30d3\u30eb\u30c9\u306f\u884c\u308f\u306a\u3044\u8a2d\u5b9a\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1206\" height=\"983\" class=\"aligncenter size-full wp-image-11279\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_config_code_gen_only-1.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u30b3\u30fc\u30c9\u751f\u6210\u306e\u307f\u306e\u8a2d\u5b9a<\/p>\n<p>&nbsp;<\/p>\n<h3>3.4.2. \u5165\u51fa\u529b\u306e\u6e21\u3057\u65b9\u3092\u5909\u3048\u305f\u3044<\/h3>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u8a2d\u5b9a\u3067\u306f\u3001\u751f\u6210\u30b3\u30fc\u30c9\u306e\u5165\u51fa\u529b\u306f\u30b0\u30ed\u30fc\u30d0\u30eb\u5909\u6570\u306b\u3088\u308b\u53d7\u3051\u6e21\u3057\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1159\" height=\"434\" class=\"aligncenter size-full wp-image-11282\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_inout_default.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30c7\u30d5\u30a9\u30eb\u30c8\u30b3\u30fc\u30c9\u751f\u6210\u306e\u5165\u51fa\u529b\u53d7\u3051\u6e21\u3057<\/p>\n<p>&nbsp;<\/p>\n<p>\u30b0\u30ed\u30fc\u30d0\u30eb\u5909\u6570\u3067\u306f\u306a\u304f\u3066\u3001\u4f8b\u3048\u3070\u4e00\u822c\u7684\u306a\u3084\u308a\u65b9\u3067\u3042\u308bGet, Set\u95a2\u6570\u3092\u4f7f\u3046\u65b9\u6cd5\u306b\u3057\u305f\u3044\u5834\u5408\u3082\u3042\u308a\u307e\u3059\u3002\u305d\u306e\u5834\u5408\u306f\u3001\u300cC\u30b3\u30fc\u30c9\u300d\u30bf\u30d6\u306e\u300c\u30b3\u30fc\u30c9\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3001\u300c\u898f\u5b9a\u306e\u30b3\u30fc\u30c9\u30de\u30c3\u30d4\u30f3\u30b0\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3001Inports, Outports\u306e\u8a2d\u5b9a\u3092\u300cGetSet\u300d\u306b\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1404\" height=\"365\" class=\"aligncenter size-full wp-image-11285\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_code_mapping_change_inout.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u898f\u5b9a\u306e\u30b3\u30fc\u30c9\u30de\u30c3\u30d4\u30f3\u30b0\u304b\u3089IO\u306e\u8a2d\u5b9a\u3092GetSet\u306b\u5909\u66f4<\/p>\n<p>&nbsp;<\/p>\n<p>\u3053\u306e\u6642\u3001\u30d3\u30eb\u30c9\u3092\u3059\u308b\u3068\u30a8\u30e9\u30fc\u306b\u306a\u308a\u307e\u3059\u3002\u306a\u305c\u304b\u3068\u3044\u3046\u3068\u3001GetSet\u306e\u95a2\u6570\u81ea\u4f53\u304c\u3001\u751f\u6210\u30b3\u30fc\u30c9\u306e\u4e2d\u3067\u5b9a\u7fa9\u3055\u308c\u3066\u3044\u306a\u3044\u304b\u3089\u3067\u3059\u3002\u5b9f\u306f\u3001GetSet\u4ee5\u5916\u306b\u3082\u3053\u3046\u3044\u3046\u3053\u3068\u304c\u8d77\u304d\u308b\u8a2d\u5b9a\u9805\u76ee\u304c\u3061\u3089\u307b\u3089\u5b58\u5728\u3057\u3066\u3044\u308b\u306e\u3067\u3001\u6c17\u3092\u3064\u3051\u3066\u304f\u3060\u3055\u3044\u3002\uff08\u524d\u8ff0\u3057\u305f\u30b3\u30fc\u30c9\u751f\u6210\u306e\u307f\u306e\u8a2d\u5b9a\u3092\u65bd\u3059\u3068\u30a8\u30e9\u30fc\u306f\u51fa\u306a\u304f\u306a\u308a\u307e\u3059\uff09<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1844\" height=\"472\" class=\"aligncenter size-full wp-image-11288\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_get_set_error.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">GetSet\u306b\u3057\u305f\u5834\u5408\u306e\u30a8\u30e9\u30fc<\/p>\n<p>&nbsp;<\/p>\n<p>GetSet\u306e\u95a2\u6570\u3092\u5916\u90e8\u30d5\u30a1\u30a4\u30eb\u3067\u5b9a\u7fa9\u3057\u305f\u5834\u5408\u3001\u751f\u6210\u3055\u308c\u305f\u30b3\u30fc\u30c9\u306e\u4e2d\u306b\u3001\u305d\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u53c2\u7167\u3059\u308b\u305f\u3081\u306b\u300c#include~~\u300d\u3092\u66f8\u304b\u306a\u3044\u3068\u3044\u3051\u307e\u305b\u3093\u3088\u306d\u3002\u305d\u308c\u3092\u3059\u308b\u5834\u5408\u306f\u3001\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u300c\u30ab\u30b9\u30bf\u30e0\u30b3\u30fc\u30c9\u300d\u306e\u30a4\u30f3\u30af\u30eb\u30fc\u30c9\u30d8\u30c3\u30c0\u30fc\u306e\u6240\u306b\u3001\u300c#include~~\u300d\u3092\u8a18\u5165\u3057\u307e\u3059\u3002<\/p>\n<p>\u305d\u3046\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u751f\u6210\u30b3\u30fc\u30c9\u306e\u4e2d\u306b\u30a4\u30f3\u30af\u30eb\u30fc\u30c9\u3092\u8ffd\u52a0\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1616\" height=\"888\" class=\"aligncenter size-full wp-image-11291\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_custom_code_header.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30ab\u30b9\u30bf\u30e0\u30b3\u30fc\u30c9\u306e\u30a4\u30f3\u30af\u30eb\u30fc\u30c9\u30d8\u30c3\u30c0\u30fc<\/p>\n<p>&nbsp;<\/p>\n<h3>3.4.3. C++\u306e\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3057\u305f\u3044<\/h3>\n<p>C\u3067\u306f\u306a\u304f\u3066\u3001C++\u306e\u30b3\u30fc\u30c9\u306b\u3057\u305f\u3044\u5834\u5408\u3082\u591a\u3044\u304b\u3068\u601d\u3044\u307e\u3059\u3002\u305d\u306e\u5834\u5408\u306f\u3001\u300cC\u30b3\u30fc\u30c9\u300d\u30bf\u30d6\u306e\u300c\u7d44\u307f\u8fbc\u307f\u30b3\u30fc\u30c9 &#8211; C\u300d\u306e\u30d7\u30eb\u30c0\u30a6\u30f3\u30e1\u30cb\u30e5\u30fc\u304b\u3089\u300c\u7d44\u307f\u8fbc\u307f\u30b3\u30fc\u30c9 &#8211; C++\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001C++\u306e\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3059\u308b\u8a2d\u5b9a\u306b\u5909\u308f\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"847\" height=\"739\" class=\"aligncenter size-full wp-image-11294\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_embedded_cpp_setting.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u7d44\u307f\u8fbc\u307f\u30b3\u30fc\u30c9 &#8211; C++\u8a2d\u5b9a<\/p>\n<p>&nbsp;<\/p>\n<p>C++\u8a2d\u5b9a\u306b\u3059\u308b\u3068\u826f\u3044\u3053\u3068\u304c\u3042\u308a\u307e\u3059\u3002\u30e2\u30c7\u30eb\u30d5\u30a1\u30a4\u30eb\u3092\u4e00\u3064\u306e\u30af\u30e9\u30b9\u3068\u3057\u3066\u30b3\u30fc\u30c9\u751f\u6210\u3067\u304d\u308b\u306e\u3067\u3001\u3088\u308a\u660e\u78ba\u306a\u30ab\u30d7\u30bb\u30eb\u5316\u304c\u306a\u3055\u308c\u307e\u3059\u3002\u300c\u30b3\u30fc\u30c9\u30de\u30c3\u30d4\u30f3\u30b0\u300d\u304b\u3089\u3001Inports, Outports\u306e\u30c7\u30fc\u30bf\u306e\u53ef\u8996\u6027\u3092private\u306b\u8a2d\u5b9a\u3057\u3001\u30e1\u30f3\u30d0\u30fc\u30a2\u30af\u30bb\u30b9\u30e1\u30bd\u30c3\u30c9\u3092Method\u306b\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u3092\u304a\u52e7\u3081\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1549\" height=\"868\" class=\"aligncenter size-full wp-image-11297\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_cpp_member_access_method.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">C++\u30e1\u30f3\u30d0\u30fc\u30a2\u30af\u30bb\u30b9\u30e1\u30bd\u30c3\u30c9\u3092Method\u306b<\/p>\n<p>&nbsp;<\/p>\n<h3>3.4.4. \u4f59\u8a08\u306a\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u3092\u6e1b\u3089\u3057\u305f\u3044<\/h3>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306f\u3001\u30e2\u30c7\u30eb\u30d5\u30a1\u30a4\u30eb\u3054\u3068\u306b\u300c\u30e2\u30c7\u30eb\u540d.c\u300d\u300c\u30e2\u30c7\u30eb\u540d.h\u300d\u300c\u30e2\u30c7\u30eb\u540d_private.h\u300d\u300c\u30e2\u30c7\u30eb\u540d_types.h\u300d\u306e\u56db\u3064\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002\u30e2\u30c7\u30eb\u304c\u8907\u96d1\u306b\u306a\u3063\u3066\u304f\u308b\u3068\u3001\u305d\u308c\u4ee5\u5916\u306b\u3082\u3044\u308d\u3044\u308d\u5171\u901a\u306e\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u304c\u5897\u3048\u3066\u304f\u308b\u306e\u3067\u3001\u3084\u3084\u3053\u3057\u3044\u306e\u3067\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u3092\u6e1b\u3089\u3057\u305f\u3044\u3001\u3068\u601d\u3046\u6642\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u5834\u5408\u306f\u3001\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u300c\u30b3\u30fc\u30c9\u914d\u7f6e\u300d\u306e\u30d5\u30a1\u30a4\u30eb\u30d1\u30c3\u30b1\u30fc\u30b8\u5316\u5f62\u5f0f\u3092\u300c\u30b3\u30f3\u30d1\u30af\u30c8\u300d\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u30e2\u30c7\u30eb\u30d5\u30a1\u30a4\u30eb\u3054\u3068\u306e\u751f\u6210\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u306f\u300c\u30e2\u30c7\u30eb\u540d.h\u300d\u306e\u307f\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1243\" height=\"1001\" class=\"aligncenter size-full wp-image-11300\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_config_compact.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u30b3\u30f3\u30d1\u30af\u30c8\u8a2d\u5b9a<\/p>\n<p>&nbsp;<\/p>\n<h3>3.4.5. \u300crtwtypes.h\u300d\u3092\u4f7f\u3044\u305f\u304f\u306a\u3044<\/h3>\n<p>Simulink\u306e\u30b3\u30fc\u30c9\u751f\u6210\u3067\u306f\u3001\u3069\u308c\u3060\u3051\u30b7\u30f3\u30d7\u30eb\u306a\u30e2\u30c7\u30eb\u3067\u3042\u3063\u3066\u3082\u300crtwtypes.h\u300d\u304c\u5fc5\u305a\u751f\u6210\u3055\u308c\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u3067\u306f\u4e3b\u306b\u3001double \u3084 int32 \u306a\u3069\u306e\u57fa\u672c\u306e\u30c7\u30fc\u30bf\u578b\u3092\u3001real_T \u3084 int32_T \u306a\u3069\u306e\u3001MATLAB \u56fa\u6709\u306e\u30c7\u30fc\u30bf\u578b\u306b\u5b9a\u7fa9\u3057\u76f4\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u524d\u304b\u3089\u3001\u304a\u5ba2\u69d8\u304b\u3089\u300crtwtypes.h\u300d\u3092\u7121\u304f\u3057\u3066\u307b\u3057\u3044\u3001\u3068\u3044\u3046\u3054\u8981\u671b\u3092\u9802\u3044\u3066\u304a\u308a\u307e\u3057\u305f\u3002R2023a \u306b\u3066\u3001\u3064\u3044\u306b\u3053\u306e\u30d8\u30c3\u30c0\u30fc\u30d5\u30a1\u30a4\u30eb\u3092\u7121\u304f\u3059\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f\u3002\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u300c\u30b3\u30fc\u30c9\u751f\u6210\u300d\u300c\u30c7\u30fc\u30bf\u578b\u7f6e\u63db\u300d\u306e\u30c7\u30fc\u30bf\u578b\u306e\u7f6e\u63db\u3067\u300c\u56fa\u5b9a\u5e45\u306e\u6574\u6570\u306eC\u30c7\u30fc\u30bf\u578b\u3092\u4f7f\u7528\u300d\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1244\" height=\"1010\" class=\"aligncenter size-full wp-image-11303\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_config_fixed.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30f3\u30d5\u30a3\u30ae\u30e5\u30ec\u30fc\u30b7\u30e7\u30f3\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\uff1a\u56fa\u5b9a\u5e45\u306e\u6574\u6570\u306eC\u30c7\u30fc\u30bf\u578b\u3092\u4f7f\u7528<\/p>\n<p>&nbsp;<\/p>\n<h3>3.4.6. \u5404\u30d5\u30a9\u30eb\u30c0\u306b\u6563\u3089\u3070\u3063\u3066\u3044\u308b\u30b3\u30fc\u30c9\u3092\u4e00\u3064\u306e\u30d5\u30a9\u30eb\u30c0\u306b\u307e\u3068\u3081\u305f\u3044<\/h3>\n<p>\u8907\u6570\u306e\u30e2\u30c7\u30eb\u3092\u53c2\u7167\u3057\u3066\u3044\u308b\u30e2\u30c7\u30eb\u304b\u3089\u30b3\u30fc\u30c9\u751f\u6210\u3059\u308b\u3068\u3001\u751f\u6210\u3055\u308c\u305fC\/C++\u30d5\u30a1\u30a4\u30eb\u304c\u3044\u308d\u3093\u306a\u30d5\u30a9\u30eb\u30c0\u306b\u6563\u3089\u3070\u308a\u307e\u3059\u3002\u30ab\u30c6\u30b4\u30ea\u30fc\u3054\u3068\u306b\u5206\u3051\u3089\u308c\u3066\u3044\u308b\u3001\u3068\u3044\u3046\u826f\u3044\u9762\u3082\u3042\u308a\u307e\u3059\u304c\u3001\u305d\u306e\u5f8c\u306b\u5916\u90e8\u306e\u958b\u767a\u74b0\u5883\u3078\u6301\u3063\u3066\u3044\u304f\u3053\u3068\u3092\u8003\u3048\u308b\u3068\u3001\u5fc5\u8981\u306a\u30b3\u30fc\u30c9\u3060\u3051\u3001\u4e00\u3064\u306e\u30d5\u30a9\u30eb\u30c0\u306b\u307e\u3068\u307e\u3063\u3066\u3044\u308b\u65b9\u304c\u826f\u3044\u3067\u3059\u3002<\/p>\n<p>\u3053\u306e\u5834\u5408\u306f\u300cpackNGo\u300d\u3068\u3044\u3046\u30b3\u30de\u30f3\u30c9\u3067\u3001\u5fc5\u8981\u306a\u30b3\u30fc\u30c9\u3060\u3051\u3001\u4e00\u3064\u306e\u30d5\u30a9\u30eb\u30c0\u306b\u307e\u3068\u3081\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u307e\u305a\u3001buildInfo.mat\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u3092load\u30b3\u30de\u30f3\u30c9\u3067\u8aad\u307f\u8fbc\u307f\u307e\u3059\u3002buildInfo.mat\u306f\u3001\u300c\u30e2\u30c7\u30eb\u540d_ert_rtw\u300d\u3068\u3044\u3046\u30d5\u30a9\u30eb\u30c0\u306b\u5165\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1678\" height=\"649\" class=\"aligncenter size-full wp-image-11306\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_load_build_info.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">buildInfo\u3092\u8aad\u307f\u8fbc\u307f<\/p>\n<p>&nbsp;<\/p>\n<p>\u6b21\u306b\u3001\u300cpackNGo(buildInfo)\u300d\u3092\u5b9f\u884c\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u5fc5\u8981\u306a\u30b3\u30fc\u30c9\u304czip\u30d5\u30a1\u30a4\u30eb\u306b\u307e\u3068\u3081\u3089\u308c\u307e\u3059\u3002\u305d\u308c\u3067\u3082\u3001\u307e\u3060\u4e00\u90e8\u30b3\u30fc\u30c9\u3068\u95a2\u4fc2\u306a\u3044\u30d5\u30a1\u30a4\u30eb\u304czip\u306e\u4e2d\u306b\u5165\u3063\u3066\u3044\u307e\u3059\u304c\u3001\u304a\u624b\u6570\u3067\u3059\u304c\u3001\u5225\u9014\u9664\u53bb\u3057\u3066\u3044\u305f\u3060\u304f\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1336\" height=\"763\" class=\"aligncenter size-full wp-image-11309\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_packngo.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">packNGo\u3092\u5b9f\u884c<\/p>\n<p>&nbsp;<\/p>\n<\/details>\n<p>&nbsp;<\/p>\n<h1 id=\"deploy_and_experiment\">4. \u5b9f\u88c5\u3068\u5b9f\u6a5f\u8a66\u9a13<\/h1>\n<p>\u30b3\u30fc\u30c9\u751f\u6210\u304c\u5b8c\u4e86\u3057\u307e\u3057\u305f\u306e\u3067\u3001\u6700\u5f8c\u306b\u30de\u30a4\u30b3\u30f3\u306e\u958b\u767a\u74b0\u5883\u306b\u7d71\u5408\u3059\u308b\u6d41\u308c\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n<h2 id=\"integrate_to_arduino\">4.1. Arduino \u958b\u767a\u74b0\u5883\u3078\u7d71\u5408<\/h2>\n<p>\u751f\u6210\u3055\u308c\u305f\u30b3\u30fc\u30c9\u3092 Arduino \u958b\u767a\u74b0\u5883\u5074\u3078\u6301\u3063\u3066\u3044\u304d\u307e\u3059\u3002PlatformIO\u3067\u306f\u3001platformio.ini\u3067\u300cbuild_flags\u300d\u3068\u3044\u3046\u30aa\u30d7\u30b7\u30e7\u30f3\u3067\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u30d5\u30a9\u30eb\u30c0\u306e\u30d1\u30b9\u3092\u6307\u5b9a\u3067\u304d\u307e\u3059\u3002\u305d\u306e\u30d1\u30b9\u306e\u5185\u306b\u751f\u6210\u30b3\u30fc\u30c9\u3092\u6301\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1489\" height=\"1036\" class=\"aligncenter size-full wp-image-11312\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_copy_to_platformio.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30b3\u30fc\u30c9\u3092Arduino \u958b\u767a\u74b0\u5883\u5074\u3078\u30b3\u30d4\u30fc<\/p>\n<p>&nbsp;<\/p>\n<p>\u30bf\u30a4\u30de\u30fc\u5272\u308a\u8fbc\u307f\u95a2\u6570\u306e\u4e2d\u3067\u3001\u751f\u6210\u3057\u305f\u30b3\u30fc\u30c9\u3092\u547c\u3073\u51fa\u3059\u30b3\u30de\u30f3\u30c9\u3092\u8a18\u8ff0\u3057\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1480\" height=\"1041\" class=\"aligncenter size-full wp-image-11315\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_write_in_timer_interrupt.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u30bf\u30a4\u30de\u30fc\u5272\u308a\u8fbc\u307f\u95a2\u6570\u306b\u751f\u6210\u30b3\u30fc\u30c9\u306e\u95a2\u6570\u3092\u8a18\u8ff0<\/p>\n<p>&nbsp;<\/p>\n<p>\u307e\u305f\u3001\u521d\u671f\u5316\u3092\u884c\u3046\u30b3\u30de\u30f3\u30c9\u3082\u5fd8\u308c\u305a\u306b\u8a18\u8ff0\u3057\u307e\u3059\u3002\u521d\u671f\u5316\u306e\u30b3\u30de\u30f3\u30c9\uff08initialize()\u95a2\u6570\uff09\u306f\u3001\u6700\u521d\u306b1\u5ea6\u3060\u3051\u5b9f\u884c\u3059\u308c\u3070\u3088\u3044\u3067\u3059\u3002<\/p>\n<p>Arduino\u3067\u306f\u3001setup()\u3068\u3044\u3046\u95a2\u6570\u3067\u6700\u521d\u306b1\u5ea6\u3060\u3051\u5b9f\u884c\u3059\u308b\u51e6\u7406\u3092\u66f8\u3051\u307e\u3059\u306e\u3067\u3001\u305d\u306e\u95a2\u6570\u306e\u4e2d\u306b\u8a18\u8ff0\u3059\u308c\u3070\u3088\u3044\u3067\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1128\" height=\"619\" class=\"aligncenter size-full wp-image-11465\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/04\/EC_setup_initialize.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">\u521d\u671f\u5316\u30b3\u30de\u30f3\u30c9\u3092\u8a18\u8ff0<\/p>\n<p>&nbsp;<\/p>\n<p>Build\u3092\u30af\u30ea\u30c3\u30af\u3057\u3001\u6b63\u5e38\u306b\u30d3\u30eb\u30c9\u304c\u3067\u304d\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u307e\u3059\u3002\u554f\u984c\u306a\u3051\u308c\u3070\u3001Arduino Due\u3092PC\u306b\u63a5\u7d9a\u3057\u3001Upload\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u5b9f\u884c\u30d5\u30a1\u30a4\u30eb\u304cArduino Due\u306b\u66f8\u304d\u8fbc\u307e\u308c\u307e\u3059\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"1035\" height=\"1036\" class=\"aligncenter size-full wp-image-11318\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_build_and_upload.png\" alt=\"\" \/><\/p>\n<p style=\"text-align: center;\">Build\u3068Upload<\/p>\n<p>&nbsp;<\/p>\n<h2 id=\"experiment\">4.2. \u5b9f\u6a5f\u8a66\u9a13<\/h2>\n<p>\u6700\u5f8c\u306b\u3001Arduino Due \u3068 Quanser \u3092\u63a5\u7d9a\u3057\u3001\u5b9f\u884c\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<p><div style=\"width: 1280px;\" class=\"wp-video\"><!--[if lt IE 9]><script>document.createElement('video');<\/script><![endif]-->\n<video class=\"wp-video-shortcode\" id=\"video-10999-1\" width=\"1280\" height=\"720\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_experiment_quanser.mp4?_=1\" \/><a href=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_experiment_quanser.mp4\">https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_experiment_quanser.mp4<\/a><\/video><\/div><\/p>\n<p style=\"text-align: center;\">Arduino Due \u3067\u5236\u5fa1\u3057\u305f\u52d5\u753b<\/p>\n<p>&nbsp;<\/p>\n<p>\u904e\u53bb\u306b\u884c\u3063\u305f Raspberry Pi \u306e\u5236\u5fa1\u3068\u540c\u3058\u52d5\u304d\u304c\u5b9f\u73fe\u3067\u304d\u307e\u3057\u305f\uff01<\/p>\n<h1 id=\"conclusion\">5. \u307e\u3068\u3081<\/h1>\n<p>\u672c\u8a18\u4e8b\u3067\u306f\u3001Embedded Coder \u3092\u4f7f\u3063\u3066 Simulink \u30e2\u30c7\u30eb\u304b\u3089C\/C++\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3057\u3001\u5916\u90e8\u306e\u958b\u767a\u74b0\u5883\u306b\u7d71\u5408\u3059\u308b\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3092\u7d39\u4ecb\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>Embedded Coder \u306eTips\u3082\u305f\u304f\u3055\u3093\u7d39\u4ecb\u3057\u307e\u3057\u305f\u304c\u3001\u5b9f\u306f\u307e\u3060\u307e\u3060\u4ed6\u306b\u3082\u6a5f\u80fd\u304c\u305f\u304f\u3055\u3093\u3042\u308a\u307e\u3057\u3066\u3001\u91cf\u7523\u958b\u767a\u306e\u73fe\u5834\u3067\u306f\u3001\u305d\u308c\u3089\u3092\u99c6\u4f7f\u3057\u3066\u6700\u9069\u306aC\/C++\u30b3\u30fc\u30c9\u3092\u751f\u6210\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p><span class=\"ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak\" dir=\"ltr\">Embedded Coder\u3092\u672c\u683c\u7684\u306b\u4f7f\u3044\u305f\u3044\u5834\u5408\u306f\u3001<a class=\"fui-Link ___1rxvrpe f2hkw1w f3rmtva f1ewtqcl fyind8e f1k6fduh f1w7gpdv fk6fouc fjoy568 figsok6 f1hu3pq6 f11qmguv f19f4twv f1tyq0we f1g0x7ka fhxju0i f1qch9an f1cnd47f fqv5qza f1vmzxwi f1o700av f13mvf36 f1cmlufx f9n3di6 f1ids18y f1tx3yz7 f1deo86v f1eh06m1 f1iescvh fhgqx19 f1olyrje f1p93eir f1nev41a f1h8hb77 f1lqvz6u f10aw75t fsle3fq f17ae5zn\" title=\"https:\/\/jp.mathworks.com\/learn\/training\/embedded-coder-for-production-code-generation.html\" href=\"https:\/\/jp.mathworks.com\/learn\/training\/embedded-coder-for-production-code-generation.html\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\"\u30ea\u30f3\u30af \u3053\u3061\u3089\">\u3053\u3061\u3089<\/a>\u306e\u30c8\u30ec\u30fc\u30cb\u30f3\u30b0\u30b3\u30fc\u30b9\u3082\u304a\u3059\u3059\u3081\u3067\u3059\u3002\u91cf\u7523\u958b\u767a\u3067\u5fc5\u8981\u306a\u30ce\u30a6\u30cf\u30a6\u3092\u5b66\u3079\u307e\u3059\u3002<\/span><\/p>\n<p>\u7686\u69d8\u306e\u53c2\u8003\u306b\u306a\u308a\u307e\u3057\u305f\u3089\u5e78\u3044\u3067\u3059\u3002<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"overview-image\"><img decoding=\"async\"  class=\"img-responsive\" src=\"https:\/\/blogs.mathworks.com\/japan-community\/files\/2024\/03\/EC_V_process.png\" onError=\"this.style.display ='none';\" \/><\/div>\n<p>\u672c\u65e5\u306f\u3001X (Twitter) \u3067\u3082\u304a\u306a\u3058\u307f\u3001Simulink\u306e\u4e2d\u306e\u4eba\u304b\u3089\u306e\u6295\u7a3f\u3067\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001Embedded Coder \u306e\u6d3b\u7528\u65b9\u6cd5\u306b\u3064\u3044\u3066\u89e3\u8aac\u3057\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<br \/>\n\u521d\u5fc3\u8005\u306b\u306f\u3068\u3063\u3064\u304d\u306b\u304f\u3044\u30c4\u30fc\u30eb\u3067\u306f\u3042\u308a\u307e\u3059\u304c\u3001\u30e2\u30c7\u30eb\u30d9\u30fc\u30b9\u30c7\u30b6\u30a4\u30f3\u306e\u4e2d\u6838\u3092\u306a\u3059\u91cd\u8981\u306a\u30c4\u30fc\u30eb\u3067\u3059\u3002\u4f7f\u3044\u3053\u306a\u305b\u308b\u3068\u3001\u958b\u767a\u5de5\u6570\u3092\u5927\u5e45\u306b\u524a\u6e1b\u3067\u304d\u307e\u3059\u306e\u3067\u3001\u662f\u975e\u4f7f\u3044\u3053\u306a\u305b\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u3087\u3046\uff01<br \/>\nNote: \u672c\u8a18\u4e8b\u306e MATLAB,&#8230; <a class=\"read-more\" href=\"https:\/\/blogs.mathworks.com\/japan-community\/2024\/04\/17\/embedded-coder-for-beginner\/\">read more >><\/a><\/p>\n","protected":false},"author":159,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[61],"tags":[160,151,69,163,154,157],"_links":{"self":[{"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/posts\/10999"}],"collection":[{"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/users\/159"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/comments?post=10999"}],"version-history":[{"count":71,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/posts\/10999\/revisions"}],"predecessor-version":[{"id":11541,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/posts\/10999\/revisions\/11541"}],"wp:attachment":[{"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/media?parent=10999"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/categories?post=10999"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/japan-community\/wp-json\/wp\/v2\/tags?post=10999"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}