# Timer Issue 

**URL:** <https://forums.freertos.org/t/timer-issue/7415>\
**Category:** Kernel\
**Created:** [September 13, 2018, 8:58am UTC](https://forums.freertos.org/t/timer-issue/7415 "2018-09-13T08:58:22Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [September 13, 2018, 8:58am UTC](https://forums.freertos.org/t/timer-issue/7415/1 "2018-09-13T08:58:22Z")

</div>

**[mbedded](https://sourceforge.net/u/mbedded/)** wrote on [Thursday, September 13, 2018](https://sourceforge.net/p/freertos/discussion/382005/thread/152dea30/#8b11):

Using the example  
[https://www.freertos.org/FreeRTOS-timers-xTimerCreate.html](https://www.freertos.org/FreeRTOS-timers-xTimerCreate.html)

I get an eror:  
“error: ‘pxTimer’ was not declared in this scope xTimerStop(pxTimer, 0)” in the function “vTimerCallback”

Is there a configuration somewhere I need to set ?

I’m using the Arduino\_FreeRTOS v10.0.0

---

<div class="post-metadata">

**Author:** ![rtel](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/rtel/32/31_2.png) [@rtel](https://forums.freertos.org/u/rtel)\
**Post date:** [September 13, 2018, 3:26pm UTC](https://forums.freertos.org/t/timer-issue/7415/2 "2018-09-13T15:26:46Z")

</div>

**[rtel](https://sourceforge.net/u/rtel/)** wrote on [Thursday, September 13, 2018](https://sourceforge.net/p/freertos/discussion/382005/thread/152dea30/#8b11/da57):

pxTimer is just a variable, and if you cut and paste the example from  
the webpage then it is not necessarily complete and may make assumptions  
about objects being created outside of the shown source code. In this  
case however it just looks like a mistake in the code as the comments  
refer to pxTimer being a function parameter, whereas the parameter is  
actually called xTimer (without the ‘p’).

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [September 14, 2018, 1:27am UTC](https://forums.freertos.org/t/timer-issue/7415/3 "2018-09-14T01:27:37Z")

</div>

**[mbedded](https://sourceforge.net/u/mbedded/)** wrote on [Friday, September 14, 2018](https://sourceforge.net/p/freertos/discussion/382005/thread/152dea30/#80bd):

Thanks, it compiles now.

What (maximum) size does xTimerCreate return ?  
In the example you have used a “long”

And what does xTimerStart return ?  
It says pdPASS/pdFAIL, it that a boolean ?

Cheers

---

<div class="post-metadata">

**Author:** ![rtel](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/rtel/32/31_2.png) [@rtel](https://forums.freertos.org/u/rtel)\
**Post date:** [September 14, 2018, 2:01am UTC](https://forums.freertos.org/t/timer-issue/7415/4 "2018-09-14T02:01:16Z")

</div>

**[rtel](https://sourceforge.net/u/rtel/)** wrote on [Friday, September 14, 2018](https://sourceforge.net/p/freertos/discussion/382005/thread/152dea30/#80bd/a06d):

> What (maximum) size does xTimerCreate return ?  
> In the example you have used a “long”

Does it? It should return an TimerHandle\_t, which underneath is a  
pointer (normally 32-bits on 32-bit architecture).

> And what does xTimerStart return ?  
> It says pdPASS/pdFAIL, it that a boolean ?

[FreeRTOS - Small footprint, open source software for microcontrollers - FreeRTOS xTimerStart() timer API function description](https://www.freertos.org/FreeRTOS-timers-xTimerStart.html) Returns a  
BaseType\_t, which is the natural word size of the architecture depending  
on the architecture. These are used in place of bools - which are not  
used anywhere in the code as they are not portable back to older C  
standards.

---

<div class="post-metadata">

**Author:** ![system](https://d2v6vdsk2p900z.cloudfront.net/original/1X/7fc8fdb729c645aab5b20282bbe34e57cb407be6.jpeg) [@system](https://forums.freertos.org/u/system)\
**Post date:** [September 15, 2018, 8:42pm UTC](https://forums.freertos.org/t/timer-issue/7415/5 "2018-09-15T20:42:54Z")

</div>

**[mbedded](https://sourceforge.net/u/mbedded/)** wrote on [Saturday, September 15, 2018](https://sourceforge.net/p/freertos/discussion/382005/thread/152dea30/#59b3):

Churs bro 🙂
