we need TLE8888 driver #714
This commit is contained in:
parent
878b75f575
commit
b4077d72ba
|
@ -319,7 +319,7 @@ void setTle8888TestConfiguration(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
||||||
engineConfiguration->crankingInjectionMode = IM_SEQUENTIAL;
|
engineConfiguration->crankingInjectionMode = IM_SEQUENTIAL;
|
||||||
|
|
||||||
engineConfiguration->tle8888_cs = GPIOD_5;
|
engineConfiguration->tle8888_cs = GPIOD_5;
|
||||||
engineConfiguration->tle8888_csPinMode = OM_OPENDRAIN;
|
// engineConfiguration->tle8888_csPinMode = OM_OPENDRAIN;
|
||||||
engineConfiguration->directSelfStimulation = true;
|
engineConfiguration->directSelfStimulation = true;
|
||||||
|
|
||||||
boardConfiguration->ignitionPins[0] = GPIOG_3;
|
boardConfiguration->ignitionPins[0] = GPIOG_3;
|
||||||
|
@ -333,12 +333,13 @@ void setTle8888TestConfiguration(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
||||||
|
|
||||||
engineConfiguration->tle8888spiDevice = SPI_DEVICE_1;
|
engineConfiguration->tle8888spiDevice = SPI_DEVICE_1;
|
||||||
|
|
||||||
|
// PB3 is nicely both SWO and SPI1 SCK so logic analyzer could be used on SWO header
|
||||||
boardConfiguration->is_enabled_spi_1 = true;
|
boardConfiguration->is_enabled_spi_1 = true;
|
||||||
engineConfiguration->debugMode = DBG_TLE8888;
|
engineConfiguration->debugMode = DBG_TLE8888;
|
||||||
|
|
||||||
engineConfiguration->spi1MosiMode = PO_OPENDRAIN;
|
// engineConfiguration->spi1MosiMode = PO_OPENDRAIN;
|
||||||
engineConfiguration->spi1MisoMode = PO_PULLUP;
|
// engineConfiguration->spi1MisoMode = PO_PULLUP;
|
||||||
engineConfiguration->spi1SckMode = PO_OPENDRAIN;
|
// engineConfiguration->spi1SckMode = PO_OPENDRAIN;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -113,8 +113,8 @@ static int tle8888_spi_rw(struct tle8888_priv *chip, uint16_t tx, uint16_t *rx)
|
||||||
/* Slave Select assertion. */
|
/* Slave Select assertion. */
|
||||||
spiSelect(spi);
|
spiSelect(spi);
|
||||||
/* Atomic transfer operations. */
|
/* Atomic transfer operations. */
|
||||||
// todo 16 bit for F4? rxb = spiPolledExchange(spi, tx);
|
rxb = spiPolledExchange(spi, tx);
|
||||||
spiExchange(spi, 2, &tx, &rxb);
|
//spiExchange(spi, 2, &tx, &rxb); 8 bit version just in case?
|
||||||
/* Slave Select de-assertion. */
|
/* Slave Select de-assertion. */
|
||||||
spiUnselect(spi);
|
spiUnselect(spi);
|
||||||
/* Ownership release. */
|
/* Ownership release. */
|
||||||
|
|
Loading…
Reference in New Issue