Skip to content

Commit 6c66584

Browse files
authored
Merge pull request #28 from libdriver/dev
fix: change spi speed
2 parents cb52ad7 + 2756236 commit 6c66584

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## 1.0.9 (2025-04-17)
2+
3+
## Bug Fixes
4+
5+
- change spi speed
6+
17
## 1.0.8 (2025-04-16)
28

39
## Bug Fixes

project/raspberrypi4b/driver/src/raspberrypi4b_driver_bmp390_interface.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ uint8_t bmp390_interface_iic_write(uint8_t addr, uint8_t reg, uint8_t *buf, uint
124124
*/
125125
uint8_t bmp390_interface_spi_init(void)
126126
{
127-
return spi_init(SPI_DEVICE_NAME, &gs_spi_fd, SPI_MODE_TYPE_3, 1000 * 1000 * 2);
127+
return spi_init(SPI_DEVICE_NAME, &gs_spi_fd, SPI_MODE_TYPE_3, 1000 * 1000);
128128
}
129129

130130
/**

project/stm32f407/interface/src/spi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ uint8_t spi_init(spi_mode_t mode)
101101
g_spi_handle.Init.CLKPhase = SPI_PHASE_2EDGE;
102102
}
103103
g_spi_handle.Init.NSS = SPI_NSS_SOFT;
104-
g_spi_handle.Init.BaudRatePrescaler = SPI_BAUDRATEPRESCALER_8;
104+
g_spi_handle.Init.BaudRatePrescaler = SPI_BAUDRATEPRESCALER_32;
105105
g_spi_handle.Init.FirstBit = SPI_FIRSTBIT_MSB;
106106
g_spi_handle.Init.TIMode = SPI_TIMODE_DISABLE;
107107
g_spi_handle.Init.CRCCalculation = SPI_CRCCALCULATION_DISABLE;

0 commit comments

Comments
 (0)