mirror of
https://github.com/MrUnknownDE/OpenIris-ESPIDF.git
synced 2026-04-19 06:23:44 +02:00
Fix getLEDCurrentCommand after rebase, cleanup todos, add current monitoring to setup script
This commit is contained in:
@@ -212,12 +212,7 @@ CommandResult getLEDCurrentCommand(std::shared_ptr<DependencyRegistry> registry)
|
||||
return CommandResult::getErrorResult("MonitoringManager unavailable");
|
||||
}
|
||||
float ma = mon->getCurrentMilliAmps();
|
||||
const auto json = nlohmann::json
|
||||
{
|
||||
{
|
||||
"led_current_ma", std::format("{:.3f}", static_cast<double>(ma))
|
||||
}
|
||||
}
|
||||
const auto json = nlohmann::json{{"led_current_ma", std::format("{:.3f}", static_cast<double>(ma))}};
|
||||
return CommandResult::getSuccessResult(json);
|
||||
#else
|
||||
return CommandResult::getErrorResult("Monitoring disabled");
|
||||
|
||||
Reference in New Issue
Block a user