33810 CPHA or not?! fix #6538

only:hellen154hyundai_f7
This commit is contained in:
Andrey 2024-05-23 11:32:03 -04:00
parent a7c7d3dcac
commit b788ff83ac
2 changed files with 6 additions and 2 deletions

View File

@ -151,8 +151,6 @@ static const struct mc33810_config mc33810 = {
// ((3 << SPI_CR1_BR_Pos) & SPI_CR1_BR) | /* div = 16 */
((0b110 << SPI_CR1_BR_Pos) & SPI_CR1_BR) | /* div = 128 */
SPI_CR1_MSTR |
/* SPI_CR1_CPOL | */ // = 0
SPI_CR1_CPHA | // = 1
0,
.cr2 = SPI_CR2_16BIT_MODE
},

View File

@ -240,7 +240,10 @@ static const struct mc33810_config mc33810_odd = {
((3 << SPI_CR1_BR_Pos) & SPI_CR1_BR) | /* div = 16 */
SPI_CR1_MSTR |
/* SPI_CR1_CPOL | */ // = 0
/*
https://github.com/rusefi/rusefi/issues/6538 says that should be zero
SPI_CR1_CPHA | // = 1
*/
0,
.cr2 = //SPI_CR2_16BIT_MODE |
SPI_CR2_DS_3 | SPI_CR2_DS_2 | SPI_CR2_DS_1 | SPI_CR2_DS_0
@ -276,7 +279,10 @@ static const struct mc33810_config mc33810_even = {
((3 << SPI_CR1_BR_Pos) & SPI_CR1_BR) | /* div = 16 */
SPI_CR1_MSTR |
/* SPI_CR1_CPOL | */ // = 0
/*
https://github.com/rusefi/rusefi/issues/6538 says that should be zero
SPI_CR1_CPHA | // = 1
*/
0,
.cr2 = SPI_CR2_16BIT_MODE
},