This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

RTX osTimerStart() interval short

Hi! I'm trying to learn osTimerStart(), \ble_app_hrs_rtx. Compiling was successful, and it is working. If I set the timer interval shorter than 25 ms, the timer cycle becomes abnormally short. The cycle of other timers also becomes short.Is this a specification?

For example //#define RR_INTERVAL_INTERVAL 300 #define RR_INTERVAL_INTERVAL 10

Parents
  • I am using MDK-ARM , s130_nrf51_2.0.0-7, Example \ ble_app_hrs_rtx \ pca10028 \ s130 \ arm5 \ ble_app_hrs_rtx_s130_pca10028.uvprojx

    Usually, rr_interval_timeout_handler() is a 300 ms repeating timer. However, if I create a short cycle timer in main () as below, the cycle will be 264 ms.

    OsTimer1_id = osTimerCreate (osTimer (osTimer1), osTimerPeriodic, NULL);
    OsTimerStart (osTimer1_id, 10);
    

    I found, This phenomenon does not occur if I rewritte os_idle_demon () to "for (;;) ;".

Reply
  • I am using MDK-ARM , s130_nrf51_2.0.0-7, Example \ ble_app_hrs_rtx \ pca10028 \ s130 \ arm5 \ ble_app_hrs_rtx_s130_pca10028.uvprojx

    Usually, rr_interval_timeout_handler() is a 300 ms repeating timer. However, if I create a short cycle timer in main () as below, the cycle will be 264 ms.

    OsTimer1_id = osTimerCreate (osTimer (osTimer1), osTimerPeriodic, NULL);
    OsTimerStart (osTimer1_id, 10);
    

    I found, This phenomenon does not occur if I rewritte os_idle_demon () to "for (;;) ;".

Children
No Data
Related