This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
Hello TI-Support,
I would like to reduce/halve the duration of the time slices/ticks. Unfortunately, if I change the following values, the lwip-freertos-library can no longer be compiled.
FreeRTOSConfig.h:
#define configTICK_RATE_HZ (2000)
alpha_delta_lru.syscfg:
Tick Periode (usec) : 500
I am currently using the following versions :
TI CCS : 12.7.0
SysConfig : 1.20.0
MCU+ SDK for AM243x : 9.2.0.50
Error messages :
Compiling: lwip-freertos.am243x.r5f.ti-arm-clang.debug.lib: /home/auto/ti/mcu_plus_sdk_am243x_09_02_00_50/source/networking/lwip/lwip-port/freertos/src/sys_arch.c
/home/auto/ti/mcu_plus_sdk_am243x_09_02_00_50/source/networking/lwip/lwip-port/freertos/src/sys_arch.c:204:37: error: division by zero is undefined [-Werror,-Wdivision-by-zero]
TickType_t delay_ticks = delay_ms / portTICK_RATE_MS;
^ ~~~~~~~~~~~~~~~~
/home/auto/ti/mcu_plus_sdk_am243x_09_02_00_50/source/networking/lwip/lwip-port/freertos/src/sys_arch.c:306:43: error: division by zero is undefined [-Werror,-Wdivision-by-zero]
TickType_t timeout_ticks = timeout_ms / portTICK_RATE_MS;
^ ~~~~~~~~~~~~~~~~
/home/auto/ti/mcu_plus_sdk_am243x_09_02_00_50/source/networking/lwip/lwip-port/freertos/src/sys_arch.c:413:43: error: division by zero is undefined [-Werror,-Wdivision-by-zero]
TickType_t timeout_ticks = timeout_ms / portTICK_RATE_MS;
^ ~~~~~~~~~~~~~~~~
3 errors generated.
gmake[2]: *** [makefile.stack_freertos.am243x.r5f.ti-arm-clang:242: sys_arch.obj] Error 1
gmake[1]: *** [makefile.am243x:691: lwip-freertos_r5f.ti-arm-clang] Error 2
gmake: *** [makefile:68: libs] Error 2
I think with an older MCU+ SDK I was able to make these changes without any problems. Did I miss something?
Best regards,
Thomas
Hi Thomas Breitung,
Thanks for your query.
I will check on this and get back to you.
I think with an older MCU+ SDK I was able to make these changes without any problems.
Which SDK are you referring here ?
Regards
Ashwani
Hi Ashwani,
I think this was probably version MCU+ SDK 09.00.00.35.
Best regards,
Thomas
Hi Thomas,
Can you please provide step by step changes, I need to try on my setup?
I will follow the steps and build LwIP library.
Expectation:
It should give above error for SDK 9.2 but not for SDK 9.0.
correct?
Regards
Ashwani
Hi Ashwani,
the main difference was that the SDK 9.0 could be compiled without compiler errors after adapting the above mentioned changes. Now the question would be, is it possible in principle to set tick periods smaller than 1 ms or is this not possible from a TI RTOS point of view?
Best regards,
Thomas
TI RTOS point of view?
It is FreeRTOS, provides a execution environment consisting of tasks, semaphores, timers, see https://www.freertos.org/RTOS.html
Limited POSIX APIs with FreeRTOS underneath, provides pthreads, mqueue, semaphore, see https://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_POSIX/index.html
to set tick periods smaller than 1 ms
For SW timers using "ClockP_ api", can t go less than 1 ms (tick period if RTOS).
For HW timers, we can set to any number.
Regards
Ashwani