Data Types In GNU Radio

Hi,

I am working on a project on Cognitive radios. I want to achieve
real-time transmission n reception of audio between two USRP boards. The
biggest problems i am facing are in designing the flow graphs because of
data type mis matches. For example i am taking the audio input from
microphone and its Float type but blocks like modulation and
chunks_to_symbols do not accept float type data. I have tried to use the
float_to_char bloack to accomplish the necessary conversion but
unfortunately it didnt work.

Another question is “Are the float_to_char and char_to_float bloacks bot
exactly reciprocal of each other??? (coz after passing through both
these bloacks the original float signal wasnt recovered) Similar is the
case with float_to_short and short_to_float blocks…”

Kindly guide me how i should get rid of this data type issue coz alot of
my time is getting wasted just in resolving it…

Looking forward to your help…

Regards

Fatima Af wrote:

Regards

You probably need to adjust for the difference in dynamic range. Float’s
give you 32-bits and chars are only 8-bits, so you will likely be
clipping a lot. You need to understand the data types to convert from
the floating-point representation to a PCM representation that you can
then split into chunks for the modulators to handle.

I you want to know if the two blocks are reciprocals or each other, you
can always look at the code. Neither of these blocks are very
complicated.

Tom

Tom R. wrote:

I you want to know if the two blocks are reciprocals or each other, you
can always look at the code. Neither of these blocks are very
complicated.

Tom

Sir,
I have tried using the float_to_char block and char_to_float bloack
simultaneously and tried to listen to sound after passing through them.
Nothing could be heard. This shows that the clipping has caused data
loss which could not be recovered. What else approach could you please
suggest to apply QAM modulation on float values?

Secondly, sir i m trying to figure out parameters which are easily
configurable for SDR waveforms. i think ill b working on output power,
modulation scheme, modulation index, frequency, bandwidth etc. what more
parameters can be incorporated?

and please also guide me as WHAT IS THE DIFFERENCE BETWEEN
gr.hier_block2 AND gr.top_block…

I’ll be grateful for your help… Thanks

Tom R. wrote:

Fatima Af wrote:

Regards

You probably need to adjust for the difference in dynamic range. Float’s
give you 32-bits and chars are only 8-bits, so you will likely be
clipping a lot. You need to understand the data types to convert from
the floating-point representation to a PCM representation that you can
then split into chunks for the modulators to handle.

I you want to know if the two blocks are reciprocals or each other, you
can always look at the code. Neither of these blocks are very
complicated.
Tom