Page 1 of 1

deprecated function how to solve it

Posted: Fri Apr 10, 2026 8:04 pm
by pdecaro
Good evening, I'm having this problem. When I recompile a program that was working perfectly, I get this error for a deprecated function called "esp_lcd_touch_get_coordinates." It tells me to replace it with "esp_lcd_touch_get_data-Instead." I replace the name of this new function in the program, but I still get the error.
Can you please help me solve this problem?
Thank you.



Image

Re: deprecated function how to solve it

Posted: Mon Apr 13, 2026 8:27 am
by MicroController
I replace the name of this new function in the program, but ...
The new function has a different signature than the old one, i.e. it must be called with different arguments. Documentation seems to still be sparse, but here's an example:

Code: Select all

esp_lcd_touch_point_data_t touch_point_data[1];
uint8_t touch_cnt = 0;

ESP_ERROR_CHECK(esp_lcd_touch_get_data(tp, touch_point_data, &touch_cnt, 1));

Re: deprecated function how to solve it

Posted: Tue Apr 14, 2026 11:21 pm
by mbratch
Were you actually getting an error message for the deprecated function or was it a warning message? Usually when a function becomes deprecated, you're given a considerable amount of time to adapt the replacement function(s).

Re: deprecated function how to solve it

Posted: Tue Apr 28, 2026 11:59 am
by nopnop2002
In ESP-IDF V6, the following options may help avoid deprecation-related errors.
This allowed us to temporarily circumvent the deprecation error related to the legacy TWAI driver.
However, it is not guaranteed that all errors can be avoided.
583825747-fd46966b-6a9f-4034-a9e3-b13a75c02bc8.jpg
583825747-fd46966b-6a9f-4034-a9e3-b13a75c02bc8.jpg (159.88 KiB) Viewed 103 times