# Task: block on queue & semaphore

**URL:** <https://forums.freertos.org/t/task-block-on-queue-semaphore/323>\
**Category:** Kernel\
**Created:** [May 3, 2009, 9:42pm UTC](https://forums.freertos.org/t/task-block-on-queue-semaphore/323 "2009-05-03T21:42:27Z")\
**Posts on this page:** 1\
**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:** [May 3, 2009, 9:42pm UTC](https://forums.freertos.org/t/task-block-on-queue-semaphore/323/1 "2009-05-03T21:42:27Z")

</div>

**[alwynne](https://sourceforge.net/u/alwynne/)** wrote on [Sunday, May 03, 2009](https://sourceforge.net/p/freertos/discussion/382005/thread/0e3e4020/#e976):

Is it possible to have a task which blocks on both a queue and a semaphore?

I have a pin interrupt (from a tacho). It puts the current value of xTicks onto a queue. The task blocks on this queue, and counts pulses and total accumulated time.  
The tick interrupt sets a semaphore at exactly one second. At this semaphore, the tacho task needs to send its accumulated data to a queue for another task.

Amanda
