반응형 MPU60501 [Arduino] 아두이노로 MPU-6050 가속도센서 사용하기 #include #include #include MPU6050 mpu; void setup() { Serial.begin(9600); // Initialize serial communication with a baud rate of 9600 Wire.begin(); // Start the I2C communication mpu.initialize(); // Initialize the MPU-6050 sensor } void loop() { mpu.getMotion6(&ax, &ay, &az, &gx, &gy, &gz); // Read the accelerometer and gyroscope values // Print the accelerometer and gyroscope values to the se.. 2023. 2. 2. 이전 1 다음 반응형