# Gnuradio

**URL:** <https://www.ruby-forum.com/t/gnuradio/206507>\
**Category:** GNU Radio\
**Created:** [May 3, 2011, 2:08pm UTC](https://www.ruby-forum.com/t/gnuradio/206507 "2011-05-03T14:08:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![luislavena](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/0ea827/32.png) [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Post date:** [May 3, 2011, 2:08pm UTC](https://www.ruby-forum.com/t/gnuradio/206507/1 "2011-05-03T14:08:08Z")

</div>

Hello,

I am recently working with gnuradio’s tx\_samples.cc and USRP2. I have  
input  
files that are .sc type, which are written and saved on Matlab. I have a  
question though.  
I’ve noticed that signals in the input files before being saved to .sc  
type  
are being scaled, for example:

signal = sin(A);  
scale = 10000;

new\_signal = signal\*scale;

frwite(…)

Why do we need to use this scaling factor?

Thanks!

---

<div class="post-metadata">

**Author:** ![Mantas\_Juskauskas](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/8491ac/32.png) [@Mantas\_Juskauskas](https://www.ruby-forum.com/u/Mantas_Juskauskas)\
**Post date:** [May 5, 2011, 9:19am UTC](https://www.ruby-forum.com/t/gnuradio/206507/2 "2011-05-05T09:19:16Z")

</div>

On Tue, May 3, 2011 at 2:07 PM, Mantas Juskauskas  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> new\_signal = signal\*scale;
> 
> frwite(…)
> 
> Why do we need to use this scaling factor?
> 
> Thanks!

This is a result of the change from float to fixed point representation  
as  
the signals are sent over the wire. When using the tx\_samples program,  
it’s  
assuming shorts (16 bit I&Q), but this means that if you send a 1.0, it  
becomes a 1 out of a scale of ±32k. The copier here doesn’t do any  
scaling  
(unlike the tx\_32fc transmit function, which does the scaling for you).

Tom
