# Variable Delay Error

**URL:** <https://www.ruby-forum.com/t/variable-delay-error/238397>\
**Category:** GNU Radio\
**Created:** [January 8, 2014, 1:37pm UTC](https://www.ruby-forum.com/t/variable-delay-error/238397 "2014-01-08T13:37:22Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Detlef\_R](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/58f4c7/32.png) [@Detlef\_R](https://www.ruby-forum.com/u/Detlef_R)\
**Post date:** [January 8, 2014, 1:37pm UTC](https://www.ruby-forum.com/t/variable-delay-error/238397/1 "2014-01-08T13:37:22Z")

</div>

* * *

Discuss-gnuradio mailing list  
removed\_email\_address@domain.invalid  
[https://lists.gnu.org/mailman/listinfo/discuss-gnuradio](https://lists.gnu.org/mailman/listinfo/discuss-gnuradio)

---

<div class="post-metadata">

**Author:** ![guerra](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/bb73d2/32.png) [@guerra](https://www.ruby-forum.com/u/guerra)\
**Post date:** [January 8, 2014, 3:25pm UTC](https://www.ruby-forum.com/t/variable-delay-error/238397/2 "2014-01-08T15:25:28Z")

</div>

On Wed, Jan 8, 2014 at 7:34 AM, Antnio G. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Hi all,  
> I’m trying to make a delay on a signal with a variable delay with a WX GUI  
> Slider. When i run the simulation and try to add a delay on a sinusoidal  
> signal it gives me this error:

This is a problem with typing between Python and C++. The delay block  
wants  
(demands, really) an integer value, but your slider is passing back a  
float. In the delay block, cast it as “int(delay\_slider)”.

Also, you can use the delay block from GNU Radio; it allows variable  
delays. There’s nothing wrong with using the blocks from gr-baz, but I  
would recommend you use blocks that are directly part of GNU Radio when  
they are available. Mostly because more of the community will be more  
familiar with them.

Tom
