fix(esp_modem): Update CMUX example to use CMUX mode automatically

This commit is contained in:
David Cermak
2022-06-06 21:08:41 +02:00
parent 3fd4391c38
commit 58a0b57e12
2 changed files with 3 additions and 3 deletions

View File

@ -87,10 +87,10 @@ extern "C" void app_main(void)
}
#endif
if (dce->set_mode(esp_modem::modem_mode::CMUX_MODE) && dce->set_mode(esp_modem::modem_mode::DATA_MODE)) {
if (dce->set_mode(esp_modem::modem_mode::CMUX_MODE)) {
std::cout << "Modem has correctly entered multiplexed command/data mode" << std::endl;
} else {
ESP_LOGE(TAG, "Failed to configure desired mode... exiting");
ESP_LOGE(TAG, "Failed to configure multiplexed command mode... exiting");
return;
}

View File

@ -94,7 +94,7 @@ private:
void send_disc(size_t i); /*!< Sending closing request for each virtual terminal */
void close_down(); /*!< Close up the control terminla (term=0) */
bool exit_cmux_protocol(); /*!< Sequence of exit of all virtual terms and control term */
bool on_cmux(uint8_t *data, size_t len); /*!< Called from terminal layer when raw CMUX protocol data available */
bool on_cmux_data(uint8_t *data, size_t len); /*!< Called from terminal layer when raw CMUX protocol data available */
struct CMuxFrame; /*!< Forward declare the Frame struct, used in protocol decoders */
/**