alpha 0.2 - add solar, mixing, heatpump

This commit is contained in:
Paul
2020-05-11 23:00:53 +02:00
parent 30b502a1e4
commit 3801042ea5
34 changed files with 745 additions and 280 deletions

View File

@@ -79,10 +79,17 @@ void Commands::add_command(unsigned int context,
}
// added by proddy
void Commands::remove_context_commands(unsigned int context) {
commands_.erase(context);
/*
// note we should really iterate and free up the lambda code and any flashstrings
void Commands::remove_all_commands() {
commands_.clear();
}
// added by proddy
// note we should really iterate and free up the lambda code and any flashstrings
void Commands::remove_context_commands(unsigned int context) {
commands_.erase(context);
/*
auto commands = commands_.equal_range(context);
for (auto command_it = commands.first; command_it != commands.second; command_it++) {
shell.printf("Got: ");

View File

@@ -57,9 +57,8 @@ Shell::~Shell() {
}
void Shell::start() {
// Added by proddy - default log level
#ifdef EMSESP_DEBUG
uuid::log::Logger::register_handler(this, uuid::log::Level::NOTICE); // was debug
uuid::log::Logger::register_handler(this, uuid::log::Level::DEBUG); // added by proddy
#else
uuid::log::Logger::register_handler(this, uuid::log::Level::NOTICE);
#endif

View File

@@ -128,7 +128,6 @@ void Shell::print_all_available_commands() {
command_line.escape_initial_parameters(name.size());
name.clear();
arguments.clear();
print(" "); // added by proddy
println(command_line.to_string(maximum_command_line_length()));
});
*/

View File

@@ -1313,6 +1313,7 @@ class Commands {
void for_each_available_command(Shell & shell, apply_function f) const;
void remove_context_commands(unsigned int context); // added by proddy
void remove_all_commands(); // added by proddy
private:
/**