Skip to content

Commit 2ad2f49

Browse files
Merge pull request #10984 from sensei-hacker/display_default_i2c
better default display i2c bus
2 parents c116982 + c8ea6ba commit 2ad2f49

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/main/target/common_hardware.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,12 @@
426426

427427
#if defined(USE_OLED_UG2864)
428428
#if !defined(UG2864_I2C_BUS)
429-
#define UG2864_I2C_BUS BUS_I2C1
429+
#ifdef MAG_I2C_BUS
430+
#define UG2864_I2C_BUS MAG_I2C_BUS
431+
#else
432+
#define UG2864_I2C_BUS DEFAULT_I2C_BUS
433+
#endif
434+
430435
#endif
431436
BUSDEV_REGISTER_I2C(busdev_ug2864, DEVHW_UG2864, UG2864_I2C_BUS, 0x3C, NONE, DEVFLAGS_NONE, 0);
432437
#endif

0 commit comments

Comments
 (0)