mirror of https://github.com/FOME-Tech/fome-fw.git
reduce flash footprint by smarter code generation #4163
This commit is contained in:
parent
03fa461ac8
commit
764c064656
|
@ -38,8 +38,6 @@ T* findPair(const char *name, T array[TCount], size_t count) {
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
plain_get_float_s * findFloat(const char *name);
|
||||
|
||||
float getConfigValueByName(const char *name);
|
||||
void setConfigValueByName(const char *name, float value);
|
||||
float getOutputValueByName(const char *name);
|
||||
|
|
|
@ -844,10 +844,9 @@ static void getValue(const char *paramStr) {
|
|||
}
|
||||
|
||||
{
|
||||
plain_get_float_s * known = findFloat(paramStr);
|
||||
if (known != nullptr) {
|
||||
float value = *known->value;
|
||||
efiPrintf("%s value: %.2f", known->token, value);
|
||||
float value = getConfigValueByName(paramStr);
|
||||
if (value != EFI_ERROR_CODE) {
|
||||
efiPrintf("%s value: %.2f", paramStr, value);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue