explicit ShellCommand(const std::string& program) { boost::regex simpleCommand("^[a-zA-Z]+$"); if (boost::regex_match(program, simpleCommand)) output_ = program; else output_ = escape(program); }
bool Bluetooth_HC05::restoreDefaults(unsigned long timeout) { PGM_STRING_MAPPED_TO_RAM(command, "ORGL"); return simpleCommand(command, 0, timeout); }
bool Bluetooth_HC05::softReset(unsigned long timeout) { PGM_STRING_MAPPED_TO_RAM(reset_cmd, "RESET"); return simpleCommand(reset_cmd, 0, timeout); }