Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem


Loading

Tickless Idle and Software Timer Issue

Posted by tarun-patel on October 5, 2015

I am using FreeRTOS 8.2.2. Same issue is present in FreeRTOS 8.2.1 as well.

Please find my project scenario below.

I am using Tickles Idle mode for extra power saving.

I have two tasks. Task A creates a software timer (autoreload) using xTimerCreate call. This timer will expire at every 100 tick and call it callback function. Task B will be called at every 2000 tick as I blocked it by vTaskDelay function.

Now, I am expecting controlller will be wakeup from Tickless Idle mode at every 100 tick and do its job.

However, as per my practical expriement, I am getting 100 tick xExpectedIdleTime most of the time. However, some times I am getting 2000 tick xExpectedIdleTime instead of 100 tick.

What will be the reason behind this?

Thanks, Tarun


Tickless Idle and Software Timer Issue

Posted by rtel on October 5, 2015

If the timer is auto reload then I would not expect a 2000 tick delay - could you please create an example project that demonstrates this behaviour and send it to me a r [dot] barry at FreeRTOS [dot] org. Make the project as small as possible so it doesn't do anything else other than demonstrate this behaviour.

Also - which chip and compiler are you using, and are you using a tickless idle implementation provided by ourselves or one that you provided yourself. Finally, is the priority of the timer task set to (configMAX_PRIORITIES - 1)? If not, what is it set to?

Regards.


Tickless Idle and Software Timer Issue

Posted by tarun-patel on October 5, 2015

Thanks for prompt response.

Yes timer is auto reload and that's why I am getting 100 tick xExpectedIdleTime most of the time. I will create a demo project and email you by tomorrow.

I am using Toshiba's TZ1001 (ARM Cortex M4F) chip and Keil uVision compiler (V5.05 update 2 (build 169)). We have implemented tickles idle ourselves. I mistakenly taken timer task priotity to configMAXPRIORITIES. I have corrected it to (configMAXPRIORITIES - 1) that however problem is still exist.

Thanks, Tarun


Tickless Idle and Software Timer Issue

Posted by tarun-patel on October 8, 2015

I have prepared a demo project. However, I am not able to reproduce this behaviour in that project. So I derived there is something in my project's energy measurement library which creates this issue.

I have tried loads of workaround. However, when I enabled preemption using configUSE_PREEMPTION macro, the problem is resolved. I don't know why.

Do you have any idea how this be possible? Meanwhile, I am digging my project for the reason.

Thanks, Tarun


Tickless Idle and Software Timer Issue

Posted by rtel on October 8, 2015

I have tried loads of workaround. However, when I enabled preemption using configUSE_PREEMPTION macro, the problem is resolved. I don't know why.

I don't think you mentioned you weren't using pre-emption before. I have never tried tickless idle without preemption before.


[ Back to the top ]    [ About FreeRTOS ]    [ Privacy ]    [ Sitemap ]    [ ]


Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

NXP tweet showing LPC5500 (ARMv8-M Cortex-M33) running FreeRTOS.

Meet Richard Barry and learn about running FreeRTOS on RISC-V at FOSDEM 2019

Version 10.1.1 of the FreeRTOS kernel is available for immediate download. MIT licensed.

View a recording of the "OTA Update Security and Reliability" webinar, presented by TI and AWS.


Careers

FreeRTOS and other embedded software careers at AWS.



FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Espressif ESP32

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Renesas

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS

Xilinx Microblaze and Zynq partner