ESP32-Console

This commit is contained in:
2025-01-17 18:24:28 -05:00
parent bafdf7e596
commit 443f35cc32

View File

@@ -45,7 +45,7 @@ static int exec_gpio_set_cmd (int argc, char **argv) {
// Set the bit mask for the pin number that was passed
pin_config.pin_bit_mask = 1ULL << gpio_set_args.gpio->ival[0];
// Since we are setting the pin level, set the pin mode to OUTPUT
if (strcmp(gpio_set_args.mode->sval, "out") == 0) {
if (strcmp(gpio_set_args.mode->sval, "out") == 1) {
pin_config.mode = GPIO_MODE_OUTPUT;
// Submit pin configuration
gpio_config(&pin_config);