mirror of
https://github.com/espressif/esp-idf
synced 2025-03-09 17:19:09 -04:00
fix(modbus): Fix the mode setup in modbus slave
https://github.com/espressif/esp-idf/pull/14878
This commit is contained in:
parent
32b86e8dcd
commit
395ad7cd63
@ -99,7 +99,7 @@ void app_main(void)
|
|||||||
|
|
||||||
ESP_ERROR_CHECK(mbc_slave_init(MB_PORT_SERIAL_SLAVE, &mbc_slave_handler)); // Initialization of Modbus controller
|
ESP_ERROR_CHECK(mbc_slave_init(MB_PORT_SERIAL_SLAVE, &mbc_slave_handler)); // Initialization of Modbus controller
|
||||||
|
|
||||||
// Setup communication parameters and start stack
|
// Setup communication mode and start stack
|
||||||
#if CONFIG_MB_COMM_MODE_ASCII
|
#if CONFIG_MB_COMM_MODE_ASCII
|
||||||
comm_info.mode = MB_MODE_ASCII;
|
comm_info.mode = MB_MODE_ASCII;
|
||||||
#elif CONFIG_MB_COMM_MODE_RTU
|
#elif CONFIG_MB_COMM_MODE_RTU
|
||||||
|
Loading…
x
Reference in New Issue
Block a user