Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Shell class init method #219

Merged
merged 1 commit into from
Feb 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion andino_firmware/src/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ void App::setup() {
right_pid_controller_.reset(right_encoder_.read());

// Initialize command shell.
shell_.init(Serial);
shell_.begin(Serial);
shell_.set_default_callback(cmd_unknown_cb);
shell_.register_command(Commands::kReadAnalogGpio, cmd_read_analog_gpio_cb);
shell_.register_command(Commands::kReadDigitalGpio, cmd_read_digital_gpio_cb);
Expand Down
2 changes: 1 addition & 1 deletion andino_firmware/src/shell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

namespace andino {

void Shell::init(Stream& stream) { stream_ = &stream; }
void Shell::begin(Stream& stream) { stream_ = &stream; }

void Shell::set_default_callback(CommandCallback callback) { default_callback_ = callback; }

Expand Down
2 changes: 1 addition & 1 deletion andino_firmware/src/shell.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class Shell {
/// @brief Initializes the shell.
///
/// @param stream Data stream.
void init(Stream& stream);
void begin(Stream& stream);

/// @brief Sets the default callback for unknown commands.
///
Expand Down
Loading