1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-19 14:25:20 +03:00

Introduce per device pin pre-init

This commit is contained in:
jflyper 2018-12-10 04:42:41 +09:00
parent 2e81109be1
commit 9ea1428d11
44 changed files with 219 additions and 201 deletions

View file

@ -40,6 +40,11 @@ static busDevice_t *busdev;
static flashDevice_t flashDevice;
void flashPreInit(const flashConfig_t *flashConfig)
{
spiPreinitRegister(flashConfig->csTag, IOCFG_IPU, 1);
}
// Read chip identification and send it to device detect
bool flashInit(const flashConfig_t *flashConfig)
@ -99,7 +104,7 @@ bool flashInit(const flashConfig_t *flashConfig)
}
#endif
spiPreinitCsByTag(flashConfig->csTag);
spiPreinitByTag(flashConfig->csTag);
return false;
}