Commit 9607144c authored by ttwards's avatar ttwards
Browse files

updated imu

parent c154159f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
BasedOnStyle: LLVM  
IndentWidth: 4
ColumnLimit: 100
ColumnLimit: 98
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: true
AlignConsecutiveMacros: Consecutive
+1 −1
Original line number Diff line number Diff line
@@ -33,7 +33,7 @@
    "C_Cpp.formatting": "clangFormat",
    "C_Cpp.errorSquiggles": "disabled",
    "stm32-for-vscode.armToolchainPath": false,
    "cortex-debug.variableUseNaturalFormat": true,
    "cortex-debug.variableUseNaturalFormat": false,
    "terminal.integrated.defaultProfile.linux": "Zephyr IDE Terminal",
    "C_Cpp.default.compileCommands": "${workspaceFolder}/.vscode/compile_commands.json",
    "cmake.configureOnOpen": false,
+0 −23
Original line number Diff line number Diff line
@@ -223,29 +223,6 @@ zephyr_udc0: &usbotg_fs {
			&spi1_sck_pb3>;
	pinctrl-names="default";

	bmi08x_accel: bmi08x@0 {
		compatible = "bosch,bmi08x-accel";
		reg = <0>;
		int-gpios = <&gpioc 4 GPIO_ACTIVE_HIGH>;
		spi-max-frequency = <10000000>;
		int1-map-io = <0x01>;
		int2-map-io = <0x00>;
		int1-conf-io = <0x04>;
		int2-conf-io = <0x00>;
		accel-hz = "800";
		accel-fs = <24>;
	};

	bmi08x_gyro: bmi08x@1 {
		compatible = "bosch,bmi08x-gyro";
		reg = <1>;
		int-gpios = <&gpioc 5 GPIO_ACTIVE_HIGH>;
		spi-max-frequency = <10000000>;
		int3-4-map-io = <0x01>;
		int3-4-conf-io = <0x02>;
		gyro-hz = "1000_116";
		gyro-fs = <1000>;
	};
};

// spi1_pins: spi1-1 {
+32 −0
Original line number Diff line number Diff line
@@ -89,3 +89,35 @@
		status = "okay";
	};
};

&spi1 {
    status = "okay";

    bmi08x_accel: bmi08x_accel@0 {
        compatible = "bosch,bmi08x-accel";
		status = "okay";
        reg = <0>;
        spi-max-frequency = <8000000>;
        int-gpios = <&gpioc 4 GPIO_ACTIVE_HIGH>;
        accel-hz = "1600";
        accel-fs = <12>;
		int1-map-io = <0>;
		int2-map-io = <0>;
        int1-conf-io = <0>;
		int2-conf-io = <0>;
		// 其他所需属性...
    };

    bmi08x_gyro: bmi08x_gyro@1{
        compatible = "bosch,bmi08x-gyro";
		status = "okay";
        reg = <1>;
        spi-max-frequency = <8000000>;
        int-gpios = <&gpioc 5 GPIO_ACTIVE_HIGH>;
        gyro-hz = "2000_532";
        gyro-fs = <2000>;
		int3-4-map-io = <0>;
		int3-4-conf-io = <0>;
        // 其他所需属性...
    };
};
 No newline at end of file
+14 −0
Original line number Diff line number Diff line
@@ -59,3 +59,17 @@ CONFIG_UART_STM32=y # STM32 UART 驱动

# CONFIG_HAS_STM32CUBE=y
# CONFIG_USE_STM32_HAL_DMA=y
CONFIG_SPI=y
CONFIG_SPI_STM32=y

#
# Device Drivers
#
CONFIG_SENSOR=y
CONFIG_ADXL345_TRIGGER_NONE=y
CONFIG_BMI08X=y
CONFIG_BMI08X_ACCEL_TRIGGER_NONE=y
CONFIG_BMI08X_GYRO_TRIGGER_NONE=y
# CONFIG_BMI08X_GYRO_TRIGGER_GLOBAL_THREAD is not set
# CONFIG_BMI08X_GYRO_TRIGGER_OWN_THREAD is not set
CONFIG_BMI08X_I2C_WRITE_BURST_SIZE=16
 No newline at end of file
Loading