~aleteoryx/muditaos

a3d6c7987d7b15be84eb51260d8cd081afe77d23 — Maciej-Mudita 5 years ago 3a79343
[EGD-5186] Change minimum CPU frequency to 132 MHz

Temporary minimum CPU frequency limitation
2 files changed, 4 insertions(+), 12 deletions(-)

M changelog.md
M module-sys/SystemManager/PowerManager.cpp
M changelog.md => changelog.md +1 -0
@@ 12,6 12,7 @@

* Input keyboard language files parser from KBD to JSON.
* Input language files are now loaded based on files in "profiles" folder.
* Minimum CPU frequency is now 132 MHz

### Fixed


M module-sys/SystemManager/PowerManager.cpp => module-sys/SystemManager/PowerManager.cpp +3 -12
@@ 79,24 79,15 @@ namespace sys
        const auto freq = lowPowerControl->GetCurrentFrequency();
        auto level      = bsp::LowPowerMode::CpuFrequency::Level_1;

        // We temporarily limit the minimum CPU frequency
        // due to problems with the UART of the GSM modem
        switch (freq) {
        case bsp::LowPowerMode::CpuFrequency::Level_6:
            level = bsp::LowPowerMode::CpuFrequency::Level_5;
            break;
        case bsp::LowPowerMode::CpuFrequency::Level_5:
        default:
            level = bsp::LowPowerMode::CpuFrequency::Level_4;
            break;
        case bsp::LowPowerMode::CpuFrequency::Level_4:
            level = bsp::LowPowerMode::CpuFrequency::Level_3;
            break;
        case bsp::LowPowerMode::CpuFrequency::Level_3:
            level = bsp::LowPowerMode::CpuFrequency::Level_2;
            break;
        case bsp::LowPowerMode::CpuFrequency::Level_2:
            level = bsp::LowPowerMode::CpuFrequency::Level_1;
            break;
        case bsp::LowPowerMode::CpuFrequency::Level_1:
            break;
        }

        // decrease frequency first