PageSourceSearch

https://cubic9.com/assets/js/9e7c5333.chunk.js

js cubic9.com collected 2026-10-04 11:11:11 UTC 22,509 bytes, 2 lines download raw bytes

1/*! For license information please see 9e7c5333.chunk.js.LICENSE.txt */
2"use strict";(self.webpackChunkcubic_9_com=self.webpackChunkcubic_9_com||[]).push([[5549],{28453:(e,n,i)=>{i.d(n,{R:()=>c,x:()=>s});var r=i(96540);const l={},t=r.createContext(l);function c(e){const n=r.useContext(t);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function s(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:c(e.components),r.createElement(t.Provider,{value:n},e.children)}},48214:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>s,metadata:()=>r,toc:()=>o});const r=JSON.parse('{"id":"Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5/MPU-9150","title":"MPU-9150","description":"\u4eca\u56de\u306f\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5\u3092Arduino\u306b\u63a5\u7d9a\u3057\u3001Aruino\u3068Unity\u3092\u9023\u643a\u3055\u305b\u3066\u3001Unity\u7a7a\u9593\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u56de\u8ee2\u3092\u5236\u5fa1\u3057\u3066\u307f\u307e\u3059\u3002","source":"@site/docs/Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5/MPU-9150.md","sourceDirName":"Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5","slug":"/Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5/MPU-9150","permalink":"/Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5/MPU-9150","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{},"sidebar":"tutorialSidebar","previous":{"title":"BNO055","permalink":"/Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5/BNO055"},"next":{"title":"\u5965\u6b6f\u3092\u565b\u3093\u3067\u3044\u308b\u9593\u3060\u3051Vine\u3092\u64ae\u5f71\u3059\u308b\u88c5\u7f6e","permalink":"/Devel/\u96fb\u5b50\u5de5\u4f5c/Arduino/\u5965\u6b6f\u3092\u565b\u3093\u3067\u3044\u308b\u9593\u3060\u3051Vine\u3092\u64ae\u5f71\u3059\u308b\u88c5\u7f6e"}}');var l=i(74848),t=i(28453),c=i(77833);const s={},a=void 0,d={},o=[{value:"\u5fc5\u8981\u306a\u3082\u306e",id:"\u5fc5\u8981\u306a\u3082\u306e",level:2},{value:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2",id:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2",level:3},{value:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2",id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2",level:3},{value:"\u624b\u9806",id:"\u624b\u9806",level:2},{value:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306e\u6e96\u5099",id:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306e\u6e96\u5099",level:3},{value:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u5099(1)\uff1aArduino\u30b9\u30b1\u30c3\u30c1",id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u50991arduino\u30b9\u30b1\u30c3\u30c1",level:3},{value:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u5099(2)\uff1aUnity\u7528C#\u30b9\u30af\u30ea\u30d7\u30c8",id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u50992unity\u7528c\u30b9\u30af\u30ea\u30d7\u30c8",level:3},{value:"\u52d5\u4f5c\u78ba\u8a8d",id:"\u52d5\u4f5c\u78ba\u8a8d",level:3},{value:"\u8a2d\u5b9a\u306b\u3064\u3044\u3066",id:"\u8a2d\u5b9a\u306b\u3064\u3044\u3066",level:2},{value:"Unity\u7528C#\u30b9\u30af\u30ea\u30d7\u30c8",id:"unity\u7528c\u30b9\u30af\u30ea\u30d7\u30c8",level:2},{value:"\u53c2\u8003",id:"\u53c2\u8003",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",pre:"pre",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,t.R)(),...e.components};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n.p,{children:"\u4eca\u56de\u306f\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5\u3092Arduino\u306b\u63a5\u7d9a\u3057\u3001Aruino\u3068Unity\u3092\u9023\u643a\u3055\u305b\u3066\u3001Unity\u7a7a\u9593\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u56de\u8ee2\u3092\u5236\u5fa1\u3057\u3066\u307f\u307e\u3059\u3002"}),"\n",(0,l.jsxs)(n.p,{children:["\u8981\u3059\u308b\u306b",(0,l.jsx)(n.a,{href:"../PaxPowerGlove",children:"PAX\u30d1\u30ef\u30fc\u30b0\u30ed\u30fc\u30d6"}),"\u306e\u30da\u30fc\u30b8\u3067\u3084\u3063\u3066\u3044\u308b\u30d1\u30ef\u30fc\u30b0\u30ed\u30fc\u30d6\u8fd1\u4ee3\u5316\u4f5c\u696d\u306e\u8981\u7d20\u6280\u8853\u78ba\u8a8d\u3067\u3059\u3002"]}),"\n","\n",(0,l.jsx)("div",{className:"video-container",children:(0,l.jsx)(c.A,{id:"cVN7V2YPKlI",webp:!0})}),"\n",(0,l.jsxs)(n.p,{children:["\u672c\u30da\u30fc\u30b8\u3067\u89e3\u8aac\u3057\u3066\u3044\u308b\u306e\u306fInvenSense\u793e\u306eMPU-9150\u306b\u3064\u3044\u3066\u3067\u3059\u304c\u3001",(0,l.jsx)(n.a,{href:"./BNO055",children:"Bosch\u793e\u306eBNO055\u7248\u306e\u8a18\u4e8b\u3082\u3042\u308a\u307e\u3059\u3002"})]}),"\n",(0,l.jsx)(n.h2,{id:"\u5fc5\u8981\u306a\u3082\u306e",children:"\u5fc5\u8981\u306a\u3082\u306e"}),"\n",(0,l.jsx)(n.h3,{id:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2",children:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"\u9805\u76ee"}),(0,l.jsx)(n.th,{children:"\u8aac\u660e"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.a,{href:"http://www.amazon.co.jp/exec/obidos/ASIN/B0044X2E5S/cubic9com-22",children:"Arduino Uno"})}),(0,l.jsx)(n.td,{children:"\u6bd4\u8f03\u7684\u5c0f\u578b\u3067\u5b89\u4fa1\u3067\u7c21\u5358\u306b\u4f7f\u3048\u308b\u30de\u30a4\u30b3\u30f3\u30dc\u30fc\u30c9\u3002"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.a,{href:"http://strawberry-linux.com/catalog/items?code=12150",children:"MPU-9150 9\u8ef8\u30bb\u30f3\u30b5\u30e2\u30b8\u30e5\u30fc\u30eb"})}),(0,l.jsx)(n.td,{children:"InvenSense\u793e\u306e3\u8ef8\u52a0\u901f\u5ea6+3\u8ef8\u30b8\u30e3\u30a4\u30ed+3\u8ef8\u30b3\u30f3\u30d1\u30b9\u306e\u30e2\u30fc\u30b7\u30e7\u30f3\u30bb\u30f3\u30b5\u30c1\u30c3\u30d7MPU-9150\u304c\u8f09\u3063\u305f\u30e2\u30b8\u30e5\u30fc\u30eb\u3002&br;MPU-9150\u306f\u3001InvenSense\u306e\u52a0\u901f\u5ea6\u30fb\u30b8\u30e3\u30a4\u30ed\u30c1\u30c3\u30d7MPU-6050\u3068\u65ed\u5316\u6210\u306e\u30b3\u30f3\u30d1\u30b9\u30c1\u30c3\u30d7\u3092AK8975\u30921\u30d1\u30c3\u30b1\u30fc\u30b8\u306b\u3057\u305f\u3082\u306e\u3067\u3059\u3002&br;MPU-9150\u3082\u3057\u304f\u306fMPU-6050\u304c\u642d\u8f09\u3055\u308c\u3066\u3044\u308b\u30e2\u30b8\u30e5\u30fc\u30eb\u306a\u3089\u3070\u6982\u306d\u54
20c\u69d8\u3060\u3068\u601d\u3044\u307e\u3059\u3002&br;\u3053\u308c\u3089\u306e\u30c1\u30c3\u30d7\u306b\u306fDMP\uff08Digital Motion Processor\uff09\u3068\u3044\u3046\u6a5f\u80fd\u304c\u3042\u308a\u3001\u30bb\u30f3\u30b5\u306e\u751f\u30c7\u30fc\u30bf\u3067\u306f\u306a\u304f\u3001\u30bb\u30f3\u30b5\u306e\u5024\u304b\u3089\u30af\u30a9\u30fc\u30bf\u30cb\u30aa\u30f3\u3092\u7b97\u51fa\u3057\u3066\u304f\u308c\u308b\u306e\u3067\u4fbf\u5229\u3067\u3059\u3002"})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2",children:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"\u9805\u76ee"}),(0,l.jsx)(n.th,{children:"\u8aac\u660e"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:"Arduino IDE"}),(0,l.jsxs)(n.td,{children:["Arduino\u7528\u306e\u958b\u767a\u74b0\u5883\u3002",(0,l.jsx)(n.a,{href:"http://arduino.cc/",children:"\u30aa\u30d5\u30a3\u30b7\u30e3\u30eb\u30b5\u30a4\u30c8"}),"\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u304f\u3060\u3055\u3044\u3002"]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.a,{href:"http://japan.unity3d.com/",children:"Unity"})}),(0,l.jsxs)(n.td,{children:["\u30de\u30eb\u30c1\u30d7\u30e9\u30c3\u30c8\u30d5\u30a9\u30fc\u30e0\u5bfe\u5fdc\u306e\u30b2\u30fc\u30e0\u30a8\u30f3\u30b8\u30f3\u3002\u7c21\u5358\u306b3D\uff08or 2D\uff09\u30b2\u30fc\u30e0\u3092\u4f5c\u308b\u3053\u3068\u304c\u51fa\u6765\u308b\u3002",(0,l.jsx)(n.a,{href:"http://japan.unity3d.com/",children:"\u30aa\u30d5\u30a3\u30b7\u30e3\u30eb\u30b5\u30a4\u30c8"}),"\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u304f\u3060\u3055\u3044\u3002"]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:"I2C Device Library"}),(0,l.jsxs)(n.td,{children:["I2C\u30c7\u30d0\u30a4\u30b9\u7528C++\u30e9\u30a4\u30d6\u30e9\u30ea\u3068MPU-6050\u3068MPU-9150\u306eArduino\u30b5\u30f3\u30d7\u30eb\u30b9\u30b1\u30c3\u30c1\u3002 ",(0,l.jsx)(n.a,{href:"https://github.com/jrowberg/i2cdevlib",children:"https://github.com/jrowberg/i2cdevlib"})," \u3092\u958b\u304d\u3001\u53f3\u5074\u306e\u300cDownload ZIP\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u304f\u3060\u3055\u3044\u3002"]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:"Unity\u7528C#\u30b9\u30af\u30ea\u30d7\u30c8"}),(0,l.jsx)(n.td,{children:"\u4e0a\u8a18\u30b5\u30f3\u30d7\u30eb\u30b9\u30b1\u30c3\u30c1\u306e\u51fa\u529b\u3092Unity\u5074\u3067\u53d7\u3051\u53d6\u3063\u3066GameObject\u3092\u5236\u5fa1\u3059\u308bC#\u30b9\u30af\u30ea\u30d7\u30c8\u3002\u672c\u30da\u30fc\u30b8\u4e0b\u90e8\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u304f\u3060\u3055\u3044\u3002"})]})]})]}),"\n",(0,l.jsx)(n.h2,{id:"\u624b\u9806",children:"\u624b\u9806"}),"\n",(0,l.jsx)(n.h3,{id:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306e\u6e96\u5099",children:"\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u306e\u6e96\u5099"}),"\n",(0,l.jsxs)(n.ol,{children:["\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306eSCL\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f3\u756a\u30d4\u30f3\uff09\u3092Arduino\u306eSCL\uff08Arduino Uno\u3067\u306fA5\u30d4\u30f3\uff09\u306b\u63a5\u7d9a\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306eSDA\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f4\u756a\u30d4\u30f3\uff09\u3092Arduino\u306eSDA\uff08Arduino Uno\u3067\u306fA4\u30d4\u30f3\uff09\u306b\u63a5\u7d9a\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306eINT\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f8\u756a\u30d4\u30f3\uff09\u3092Arduino\u306einterrupt\uff08Arduino Uno\u3067\u306fD2\u30d4\u30f3\uff09\u306b\u63a5\u7d9a\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306eGND\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f10\u756a\u30d4\u30f3\uff09\u3068AD0\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f9\u756a\u30d4\u30f3\uff09\u3092Arduino\u306eGND\u30d4\u30f3\u306b\u63a5\u7d9a\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306eVDD\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f1\u756a\u30d4\u30f3\uff09\u3068VLOGIC\uff08\u4eca\u56de\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3067\u306f2\u756a\u30d4\u30f3\uff09\u3092Arduino\u306e3.3V\u30d4\u30f3\u306b\u63a5\u7d9a\u3059\u308b\u3002"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u50991arduino\u30b9\u30b1\u30c3\u30c1",children:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u5099(1)\uff1aArduino\u30b9\u30b1\u30c3\u30c1"}),"\n",(0,l.jsxs)(n.ol,{children:["\n",(0,l.jsx)(n.li,{children:"i2cdevlib-master.zip\u3092\u89e3\u51cd\u3059\u308b\u3002"}),"\n",(0,l.jsxs)(n.li,{children:["\u4e0b\u8a182\u3064\u306e\u30d5\u30a9\u30eb\u30c0\u3092Arduino\u7528\u30d5\u30a9\u30eb\u30c0\u306elibraries\u306b\u30b3\u30d4\u30fc\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{children:"-i2cdevlib-master/Arduino/I2Cdev\r\n-i2cdevlib-master/Arduino/MPU6050\r\n-&color(#F00){i2cdevlib-master/Arduino/MPU9150};\n"})}),"\n"]}),"\n",(0,l.jsx)(n.li,{children:"MPU9150/MPU9150_9Axis_MotionApps41.h\u3092\u30a8\u30c7\u30a3\u30bf\u3067\u958b\u304f\u3002"}),"\n",(0,l.jsx)(n.li,{children:'61\u884c\u76ee\u306e"typedef unsigned char unsigned char;"\u3092\u30b3\u30e1\u30f3\u30c8\u30a2\u30a6\u30c8\u3059\u308b\u3002'}),"\n",(0,l.jsx)(n.li,{children:'\u30d5\u30a1\u30a4\u30eb\u5185\u306e"prog_uchar"\u3092"unsigned char"\u306b\u7f6e\u63db\u3059\u308b\u3002'}),"\n",(0,l.jsx)(n.li,{children:"Arduino IDE\u3092\u8d77\u52d5\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u30e1\u30cb\u30e5\u30fc\u306e[\u30d5\u30a1\u30a4\u30eb]>[\u30b9\u30b1\u30c3\u30c1\u306e\u4f8b]>[MPU6050]>[Example]>[MPU6050_DMP6]\u3092\u9078\u629e\u3059\u308b\u3002"}),"\n",(0,l.jsxs)(n.li,{children:["87\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002~\r\n(unidiff\u98a8\u306b\u66f8\u3044\u3066\u3044\u307e\u3059\u3002\u8981\u3059\u308b\u306b\u5148\u982d\u304c-\u306e\u884c\u3092\u524a\u9664\u3057\u3066\u3001\u5148\u982d\u304c+\u306e\u884c\u3092\u8ffd\u52a0\u3059\u308b\u3060\u3051\u3067\u3059\u3002)","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:'-#include "MPU6050_6Axis_MotionApps20.h"\r\n+#include "MPU9150_9Axis_MotionApps41.h"\n'})}),"\n"]}),"\n",(0,l.jsxs)(n.li,{children:["61\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:"    -MPU6050 mpu;\r\n    +MPU9150 mpu;\n"})}),"\n"]}),"\n",(0,l.jsxs)(n.li,{children:["87\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:"-//#define OUTPUT_READABLE_QUATERNION\r\n+#define OUTPUT_READABLE_QUATERNION\n"})}),"\n"]}),"\n",(0,l.jsxs)(n.li,{children:["100\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:"-#define OUTPUT_READABLE_YAWPITCHROLL\r\n+//#define OUTPUT_READABLE_YAWPITCHROLL\n"})}),"\n"]}),"\n",(0,l.jsxs)(n.li,{children:["192-194\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:"-    while (Serial.available() && Seri
2al.read()); // empty buffer\r\n-    while (!Serial.available());                 // wait for data\r\n-    while (Serial.available() && Serial.read()); // empty buffer again\r\n+//    while (Serial.available() && Serial.read()); // empty buffer\r\n+//    while (!Serial.available());                 // wait for data\r\n+//    while (Serial.available() && Serial.read()); // empty buffer again\n"})}),"\n"]}),"\n",(0,l.jsxs)(n.li,{children:["201-204\u884c\u76ee\u3092\u6b21\u306e\u3088\u3046\u306b\u5909\u66f4\u3059\u308b\u3002","\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-C",children:"-    mpu.setXGyroOffset(220);\r\n-    mpu.setYGyroOffset(76);\r\n-    mpu.setZGyroOffset(-85);\r\n-    mpu.setZAccelOffset(1788); // 1688 factory default for my test chip\r\n+//    mpu.setXGyroOffset(220);\r\n+//    mpu.setYGyroOffset(76);\r\n+//    mpu.setZGyroOffset(-85);\r\n+//    mpu.setZAccelOffset(1788); // 1688 factory default for my test chip\n"})}),"\n"]}),"\n",(0,l.jsx)(n.li,{children:"\u4fdd\u5b58\u3057\u3066Arduino\u306b\u66f8\u304d\u8fbc\u3080\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u30e1\u30cb\u30e5\u30fc\u306e[\u30c4\u30fc\u30eb]>[\u30b7\u30ea\u30a2\u30eb\u30e2\u30cb\u30bf]\u3092\u9078\u629e\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u53f3\u4e0b\u306e\u30dc\u30fc\u30ec\u30fc\u30c8\u9078\u629e\u30ea\u30b9\u30c8\u304b\u3089115200baud\u3092\u9078\u629e\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u300cInitializing I2C device..\u300d\u306b\u7d9a\u3044\u3066\u3001\u5148\u982d\u306b\u300cquat\u300d\u3001\u305d\u306e\u5f8c\u306b\u6570\u5024\u304c\u51fa\u529b\u3055\u308c\u305f\u3089\u3001\u6210\u529f\u3002~\r\n\u8868\u793a\u3055\u308c\u306a\u3044\u5834\u5408\u306f\u3001Arduino\u672c\u4f53\u306e\u30ea\u30bb\u30c3\u30c8\u30dc\u30bf\u30f3\u3092\u62bc\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u3053\u306e\u3068\u304d\u3001\u30a6\u30a3\u30f3\u30c9\u30a6\u306e\u30bf\u30a4\u30c8\u30eb\u306b\u300cCOM\uff5e\u300d\u3068\u8868\u793a\u3055\u308c\u3066\u3044\u308b\u306f\u305a\u306a\u306e\u3067\u3001\u756a\u53f7\u3092\u899a\u3048\u3066\u304a\u304f\u3002"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u50992unity\u7528c\u30b9\u30af\u30ea\u30d7\u30c8",children:"\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u306e\u6e96\u5099(2)\uff1aUnity\u7528C#\u30b9\u30af\u30ea\u30d7\u30c8"}),"\n",(0,l.jsxs)(n.ol,{children:["\n",(0,l.jsx)(n.li,{children:"Unity\u3092\u8d77\u52d5\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"[Edit]>[Project Settings]>[Player]\u3092\u958b\u304f\u3002"}),"\n",(0,l.jsx)(n.li,{children:'[Api Compatibility Level]\u3092".NET 2.0 Subset"\u304b\u3089".NET 2.0"\u306b\u5909\u66f4\u3059\u308b\u3002'}),"\n",(0,l.jsx)(n.li,{children:"[GameObject]>[Create Other]>[Cube]\u3092\u9078\u629e\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"Scene View\u306b\u7acb\u65b9\u4f53\u304c\u8868\u793a\u3055\u308c\u3001Hierarchy View\u306b\u300cCube\u300d\u3068\u3044\u3046GameObject\u304c\u51fa\u6765\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"Project View\u306b\u672c\u30da\u30fc\u30b8\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u305fC#\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u30c9\u30e9\u30c3\u30b0&\u30c9\u30ed\u30c3\u30d7\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"Project View\u306bC#\u30b9\u30af\u30ea\u30d7\u30c8\u304c\u8ffd\u52a0\u3055\u308c\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"C#\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u30c0\u30d6\u30eb\u30af\u30ea\u30c3\u30af\u3057\u3066\u958b\u304d\u3001\u5b9a\u6570SERIAL_PORT\u3092\u5148\u307b\u3069\u899a\u3048\u3066\u304a\u3044\u305f\u756a\u53f7\u306b\u66f8\u304d\u63db\u3048\u3001\u4fdd\u5b58\u3059\u308b\u3002"}),"\n",(0,l.jsx)(n.li,{children:"Project View\u306eC#\u30b9\u30af\u30ea\u30d7\u30c8\u3092Hierarchy View\u306e\u300cCube\u300d\u306b\u30c9\u30e9\u30c3\u30b0&\u30c9\u30ed\u30c3\u30d7\u3059\u308b\u3002"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"\u52d5\u4f5c\u78ba\u8a8d",children:"\u52d5\u4f5c\u78ba\u8a8d"}),"\n",(0,l.jsxs)(n.ol,{children:["\n",(0,l.jsx)(n.li,{children:"Unity\u306e\u518d\u751f\u30dc\u30bf\u30f3\u3092\u62bc\u3059\u3002"}),"\n",(0,l.jsx)(n.li,{children:"MPU-9150\u3092\u50be\u3051\u3066\u307f\u3066\u3001Cube\u304c\u52d5\u3051\u3070\u6210\u529f\uff01\r\n\u52d5\u304b\u306a\u3044\u5834\u5408\u306f\u3001Ardu
2ino\u672c\u4f53\u306e\u30ea\u30bb\u30c3\u30c8\u30dc\u30bf\u30f3\u3092\u62bc\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:"\u304a\u75b2\u308c\u69d8\u3067\u3057\u305f\u3002 :)"}),"\n",(0,l.jsx)(n.h2,{id:"\u8a2d\u5b9a\u306b\u3064\u3044\u3066",children:"\u8a2d\u5b9a\u306b\u3064\u3044\u3066"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"MPU-9150\u306e\u8abf\u6574\u306fArduino\u30b9\u30b1\u30c3\u30c1\u306e201-204\u884c\u76ee\u3067\u5909\u66f4\u3067\u304d\u307e\u3059\u3002"}),"\n",(0,l.jsx)(n.li,{children:"\u30b7\u30ea\u30a2\u30eb\u30dd\u30fc\u30c8\u306e\u63a5\u7d9a\u8a2d\u5b9a\uff08\u30dd\u30fc\u30c8\u756a\u53f7\u3001\u30dc\u30fc\u30ec\u30fc\u30c8\u3001\u30bf\u30a4\u30e0\u30a2\u30a6\u30c8\u5024\uff09\u306fC#\u30b9\u30af\u30ea\u30d7\u30c8\u306e\u5148\u982d\u306e\u5b9a\u6570\u90e8\u5206\u3067\u5909\u66f4\u3067\u304d\u307e\u3059\u3002"}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"unity\u7528c\u30b9\u30af\u30ea\u30d7\u30c8",children:"Unity\u7528C#\u30b9\u30af\u30ea\u30d7\u30c8"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"pathname:///assets/Arduino/ControlObjectByMPU9150InUnity.cs",children:"ControlObjectByMPU9150InUnity.cs"})}),"\n",(0,l.jsx)(n.h2,{id:"\u53c2\u8003",children:"\u53c2\u8003"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:(0,l.jsx)(n.a,{href:"http://msdn.microsoft.com/ja-jp/library/system.io.ports.serialport(v=vs.110).aspx",children:"SerialPort \u30af\u30e9\u30b9 (System.IO.Ports)"})}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,l.jsx)(n,{...e,children:(0,l.jsx)(h,{...e})}):h(e)}},77833:(e,n,i)=>{i.d(n,{A:()=>t});var r=i(96540),l=function(){return l=Object.assign||function(e){for(var n,i=1,r=arguments.length;i<r;i++)for(var l in n=arguments[i])Object.prototype.hasOwnProperty.call(n,l)&&(e[l]=n[l]);return e},l.apply(this,arguments)};var t=r.forwardRef((function(e,n){var i=r.useState(!1),t=i[0],c=i[1],s=r.useState(e.alwaysLoadIframe||!1),a=s[0],d=s[1],o=encodeURIComponent(e.id),h="string"==typeof e.playlistCoverId?encodeURIComponent(e.playlistCoverId):null,u=e.title,j=e.poster||"hqdefault",x=e.announce||"Watch",p=new URLSearchParams(l(l(l(l({},e.muted?{mute:"1"}:{}),e.alwaysLoadIframe?{}:{autoplay:"1",state:"1"}),e.enableJsApi?{enablejsapi:"1"}:{}),e.playlist?{list:o}:{})),m=e.noCookie;m=e.cookie?"https://www.youtube.com":"https://www.youtube-nocookie.com";var f=e.playlist?"".concat(m,"/embed/videoseries?").concat(p.toString()):"".concat(m,"/embed/").concat(o,"?").concat(p.toString()),y=e.webp?"webp":"jpg",b=e.webp?"vi_webp":"vi",v=e.thumbnail||(e.playlist?"https://i.ytimg.com/".concat(b,"/").concat(h,"/").concat(j,".").concat(y):"https://i.ytimg.com/".concat(b,"/").concat(o,"/").concat(j,".").concat(y)),A=e.activatedClass||"lyt-activated",U=e.adNetwork||!1,P=e.aspectHeight||9,g=e.aspectWidth||16,C=e.iframeClass||"",w=e.playerClass||"lty-playbtn",M=e.wrapperClass||"yt-lite",O=e.onIframeAdded||function(){},E=e.rel?"prefetch":"preload",S=e.containerElement||"article",I=e.style||{};return r.useEffect((function(){a&&O()}),[a]),r.createElement(r.Fragment,null,r.createElement("link",{rel:E,href:v,as:"image"}),r.createElement(r.Fragment,null,t&&r.createElement(r.Fragment,null,r.createElement("link",{rel:"preconnect",href:m}),r.createElement("link",{rel:"preconnect",href:"https://www.google.com"}),U&&r.createElement(r.Fragment,null,r.createElement("link",{rel:"preconnect",href:"https://static.doubleclick.net"}),r.createElement("link",{rel:"preconnect",href:"https://googleads.g.doubleclick.net"})))),r.createElement(S,{onPointerOver:function(){t||c(!0)},onClick:function(){a||d(!0)},className:"".concat(M," ").concat(a?A:""),"data-title":u,style:l(l({backgroundImage:"url(".concat(v,")")},{"--aspect-ratio":"".concat(P/g*100,"%")}),I)},r.createElement("button",{type:"button",className:w,"aria-label":"".concat(x," ").concat(u)}),a&&r.createElement("iframe",{ref:n,className:C,title:u,width:"560",height:"315",frameBorder:"0",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,src:f})))}))}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.