Allow BLE transmit power up to 20 on newer ESP32 models

This commit is contained in:
iranl
2025-01-28 15:36:37 +01:00
parent c436757c23
commit 0b96ec6b2c
4 changed files with 55 additions and 1 deletions

View File

@@ -82,7 +82,30 @@ void NukiWrapper::readSettings()
if(pwrLvl >= 9)
{
#if defined(CONFIG_IDF_TARGET_ESP32)
powerLevel = ESP_PWR_LVL_P9;
#else
if(pwrLvl >= 20)
{
powerLevel = ESP_PWR_LVL_P20;
}
else if(pwrLvl >= 18)
{
powerLevel = ESP_PWR_LVL_P18;
}
else if(pwrLvl >= 15)
{
powerLevel = ESP_PWR_LVL_P15;
}
else if(pwrLvl >= 12)
{
powerLevel = ESP_PWR_LVL_P12;
}
else
{
powerLevel = ESP_PWR_LVL_P9;
}
#endif
}
else if(pwrLvl >= 6)
{