1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-12 19:10:32 +03:00

REFACTOR: missed trait defines (#14435)

This commit is contained in:
Jay Blackman 2025-06-08 08:44:11 +10:00 committed by GitHub
parent 0bb1254ee8
commit 3a70ece364
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -56,13 +56,13 @@ void i2cHardwareConfigure(const i2cConfig_t *i2cConfig)
for (int pindex = 0 ; pindex < I2C_PIN_SEL_MAX ; pindex++) {
if (i2cConfig[device].ioTagScl == hardware->sclPins[pindex].ioTag) {
pDev->scl = IOGetByTag(i2cConfig[device].ioTagScl);
#if defined(STM32F4) || defined(STM32H7) || defined(STM32G4) || defined(AT32F4) || defined(APM32F4)
#if I2C_TRAIT_AF_PIN
pDev->sclAF = hardware->sclPins[pindex].af;
#endif
}
if (i2cConfig[device].ioTagSda == hardware->sdaPins[pindex].ioTag) {
pDev->sda = IOGetByTag(i2cConfig[device].ioTagSda);
#if defined(STM32F4) || defined(STM32H7) || defined(STM32G4) || defined(AT32F4) || defined(APM32F4)
#if I2C_TRAIT_AF_PIN
pDev->sdaAF = hardware->sdaPins[pindex].af;
#endif
}