updated i2c timing for L8
This commit is contained in:
parent
d55d7f67b6
commit
2af97fcb7d
|
@ -213,18 +213,35 @@ void Error_Handler(void);
|
|||
|
||||
#endif
|
||||
|
||||
#ifdef STM32WLE5xx
|
||||
|
||||
#define I2C2_SCL_PIN GPIO_PIN_12
|
||||
#define I2C2_SDA_PIN GPIO_PIN_11
|
||||
#define I2C2_SCL_PORT GPIOA
|
||||
#define I2C2_SDA_PORT GPIOA
|
||||
|
||||
// FOR STM32WLE5CCU6 UFQFPN48 PA12 PA11
|
||||
#ifndef STM32WLE5xx
|
||||
#define I2C2_STANDARD_100K 0x00000E14
|
||||
#define I2C2_FAST_400K 0x00000004
|
||||
#define I2C2_FAST_PLUS_1M 0x00000000
|
||||
#endif
|
||||
|
||||
/*
|
||||
* FOR STM32WLE5CCU6 UFQFPN48 PA12 PA11
|
||||
*
|
||||
#define I2C2_STANDARD_100K 0x00000E14
|
||||
#define I2C2_FAST_400K 0x00000004
|
||||
#define I2C2_FAST_PLUS_1M 0x00000000
|
||||
*/
|
||||
|
||||
/*
|
||||
* FOR STM32WL55JCIX UFBGA73 PA12 PA11
|
||||
*/
|
||||
|
||||
#define I2C2_STANDARD_100K 0x10805D88
|
||||
#define I2C2_FAST_400K 0x0090194B
|
||||
#define I2C2_FAST_PLUS_1M 0x00700814
|
||||
|
||||
#if defined(STS_R4)
|
||||
/* IF_SOAP_IN, MEMS_IF_3, PA10 */
|
||||
#define SOAP_STATUS_Pin GPIO_PIN_10
|
||||
|
|
|
@ -43,7 +43,7 @@ void MX_I2C2_Init(void)
|
|||
|
||||
/* USER CODE END I2C2_Init 1 */
|
||||
hi2c2.Instance = I2C2;
|
||||
hi2c2.Init.Timing = I2C2_STANDARD_100K; //I2C2_FAST_400K;
|
||||
hi2c2.Init.Timing = I2C2_FAST_PLUS_1M;
|
||||
hi2c2.Init.OwnAddress1 = 0;
|
||||
hi2c2.Init.AddressingMode = I2C_ADDRESSINGMODE_7BIT;
|
||||
hi2c2.Init.DualAddressMode = I2C_DUALADDRESS_DISABLE;
|
||||
|
|
|
@ -39,8 +39,8 @@
|
|||
* MODULE SELECTION
|
||||
*/
|
||||
//#define USE_OLED_SSD1306
|
||||
#define STS_USE_TOF_VL53L1X
|
||||
#define STS_USE_TOF_VL53L0X 1U
|
||||
//#define STS_USE_TOF_VL53L1X
|
||||
//#define STS_USE_TOF_VL53L0X 1U
|
||||
|
||||
#ifdef STS_R1 /* STS R1 for single roll */
|
||||
#define YUNHORN_STS_R1_ENABLED 1U
|
||||
|
|
Loading…
Reference in New Issue