LibDriver MPU6050
Loading...
Searching...
No Matches
driver_mpu6050.h
Go to the documentation of this file.
1
36
37#ifndef DRIVER_MPU6050_H
38#define DRIVER_MPU6050_H
39
40#include <stdio.h>
41#include <stdint.h>
42#include <string.h>
43
44#ifdef __cplusplus
45extern "C"{
46#endif
47
53
58
67
78
82typedef enum
83{
87
100
114
124
139
153
157typedef enum
158{
163
174
185
197
206
215
227
239
262
271
280
289
298
309
324
338
342
347
356
372
385
396
400
405
409typedef struct mpu6050_handle_s
410{
411 uint8_t iic_addr;
412 uint8_t (*iic_init)(void);
413 uint8_t (*iic_deinit)(void);
414 uint8_t (*iic_read)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len);
415 uint8_t (*iic_write)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len);
416 void (*delay_ms)(uint32_t ms);
417 void (*debug_print)(const char *const fmt, ...);
418 void (*receive_callback)(uint8_t type);
419 void (*dmp_tap_callback)(uint8_t count, uint8_t direction);
420 void (*dmp_orient_callback)(uint8_t orientation);
421 uint8_t inited;
422 uint8_t dmp_inited;
423 uint16_t orient;
424 uint16_t mask;
425 uint8_t buf[1024];
427
443
447
454
461#define DRIVER_MPU6050_LINK_INIT(HANDLE, STRUCTURE) memset(HANDLE, 0, sizeof(STRUCTURE))
462
469#define DRIVER_MPU6050_LINK_IIC_INIT(HANDLE, FUC) (HANDLE)->iic_init = FUC
470
477#define DRIVER_MPU6050_LINK_IIC_DEINIT(HANDLE, FUC) (HANDLE)->iic_deinit = FUC
478
485#define DRIVER_MPU6050_LINK_IIC_READ(HANDLE, FUC) (HANDLE)->iic_read = FUC
486
493#define DRIVER_MPU6050_LINK_IIC_WRITE(HANDLE, FUC) (HANDLE)->iic_write = FUC
494
501#define DRIVER_MPU6050_LINK_DELAY_MS(HANDLE, FUC) (HANDLE)->delay_ms = FUC
502
509#define DRIVER_MPU6050_LINK_DEBUG_PRINT(HANDLE, FUC) (HANDLE)->debug_print = FUC
510
517#define DRIVER_MPU6050_LINK_RECEIVE_CALLBACK(HANDLE, FUC) (HANDLE)->receive_callback = FUC
518
522
529
538uint8_t mpu6050_info(mpu6050_info_t *info);
539
550
561
573
586uint8_t mpu6050_init(mpu6050_handle_t *handle);
587
599uint8_t mpu6050_deinit(mpu6050_handle_t *handle);
600
619uint8_t mpu6050_read(mpu6050_handle_t *handle, int16_t (*accel_raw)[3], float (*accel_g)[3],
620 int16_t (*gyro_raw)[3], float (*gyro_dps)[3], uint16_t *len);
621
634uint8_t mpu6050_read_temperature(mpu6050_handle_t *handle, int16_t (*raw), float *degrees);
635
647uint8_t mpu6050_set_fifo(mpu6050_handle_t *handle, mpu6050_bool_t enable);
648
660uint8_t mpu6050_get_fifo(mpu6050_handle_t *handle, mpu6050_bool_t *enable);
661
673
686
699
710uint8_t mpu6050_fifo_reset(mpu6050_handle_t *handle);
711
724
736
749
761
774
786
799
812
825
838
851
864
877
889uint8_t mpu6050_set_sleep(mpu6050_handle_t *handle, mpu6050_bool_t enable);
890
902uint8_t mpu6050_get_sleep(mpu6050_handle_t *handle, mpu6050_bool_t *enable);
903
917
931
944
957
969uint8_t mpu6050_get_fifo_count(mpu6050_handle_t *handle, uint16_t* count);
970
983uint8_t mpu6050_fifo_get(mpu6050_handle_t *handle, uint8_t *buf, uint16_t len);
984
997uint8_t mpu6050_fifo_set(mpu6050_handle_t *handle, uint8_t *buf, uint16_t len);
998
1011
1023uint8_t mpu6050_set_sample_rate_divider(mpu6050_handle_t *handle, uint8_t d);
1024
1036uint8_t mpu6050_get_sample_rate_divider(mpu6050_handle_t *handle, uint8_t *d);
1037
1050
1063
1076
1089
1103
1117
1130
1143
1157
1171
1184
1197
1211
1225
1238
1251
1264
1277
1290
1303
1316
1329
1342
1355
1368
1381
1394
1407
1421
1435
1447uint8_t mpu6050_get_interrupt_status(mpu6050_handle_t *handle, uint8_t *status);
1448
1461uint8_t mpu6050_set_gyroscope_x_test(mpu6050_handle_t *handle, uint8_t data);
1462
1474uint8_t mpu6050_get_gyroscope_x_test(mpu6050_handle_t *handle, uint8_t *data);
1475
1488uint8_t mpu6050_set_gyroscope_y_test(mpu6050_handle_t *handle, uint8_t data);
1489
1501uint8_t mpu6050_get_gyroscope_y_test(mpu6050_handle_t *handle, uint8_t *data);
1502
1515uint8_t mpu6050_set_gyroscope_z_test(mpu6050_handle_t *handle, uint8_t data);
1516
1528uint8_t mpu6050_get_gyroscope_z_test(mpu6050_handle_t *handle, uint8_t *data);
1529
1542uint8_t mpu6050_set_accelerometer_x_test(mpu6050_handle_t *handle, uint8_t data);
1543
1555uint8_t mpu6050_get_accelerometer_x_test(mpu6050_handle_t *handle, uint8_t *data);
1556
1569uint8_t mpu6050_set_accelerometer_y_test(mpu6050_handle_t *handle, uint8_t data);
1570
1582uint8_t mpu6050_get_accelerometer_y_test(mpu6050_handle_t *handle, uint8_t *data);
1583
1596uint8_t mpu6050_set_accelerometer_z_test(mpu6050_handle_t *handle, uint8_t data);
1597
1609uint8_t mpu6050_get_accelerometer_z_test(mpu6050_handle_t *handle, uint8_t *data);
1610
1622uint8_t mpu6050_set_motion_threshold(mpu6050_handle_t *handle, uint8_t threshold);
1623
1635uint8_t mpu6050_get_motion_threshold(mpu6050_handle_t *handle, uint8_t *threshold);
1636
1648uint8_t mpu6050_motion_threshold_convert_to_register(mpu6050_handle_t *handle, float mg, uint8_t *reg);
1649
1661uint8_t mpu6050_motion_threshold_convert_to_data(mpu6050_handle_t *handle, uint8_t reg, float *mg);
1662
1674uint8_t mpu6050_set_motion_duration(mpu6050_handle_t *handle, uint8_t duration);
1675
1687uint8_t mpu6050_get_motion_duration(mpu6050_handle_t *handle, uint8_t *duration);
1688
1700uint8_t mpu6050_motion_duration_convert_to_register(mpu6050_handle_t *handle, uint8_t ms, uint8_t *reg);
1701
1713uint8_t mpu6050_motion_duration_convert_to_data(mpu6050_handle_t *handle, uint8_t reg, uint8_t *ms);
1714
1727
1740uint8_t mpu6050_self_test(mpu6050_handle_t *handle, int32_t gyro_offset_raw[3], int32_t accel_offset_raw[3]);
1741
1754
1767
1780
1793
1806
1819
1832
1845
1860
1875
1890
1905
1919uint8_t mpu6050_set_iic_address(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t addr_7bit);
1920
1934uint8_t mpu6050_get_iic_address(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *addr_7bit);
1935
1949uint8_t mpu6050_set_iic_register(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t reg);
1950
1964uint8_t mpu6050_get_iic_register(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *reg);
1965
1979uint8_t mpu6050_set_iic_data_out(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t data);
1980
1994uint8_t mpu6050_get_iic_data_out(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *data);
1995
2010
2025
2040
2055
2070
2085
2100
2115
2130uint8_t mpu6050_set_iic_transferred_len(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t len);
2131
2145uint8_t mpu6050_get_iic_transferred_len(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *len);
2146
2158uint8_t mpu6050_get_iic_status(mpu6050_handle_t *handle, uint8_t *status);
2159
2173
2187
2200
2213
2226
2239
2252
2265
2278uint8_t mpu6050_set_iic_delay(mpu6050_handle_t *handle, uint8_t delay);
2279
2291uint8_t mpu6050_get_iic_delay(mpu6050_handle_t *handle, uint8_t *delay);
2292
2304uint8_t mpu6050_set_iic4_data_out(mpu6050_handle_t *handle, uint8_t data);
2305
2317uint8_t mpu6050_get_iic4_data_out(mpu6050_handle_t *handle, uint8_t *data);
2318
2330uint8_t mpu6050_set_iic4_data_in(mpu6050_handle_t *handle, uint8_t data);
2331
2343uint8_t mpu6050_get_iic4_data_in(mpu6050_handle_t *handle, uint8_t *data);
2344
2358uint8_t mpu6050_read_extern_sensor_data(mpu6050_handle_t *handle, uint8_t *data, uint8_t len);
2359
2363
2370
2385
2398uint8_t mpu6050_dmp_set_pedometer_walk_time(mpu6050_handle_t *handle, uint32_t ms);
2399
2412uint8_t mpu6050_dmp_get_pedometer_walk_time(mpu6050_handle_t *handle, uint32_t *ms);
2413
2426uint8_t mpu6050_dmp_set_pedometer_step_count(mpu6050_handle_t *handle, uint32_t count);
2427
2440uint8_t mpu6050_dmp_get_pedometer_step_count(mpu6050_handle_t *handle, uint32_t *count);
2441
2454uint8_t mpu6050_dmp_set_shake_reject_timeout(mpu6050_handle_t *handle, uint16_t ms);
2455
2468uint8_t mpu6050_dmp_get_shake_reject_timeout(mpu6050_handle_t *handle, uint16_t *ms);
2469
2482uint8_t mpu6050_dmp_set_shake_reject_time(mpu6050_handle_t *handle, uint16_t ms);
2483
2496uint8_t mpu6050_dmp_get_shake_reject_time(mpu6050_handle_t *handle, uint16_t *ms);
2497
2510uint8_t mpu6050_dmp_set_shake_reject_thresh(mpu6050_handle_t *handle, uint16_t dps);
2511
2524uint8_t mpu6050_dmp_get_shake_reject_thresh(mpu6050_handle_t *handle, uint16_t *dps);
2525
2538uint8_t mpu6050_dmp_set_tap_time_multi(mpu6050_handle_t *handle, uint16_t ms);
2539
2552uint8_t mpu6050_dmp_get_tap_time_multi(mpu6050_handle_t *handle, uint16_t *ms);
2553
2566uint8_t mpu6050_dmp_set_tap_time(mpu6050_handle_t *handle, uint16_t ms);
2567
2580uint8_t mpu6050_dmp_get_tap_time(mpu6050_handle_t *handle, uint16_t *ms);
2581
2595uint8_t mpu6050_dmp_set_min_tap_count(mpu6050_handle_t *handle, uint8_t cnt);
2596
2609uint8_t mpu6050_dmp_get_min_tap_count(mpu6050_handle_t *handle, uint8_t *cnt);
2610
2625
2640
2656uint8_t mpu6050_dmp_set_tap_thresh(mpu6050_handle_t *handle, mpu6050_axis_t axis, uint16_t mg_ms);
2657
2672uint8_t mpu6050_dmp_get_tap_thresh(mpu6050_handle_t *handle, mpu6050_axis_t axis, uint16_t *mg_ms);
2673
2687uint8_t mpu6050_dmp_set_fifo_rate(mpu6050_handle_t *handle, uint16_t rate);
2688
2701uint8_t mpu6050_dmp_get_fifo_rate(mpu6050_handle_t *handle, uint16_t *rate);
2702
2716
2730
2744
2758
2771uint8_t mpu6050_dmp_set_gyro_bias(mpu6050_handle_t *handle, int32_t bias[3]);
2772
2785uint8_t mpu6050_dmp_set_accel_bias(mpu6050_handle_t *handle, int32_t bias[3]);
2786
2799uint8_t mpu6050_dmp_set_orientation(mpu6050_handle_t *handle, int8_t mat[9]);
2800
2817uint8_t mpu6050_dmp_set_feature(mpu6050_handle_t *handle, uint16_t mask);
2818
2843uint8_t mpu6050_dmp_read(mpu6050_handle_t *handle,
2844 int16_t (*accel_raw)[3], float (*accel_g)[3],
2845 int16_t (*gyro_raw)[3], float (*gyro_dps)[3],
2846 int32_t (*quat)[4],
2847 float *pitch, float *roll, float *yaw,
2848 uint16_t *l
2849 );
2850
2863uint8_t mpu6050_dmp_set_tap_callback(mpu6050_handle_t *handle, void (*callback)(uint8_t count, uint8_t direction));
2864
2877uint8_t mpu6050_dmp_set_orient_callback(mpu6050_handle_t *handle, void (*callback)(uint8_t orientation));
2878
2892
2909 int32_t gyro_offset_raw[3], int32_t accel_offset_raw[3],
2910 int32_t gyro_offset[3], int32_t accel_offset[3]);
2911
2915
2922
2936uint8_t mpu6050_set_reg(mpu6050_handle_t *handle, uint8_t reg, uint8_t *buf, uint16_t len);
2937
2951uint8_t mpu6050_get_reg(mpu6050_handle_t *handle, uint8_t reg, uint8_t *buf, uint16_t len);
2952
2956
2960
2961#ifdef __cplusplus
2962}
2963#endif
2964
2965#endif
uint8_t mpu6050_get_interrupt_latch(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the interrupt latch status
mpu6050_iic_mode_t
mpu6050 iic mode enumeration definition
uint8_t mpu6050_get_motion_duration(mpu6050_handle_t *handle, uint8_t *duration)
get the motion duration
uint8_t mpu6050_get_iic4_transaction_mode(mpu6050_handle_t *handle, mpu6050_iic4_transaction_mode_t *mode)
get the iic4 transaction mode
uint8_t mpu6050_get_motion_threshold(mpu6050_handle_t *handle, uint8_t *threshold)
get the motion_threshold
uint8_t mpu6050_get_temperature_sensor(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the temperature sensor status
uint8_t mpu6050_get_iic_byte_swap(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t *enable)
get the iic byte swap status
uint8_t mpu6050_get_iic_transferred_len(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *len)
get the iic transferred length
uint8_t mpu6050_set_gyroscope_z_test(mpu6050_handle_t *handle, uint8_t data)
set the gyroscope z test
uint8_t mpu6050_get_accelerometer_test(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t *enable)
get the accelerometer test
mpu6050_pin_type_t
mpu6050 pin type enumeration definition
uint8_t mpu6050_get_iic_read_mode(mpu6050_handle_t *handle, mpu6050_iic_read_mode_t *mode)
get the iic read mode
uint8_t mpu6050_get_accelerometer_x_test(mpu6050_handle_t *handle, uint8_t *data)
get the accelerometer x test
mpu6050_iic_read_mode_t
mpu6050 iic read mode enumeration definition
mpu6050_wake_up_frequency_t
mpu6050 wake up frequency enumeration definition
uint8_t mpu6050_get_iic4_data_out(mpu6050_handle_t *handle, uint8_t *data)
get the iic4 data out
struct mpu6050_info_s mpu6050_info_t
mpu6050 information structure definition
mpu6050_iic_clock_t
mpu6050 iic clock enumeration definition
uint8_t mpu6050_get_interrupt_status(mpu6050_handle_t *handle, uint8_t *status)
get the interrupt status
uint8_t mpu6050_set_iic4_enable(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the iic4
uint8_t mpu6050_set_iic_transaction_mode(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_transaction_mode_t mode)
set the iic transaction mode
uint8_t mpu6050_set_iic4_data_in(mpu6050_handle_t *handle, uint8_t data)
set the iic4 data in
uint8_t mpu6050_get_cycle_wake_up(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the cycle wake up mode status
uint8_t mpu6050_iic_master_reset(mpu6050_handle_t *handle)
reset the iic master controller
uint8_t mpu6050_set_gyroscope_y_test(mpu6050_handle_t *handle, uint8_t data)
set the gyroscope y test
uint8_t mpu6050_set_iic_wait_for_external_sensor(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable iic wait for external sensor
uint8_t mpu6050_sensor_reset(mpu6050_handle_t *handle)
reset all sensors
uint8_t mpu6050_get_low_pass_filter(mpu6050_handle_t *handle, mpu6050_low_pass_filter_t *filter)
get the low pass filter
uint8_t mpu6050_set_wake_up_frequency(mpu6050_handle_t *handle, mpu6050_wake_up_frequency_t frequency)
set the wake up frequency
mpu6050_gyroscope_range_t
mpu6050 gyroscope range enumeration definition
uint8_t mpu6050_set_accelerometer_x_test(mpu6050_handle_t *handle, uint8_t data)
set the accelerometer x test
uint8_t mpu6050_fifo_reset(mpu6050_handle_t *handle)
reset the fifo
uint8_t mpu6050_get_interrupt_pin_type(mpu6050_handle_t *handle, mpu6050_pin_type_t *type)
get the interrupt pin type
uint8_t mpu6050_get_iic_address(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *addr_7bit)
get the iic address
uint8_t mpu6050_get_iic_group_order(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_group_order_t *order)
get the iic group order
uint8_t mpu6050_init(mpu6050_handle_t *handle)
initialize the chip
uint8_t mpu6050_set_iic_multi_master(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable iic multi master
uint8_t mpu6050_set_iic_group_order(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_group_order_t order)
set the iic group order
uint8_t mpu6050_get_iic_clock(mpu6050_handle_t *handle, mpu6050_iic_clock_t *clk)
get the iic clock
uint8_t mpu6050_set_iic_address(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t addr_7bit)
set the iic address
mpu6050_extern_sync_t
mpu6050 extern sync enumeration definition
uint8_t mpu6050_read_temperature(mpu6050_handle_t *handle, int16_t(*raw), float *degrees)
read the temperature
uint8_t mpu6050_set_accelerometer_range(mpu6050_handle_t *handle, mpu6050_accelerometer_range_t range)
set the accelerometer range
uint8_t mpu6050_device_reset(mpu6050_handle_t *handle)
reset the chip
mpu6050_address_t
mpu6050 address enumeration definition
uint8_t mpu6050_set_standby_mode(mpu6050_handle_t *handle, mpu6050_source_t source, mpu6050_bool_t enable)
set source into standby mode
mpu6050_iic_delay_t
mpu6050 iic delay enumeration definition
uint8_t mpu6050_get_iic_fifo_enable(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t *enable)
get the iic fifo status
uint8_t mpu6050_get_interrupt_read_clear(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the interrupt reading clear status
uint8_t mpu6050_set_iic_register(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t reg)
set the iic register
uint8_t mpu6050_motion_threshold_convert_to_register(mpu6050_handle_t *handle, float mg, uint8_t *reg)
convert the motion threshold to the register raw data
uint8_t mpu6050_get_iic_master_reset(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic master reset status
uint8_t mpu6050_get_interrupt(mpu6050_handle_t *handle, mpu6050_interrupt_t type, mpu6050_bool_t *enable)
get the interrupt status
uint8_t mpu6050_self_test(mpu6050_handle_t *handle, int32_t gyro_offset_raw[3], int32_t accel_offset_raw[3])
run the self test
uint8_t mpu6050_set_gyroscope_x_test(mpu6050_handle_t *handle, uint8_t data)
set the gyroscope x test
uint8_t mpu6050_get_accelerometer_z_test(mpu6050_handle_t *handle, uint8_t *data)
get the accelerometer z test
uint8_t mpu6050_set_iic_delay(mpu6050_handle_t *handle, uint8_t delay)
set the iic delay
mpu6050_source_t
mpu6050 source enumeration definition
uint8_t mpu6050_get_sleep(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the sleep status
uint8_t mpu6050_set_iic_transferred_len(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t len)
set the iic transferred length
uint8_t mpu6050_set_motion_threshold(mpu6050_handle_t *handle, uint8_t threshold)
set the motion_threshold
uint8_t mpu6050_get_sample_rate_divider(mpu6050_handle_t *handle, uint8_t *d)
get the sample rate divider
uint8_t mpu6050_set_iic4_interrupt(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the iic4 interrupt
uint8_t mpu6050_set_iic_clock(mpu6050_handle_t *handle, mpu6050_iic_clock_t clk)
set the iic clock
uint8_t mpu6050_set_iic4_data_out(mpu6050_handle_t *handle, uint8_t data)
set the iic4 data out
uint8_t mpu6050_fifo_get(mpu6050_handle_t *handle, uint8_t *buf, uint16_t len)
fifo read bytes
uint8_t mpu6050_get_accelerometer_y_test(mpu6050_handle_t *handle, uint8_t *data)
get the accelerometer y test
uint8_t mpu6050_set_sample_rate_divider(mpu6050_handle_t *handle, uint8_t d)
set the sample rate divider
uint8_t mpu6050_set_motion_duration(mpu6050_handle_t *handle, uint8_t duration)
set the motion duration
uint8_t mpu6050_set_gyroscope_range(mpu6050_handle_t *handle, mpu6050_gyroscope_range_t range)
set the gyroscope range
uint8_t mpu6050_set_addr_pin(mpu6050_handle_t *handle, mpu6050_address_t addr_pin)
set the chip address pin
uint8_t mpu6050_get_wake_up_frequency(mpu6050_handle_t *handle, mpu6050_wake_up_frequency_t *frequency)
get the wake up frequency
uint8_t mpu6050_get_interrupt_level(mpu6050_handle_t *handle, mpu6050_pin_level_t *level)
get the interrupt level
mpu6050_iic_group_order_t
mpu6050 iic group order enumeration definition
uint8_t mpu6050_set_interrupt_read_clear(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the interrupt reading clear
uint8_t mpu6050_read(mpu6050_handle_t *handle, int16_t(*accel_raw)[3], float(*accel_g)[3], int16_t(*gyro_raw)[3], float(*gyro_dps)[3], uint16_t *len)
read the data
uint8_t mpu6050_set_fifo_enable(mpu6050_handle_t *handle, mpu6050_fifo_t fifo, mpu6050_bool_t enable)
enable or disable the fifo function
mpu6050_fifo_t
mpu6050 fifo enumeration definition
mpu6050_clock_source_t
mpu6050 clock source enumeration definition
uint8_t mpu6050_set_iic_byte_swap(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t enable)
enable or disable the iic byte swap
uint8_t mpu6050_get_gyroscope_z_test(mpu6050_handle_t *handle, uint8_t *data)
get the gyroscope z test
uint8_t mpu6050_get_iic_data_out(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *data)
get the iic data out
uint8_t mpu6050_get_fifo_enable(mpu6050_handle_t *handle, mpu6050_fifo_t fifo, mpu6050_bool_t *enable)
get the fifo function status
uint8_t mpu6050_get_extern_sync(mpu6050_handle_t *handle, mpu6050_extern_sync_t *sync)
get the extern sync type
uint8_t mpu6050_get_iic_master(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic master status
uint8_t mpu6050_set_accelerometer_y_test(mpu6050_handle_t *handle, uint8_t data)
set the accelerometer y test
uint8_t mpu6050_set_interrupt(mpu6050_handle_t *handle, mpu6050_interrupt_t type, mpu6050_bool_t enable)
enable or disable the interrupt
uint8_t mpu6050_set_iic_bypass(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the iic bypass
uint8_t mpu6050_info(mpu6050_info_t *info)
get the chip's information
uint8_t mpu6050_set_gyroscope_test(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t enable)
set the gyroscope test
uint8_t mpu6050_get_fsync_interrupt_level(mpu6050_handle_t *handle, mpu6050_pin_level_t *level)
get the fsync interrupt level
mpu6050_pin_level_t
mpu6050 pin level enumeration definition
uint8_t mpu6050_get_iic4_enable(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic4 status
uint8_t mpu6050_set_cycle_wake_up(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the cycle wake up mode
uint8_t mpu6050_get_device_reset(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the device reset status
uint8_t mpu6050_get_fifo_reset(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the fifo reset status
uint8_t mpu6050_set_interrupt_pin_type(mpu6050_handle_t *handle, mpu6050_pin_type_t type)
set the interrupt pin type
uint8_t mpu6050_set_signal_path_reset(mpu6050_handle_t *handle, mpu6050_signal_path_reset_t path)
set the signal path reset
uint8_t mpu6050_get_iic_enable(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t *enable)
get the iic status
uint8_t mpu6050_get_iic_transaction_mode(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_transaction_mode_t *mode)
get the iic transaction mode
uint8_t mpu6050_irq_handler(mpu6050_handle_t *handle)
irq handler
uint8_t mpu6050_get_standby_mode(mpu6050_handle_t *handle, mpu6050_source_t source, mpu6050_bool_t *enable)
get the source mode
uint8_t mpu6050_set_iic_master(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the iic master mode
uint8_t mpu6050_force_fifo_reset(mpu6050_handle_t *handle)
force reset the fifo
uint8_t mpu6050_get_gyroscope_x_test(mpu6050_handle_t *handle, uint8_t *data)
get the gyroscope x test
uint8_t mpu6050_get_gyroscope_y_test(mpu6050_handle_t *handle, uint8_t *data)
get the gyroscope y test
uint8_t mpu6050_set_temperature_sensor(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the temperature sensor
uint8_t mpu6050_set_interrupt_latch(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the interrupt latch
mpu6050_interrupt_t
mpu6050 interrupt enumeration definition
uint8_t mpu6050_set_iic4_transaction_mode(mpu6050_handle_t *handle, mpu6050_iic4_transaction_mode_t mode)
set the iic4 transaction mode
mpu6050_accelerometer_range_t
mpu6050 accelerometer range enumeration definition
mpu6050_signal_path_reset_t
mpu6050 signal path reset enumeration definition
uint8_t mpu6050_get_gyroscope_test(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t *enable)
get the gyroscope test
mpu6050_iic_slave_t
mpu6050 iic slave enumeration definition
mpu6050_iic_transaction_mode_t
mpu6050 iic transaction mode enumeration definition
uint8_t mpu6050_get_fsync_interrupt(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the fsync interrupt status
uint8_t mpu6050_set_iic_enable(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t enable)
enable or disable the iic
uint8_t mpu6050_set_accelerometer_test(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t enable)
set the accelerometer test
uint8_t mpu6050_set_extern_sync(mpu6050_handle_t *handle, mpu6050_extern_sync_t sync)
set the extern sync type
uint8_t mpu6050_get_iic_bypass(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic bypass status
uint8_t mpu6050_set_sleep(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the sleep mode
struct mpu6050_handle_s mpu6050_handle_t
mpu6050 handle structure definition
uint8_t mpu6050_motion_threshold_convert_to_data(mpu6050_handle_t *handle, uint8_t reg, float *mg)
convert the register raw data to the motion threshold
uint8_t mpu6050_get_clock_source(mpu6050_handle_t *handle, mpu6050_clock_source_t *clock_source)
get the chip clock source
mpu6050_bool_t
mpu6050 bool enumeration definition
uint8_t mpu6050_set_fifo(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable fifo
uint8_t mpu6050_set_interrupt_level(mpu6050_handle_t *handle, mpu6050_pin_level_t level)
set the interrupt level
uint8_t mpu6050_read_extern_sensor_data(mpu6050_handle_t *handle, uint8_t *data, uint8_t len)
read the extern sensor data
uint8_t mpu6050_get_addr_pin(mpu6050_handle_t *handle, mpu6050_address_t *addr_pin)
get the chip address pin
uint8_t mpu6050_motion_duration_convert_to_register(mpu6050_handle_t *handle, uint8_t ms, uint8_t *reg)
convert the motion duration to the register raw data
uint8_t mpu6050_get_iic_status(mpu6050_handle_t *handle, uint8_t *status)
get the iic status
uint8_t mpu6050_get_accelerometer_range(mpu6050_handle_t *handle, mpu6050_accelerometer_range_t *range)
get the accelerometer range
uint8_t mpu6050_set_iic_data_out(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t data)
set the iic data out
uint8_t mpu6050_get_iic_wait_for_external_sensor(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic wait for external sensor status
uint8_t mpu6050_set_iic_fifo_enable(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_bool_t enable)
enable or disable the iic fifo
mpu6050_low_pass_filter_t
mpu6050 low pass filter enumeration definition
uint8_t mpu6050_get_fifo(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the fifo status
uint8_t mpu6050_set_clock_source(mpu6050_handle_t *handle, mpu6050_clock_source_t clock_source)
set the chip clock source
uint8_t mpu6050_fifo_set(mpu6050_handle_t *handle, uint8_t *buf, uint16_t len)
fifo write bytes
uint8_t mpu6050_get_iic_register(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, uint8_t *reg)
get the iic register
uint8_t mpu6050_get_gyroscope_range(mpu6050_handle_t *handle, mpu6050_gyroscope_range_t *range)
get the gyroscope range
uint8_t mpu6050_set_iic_read_mode(mpu6050_handle_t *handle, mpu6050_iic_read_mode_t mode)
set the iic read mode
uint8_t mpu6050_get_iic4_data_in(mpu6050_handle_t *handle, uint8_t *data)
get the iic4 data in
uint8_t mpu6050_get_sensor_reset(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the sensor reset status
uint8_t mpu6050_get_fifo_count(mpu6050_handle_t *handle, uint16_t *count)
get the fifo counter value
uint8_t mpu6050_set_fsync_interrupt(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the fsync interrupt
uint8_t mpu6050_motion_duration_convert_to_data(mpu6050_handle_t *handle, uint8_t reg, uint8_t *ms)
convert the register raw data to the motion duration
mpu6050_iic4_transaction_mode_t
mpu6050 iic4 transaction mode enumeration definition
uint8_t mpu6050_set_low_pass_filter(mpu6050_handle_t *handle, mpu6050_low_pass_filter_t filter)
set the low pass filter
uint8_t mpu6050_set_iic_mode(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_mode_t mode)
set the iic mode
uint8_t mpu6050_deinit(mpu6050_handle_t *handle)
close the chip
uint8_t mpu6050_get_iic_delay_enable(mpu6050_handle_t *handle, mpu6050_iic_delay_t delay, mpu6050_bool_t *enable)
get the iic delay status
uint8_t mpu6050_set_iic_delay_enable(mpu6050_handle_t *handle, mpu6050_iic_delay_t delay, mpu6050_bool_t enable)
enable or disable the iic delay
mpu6050_iic_status_t
mpu6050 iic status enumeration definition
uint8_t mpu6050_get_iic_mode(mpu6050_handle_t *handle, mpu6050_iic_slave_t slave, mpu6050_iic_mode_t *mode)
get the iic mode
uint8_t mpu6050_get_iic_multi_master(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic multi master status
uint8_t mpu6050_get_iic_delay(mpu6050_handle_t *handle, uint8_t *delay)
get the iic delay
uint8_t mpu6050_set_fsync_interrupt_level(mpu6050_handle_t *handle, mpu6050_pin_level_t level)
set the fsync interrupt level
uint8_t mpu6050_set_force_accel_sample(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable force accel sample
mpu6050_axis_t
mpu6050 axis enumeration definition
uint8_t mpu6050_set_accelerometer_z_test(mpu6050_handle_t *handle, uint8_t data)
set the accelerometer z test
uint8_t mpu6050_get_iic4_interrupt(mpu6050_handle_t *handle, mpu6050_bool_t *enable)
get the iic4 interrupt status
@ MPU6050_IIC_MODE_READ
@ MPU6050_IIC_MODE_WRITE
@ MPU6050_PIN_TYPE_PUSH_PULL
@ MPU6050_PIN_TYPE_OPEN_DRAIN
@ MPU6050_IIC_READ_MODE_RESTART
@ MPU6050_IIC_READ_MODE_STOP_AND_START
@ MPU6050_WAKE_UP_FREQUENCY_1P25_HZ
@ MPU6050_WAKE_UP_FREQUENCY_40_HZ
@ MPU6050_WAKE_UP_FREQUENCY_20_HZ
@ MPU6050_WAKE_UP_FREQUENCY_5_HZ
@ MPU6050_IIC_CLOCK_296_KHZ
@ MPU6050_IIC_CLOCK_364_KHZ
@ MPU6050_IIC_CLOCK_348_KHZ
@ MPU6050_IIC_CLOCK_286_KHZ
@ MPU6050_IIC_CLOCK_267_KHZ
@ MPU6050_IIC_CLOCK_308_KHZ
@ MPU6050_IIC_CLOCK_400_KHZ
@ MPU6050_IIC_CLOCK_333_KHZ
@ MPU6050_IIC_CLOCK_320_KHZ
@ MPU6050_IIC_CLOCK_258_KHZ
@ MPU6050_IIC_CLOCK_276_KHZ
@ MPU6050_IIC_CLOCK_381_KHZ
@ MPU6050_IIC_CLOCK_444_KHZ
@ MPU6050_IIC_CLOCK_421_KHZ
@ MPU6050_IIC_CLOCK_500_KHZ
@ MPU6050_IIC_CLOCK_471_KHZ
@ MPU6050_GYROSCOPE_RANGE_250DPS
@ MPU6050_GYROSCOPE_RANGE_2000DPS
@ MPU6050_GYROSCOPE_RANGE_1000DPS
@ MPU6050_GYROSCOPE_RANGE_500DPS
@ MPU6050_EXTERN_SYNC_GYRO_ZOUT_L
@ MPU6050_EXTERN_SYNC_GYRO_YOUT_L
@ MPU6050_EXTERN_SYNC_GYRO_XOUT_L
@ MPU6050_EXTERN_SYNC_ACCEL_YOUT_L
@ MPU6050_EXTERN_SYNC_INPUT_DISABLED
@ MPU6050_EXTERN_SYNC_ACCEL_ZOUT_L
@ MPU6050_EXTERN_SYNC_ACCEL_XOUT_L
@ MPU6050_EXTERN_SYNC_TEMP_OUT_L
@ MPU6050_ADDRESS_AD0_LOW
@ MPU6050_ADDRESS_AD0_HIGH
@ MPU6050_IIC_DELAY_SLAVE_3
@ MPU6050_IIC_DELAY_SLAVE_1
@ MPU6050_IIC_DELAY_SLAVE_2
@ MPU6050_IIC_DELAY_SLAVE_4
@ MPU6050_IIC_DELAY_SLAVE_0
@ MPU6050_IIC_DELAY_ES_SHADOW
@ MPU6050_SOURCE_ACC_Y
@ MPU6050_SOURCE_GYRO_Y
@ MPU6050_SOURCE_ACC_Z
@ MPU6050_SOURCE_ACC_X
@ MPU6050_SOURCE_GYRO_Z
@ MPU6050_SOURCE_GYRO_X
@ MPU6050_IIC_GROUP_ORDER_EVEN
@ MPU6050_IIC_GROUP_ORDER_ODD
@ MPU6050_FIFO_XG
@ MPU6050_FIFO_ACCEL
@ MPU6050_FIFO_TEMP
@ MPU6050_FIFO_ZG
@ MPU6050_FIFO_YG
@ MPU6050_CLOCK_SOURCE_INTERNAL_8MHZ
@ MPU6050_CLOCK_SOURCE_STOP_CLOCK
@ MPU6050_CLOCK_SOURCE_PLL_EXT_32P768_KHZ
@ MPU6050_CLOCK_SOURCE_PLL_X_GYRO
@ MPU6050_CLOCK_SOURCE_PLL_Z_GYRO
@ MPU6050_CLOCK_SOURCE_PLL_Y_GYRO
@ MPU6050_CLOCK_SOURCE_PLL_EXT_19P2_MHZ
@ MPU6050_PIN_LEVEL_HIGH
@ MPU6050_PIN_LEVEL_LOW
@ MPU6050_INTERRUPT_DMP
@ MPU6050_INTERRUPT_I2C_MAST
@ MPU6050_INTERRUPT_DATA_READY
@ MPU6050_INTERRUPT_FIFO_OVERFLOW
@ MPU6050_INTERRUPT_MOTION
@ MPU6050_ACCELEROMETER_RANGE_16G
@ MPU6050_ACCELEROMETER_RANGE_4G
@ MPU6050_ACCELEROMETER_RANGE_2G
@ MPU6050_ACCELEROMETER_RANGE_8G
@ MPU6050_SIGNAL_PATH_RESET_GYRO
@ MPU6050_SIGNAL_PATH_RESET_ACCEL
@ MPU6050_SIGNAL_PATH_RESET_TEMP
@ MPU6050_IIC_SLAVE_3
@ MPU6050_IIC_SLAVE_1
@ MPU6050_IIC_SLAVE_0
@ MPU6050_IIC_SLAVE_2
@ MPU6050_IIC_SLAVE_4
@ MPU6050_IIC_TRANSACTION_MODE_DATA
@ MPU6050_IIC_TRANSACTION_MODE_REG_DATA
@ MPU6050_BOOL_TRUE
@ MPU6050_BOOL_FALSE
@ MPU6050_LOW_PASS_FILTER_0
@ MPU6050_LOW_PASS_FILTER_4
@ MPU6050_LOW_PASS_FILTER_3
@ MPU6050_LOW_PASS_FILTER_6
@ MPU6050_LOW_PASS_FILTER_1
@ MPU6050_LOW_PASS_FILTER_5
@ MPU6050_LOW_PASS_FILTER_2
@ MPU6050_IIC4_TRANSACTION_MODE_REG
@ MPU6050_IIC4_TRANSACTION_MODE_DATA
@ MPU6050_IIC_STATUS_IIC_SLV0_NACK
@ MPU6050_IIC_STATUS_PASS_THROUGH
@ MPU6050_IIC_STATUS_IIC_SLV4_NACK
@ MPU6050_IIC_STATUS_IIC_SLV1_NACK
@ MPU6050_IIC_STATUS_IIC_LOST_ARB
@ MPU6050_IIC_STATUS_IIC_SLV4_DONE
@ MPU6050_IIC_STATUS_IIC_SLV3_NACK
@ MPU6050_IIC_STATUS_IIC_SLV2_NACK
@ MPU6050_AXIS_X
@ MPU6050_AXIS_Z
@ MPU6050_AXIS_Y
uint8_t mpu6050_dmp_set_tap_thresh(mpu6050_handle_t *handle, mpu6050_axis_t axis, uint16_t mg_ms)
dmp set the tap thresh
mpu6050_dmp_orient_t
mpu6050 dmp orient enumeration definition
uint8_t mpu6050_dmp_set_gyro_bias(mpu6050_handle_t *handle, int32_t bias[3])
dmp set the gyro bias
uint8_t mpu6050_dmp_set_orientation(mpu6050_handle_t *handle, int8_t mat[9])
dmp set the orientation
uint8_t mpu6050_dmp_get_shake_reject_time(mpu6050_handle_t *handle, uint16_t *ms)
dmp get the shake reject time
uint8_t mpu6050_dmp_get_shake_reject_thresh(mpu6050_handle_t *handle, uint16_t *dps)
dmp get the shake reject thresh
uint8_t mpu6050_dmp_set_enable(mpu6050_handle_t *handle, mpu6050_bool_t enable)
enable or disable the dmp
uint8_t mpu6050_dmp_load_firmware(mpu6050_handle_t *handle)
load the dmp firmware
uint8_t mpu6050_dmp_set_tap_callback(mpu6050_handle_t *handle, void(*callback)(uint8_t count, uint8_t direction))
dmp set the tap callback
uint8_t mpu6050_dmp_set_orient_callback(mpu6050_handle_t *handle, void(*callback)(uint8_t orientation))
dmp set the orient callback
uint8_t mpu6050_dmp_set_shake_reject_timeout(mpu6050_handle_t *handle, uint16_t ms)
dmp set the shake reject timeout
uint8_t mpu6050_dmp_read(mpu6050_handle_t *handle, int16_t(*accel_raw)[3], float(*accel_g)[3], int16_t(*gyro_raw)[3], float(*gyro_dps)[3], int32_t(*quat)[4], float *pitch, float *roll, float *yaw, uint16_t *l)
dmp read the data
uint8_t mpu6050_dmp_set_tap_time_multi(mpu6050_handle_t *handle, uint16_t ms)
dmp set max time between taps to register as a multi tap
uint8_t mpu6050_dmp_set_accel_bias(mpu6050_handle_t *handle, int32_t bias[3])
dmp set the accel bias
uint8_t mpu6050_dmp_get_pedometer_step_count(mpu6050_handle_t *handle, uint32_t *count)
dmp get the pedometer step count
uint8_t mpu6050_dmp_set_pedometer_step_count(mpu6050_handle_t *handle, uint32_t count)
dmp set the pedometer step count
uint8_t mpu6050_dmp_get_tap_axes(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t *enable)
dmp get the tap axes status
uint8_t mpu6050_dmp_set_feature(mpu6050_handle_t *handle, uint16_t mask)
dmp enable or disable the dmp feature
uint8_t mpu6050_dmp_gyro_accel_raw_offset_convert(mpu6050_handle_t *handle, int32_t gyro_offset_raw[3], int32_t accel_offset_raw[3], int32_t gyro_offset[3], int32_t accel_offset[3])
dmp gyro accel raw offset convert
uint8_t mpu6050_dmp_get_tap_thresh(mpu6050_handle_t *handle, mpu6050_axis_t axis, uint16_t *mg_ms)
dmp get the tap thresh
mpu6050_dmp_feature_t
mpu6050 dmp feature enumeration definition
uint8_t mpu6050_dmp_set_6x_quaternion(mpu6050_handle_t *handle, mpu6050_bool_t enable)
dmp enable or disable generate 6 axis quaternions from dmp
uint8_t mpu6050_dmp_get_pedometer_walk_time(mpu6050_handle_t *handle, uint32_t *ms)
dmp get the pedometer walk time
uint8_t mpu6050_dmp_set_shake_reject_thresh(mpu6050_handle_t *handle, uint16_t dps)
dmp set the shake reject thresh
uint8_t mpu6050_dmp_get_tap_time(mpu6050_handle_t *handle, uint16_t *ms)
dmp get the tap time
mpu6050_dmp_interrupt_mode_t
mpu6050 dmp interrupt mode enumeration definition
uint8_t mpu6050_dmp_set_fifo_rate(mpu6050_handle_t *handle, uint16_t rate)
dmp set the fifo rate
uint8_t mpu6050_dmp_set_tap_axes(mpu6050_handle_t *handle, mpu6050_axis_t axis, mpu6050_bool_t enable)
dmp enable or disable the tap axes
uint8_t mpu6050_dmp_set_shake_reject_time(mpu6050_handle_t *handle, uint16_t ms)
dmp set the shake reject time
uint8_t mpu6050_dmp_get_fifo_rate(mpu6050_handle_t *handle, uint16_t *rate)
dmp get the fifo rate
uint8_t mpu6050_dmp_set_min_tap_count(mpu6050_handle_t *handle, uint8_t cnt)
dmp set the min tap count
uint8_t mpu6050_dmp_get_shake_reject_timeout(mpu6050_handle_t *handle, uint16_t *ms)
dmp get the shake reject timeout
uint8_t mpu6050_dmp_get_min_tap_count(mpu6050_handle_t *handle, uint8_t *cnt)
dmp get the min tap count
uint8_t mpu6050_dmp_get_tap_time_multi(mpu6050_handle_t *handle, uint16_t *ms)
dmp get max time between taps to register as a multi tap
uint8_t mpu6050_dmp_set_gyro_calibrate(mpu6050_handle_t *handle, mpu6050_bool_t enable)
dmp enable or disable gyro calibrate
uint8_t mpu6050_dmp_set_tap_time(mpu6050_handle_t *handle, uint16_t ms)
dmp set the tap time
uint8_t mpu6050_dmp_set_3x_quaternion(mpu6050_handle_t *handle, mpu6050_bool_t enable)
dmp enable or disable generate 3 axis quaternions from dmp
uint8_t mpu6050_dmp_set_interrupt_mode(mpu6050_handle_t *handle, mpu6050_dmp_interrupt_mode_t mode)
dmp set the interrupt mode
uint8_t mpu6050_dmp_set_pedometer_walk_time(mpu6050_handle_t *handle, uint32_t ms)
dmp set the pedometer walk time
mpu6050_dmp_tap_t
mpu6050 dmp tap enumeration definition
@ MPU6050_DMP_ORIENT_PORTRAIT
@ MPU6050_DMP_ORIENT_REVERSE_LANDSCAPE
@ MPU6050_DMP_ORIENT_LANDSCAPE
@ MPU6050_DMP_ORIENT_REVERSE_PORTRAIT
@ MPU6050_DMP_FEATURE_PEDOMETER
@ MPU6050_DMP_FEATURE_TAP
@ MPU6050_DMP_FEATURE_ORIENT
@ MPU6050_DMP_FEATURE_6X_QUAT
@ MPU6050_DMP_FEATURE_GYRO_CAL
@ MPU6050_DMP_FEATURE_SEND_RAW_ACCEL
@ MPU6050_DMP_FEATURE_SEND_CAL_GYRO
@ MPU6050_DMP_FEATURE_3X_QUAT
@ MPU6050_DMP_FEATURE_SEND_RAW_GYRO
@ MPU6050_DMP_INTERRUPT_MODE_CONTINUOUS
@ MPU6050_DMP_INTERRUPT_MODE_GESTURE
@ MPU6050_DMP_TAP_X_UP
@ MPU6050_DMP_TAP_X_DOWN
@ MPU6050_DMP_TAP_Y_UP
@ MPU6050_DMP_TAP_Y_DOWN
@ MPU6050_DMP_TAP_Z_DOWN
@ MPU6050_DMP_TAP_Z_UP
uint8_t mpu6050_get_reg(mpu6050_handle_t *handle, uint8_t reg, uint8_t *buf, uint16_t len)
get the chip register
uint8_t mpu6050_set_reg(mpu6050_handle_t *handle, uint8_t reg, uint8_t *buf, uint16_t len)
set the chip register
mpu6050 handle structure definition
uint8_t buf[1024]
void(* dmp_tap_callback)(uint8_t count, uint8_t direction)
void(* delay_ms)(uint32_t ms)
void(* receive_callback)(uint8_t type)
void(* debug_print)(const char *const fmt,...)
uint8_t(* iic_init)(void)
void(* dmp_orient_callback)(uint8_t orientation)
uint8_t(* iic_write)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
uint8_t(* iic_read)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
uint8_t(* iic_deinit)(void)
mpu6050 information structure definition
uint32_t driver_version
char manufacturer_name[32]