Forum: GNU Radio Help: How to convert a *.mat file to binary file?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
8cc3398651ba824dc6086010da0d8a20?d=identicon&s=25 slimchao (Guest)
on 2008-11-07 11:08
(Received via mailing list)
Hallo Everyone,

I have generated some samples of a sinesoid from Matlab and want to
convert
it to a binary file and use it as a source signal to the LFTX
daughterboard.
Can you tell me how i do to convert it?

Thanks a lot,

Chao

--
View this message in context:
http://www.nabble.com/Help%3A-How-to-convert-a-*.m...
Sent from the GnuRadio mailing list archive at Nabble.com.
9e8f71d228876b5d390d146fba0c8d78?d=identicon&s=25 Jorg Lotze (Guest)
on 2008-11-07 13:01
(Received via mailing list)
On Fri, 2008-11-07 at 02:06 -0800, slimchao wrote:
> Hallo Everyone,
>
> I have generated some samples of a sinesoid from Matlab and want to convert
> it to a binary file and use it as a source signal to the LFTX daughterboard.
> Can you tell me how i do to convert it?
>
> Thanks a lot,
>
> Chao

Use the MATLAB functions fopen, fwrite, fclose to write your data in
binary format to a file that can be read by gr.file_source. Choose 32bit
floats for real data, write real,imag,real,imag,... for complex data.
The MATLAB manual is your friend. ;)
063614dd3613cfd90b6c86b951fcf2a4?d=identicon&s=25 Karthik Vijayraghavan (Guest)
on 2008-11-07 17:59
(Received via mailing list)
On Fri, Nov 7, 2008 at 3:58 AM, Jorg Lotze <jlotze@tcd.ie> wrote:

> >
> > Chao
>
> Use the MATLAB functions fopen, fwrite, fclose to write your data in
> binary format to a file that can be read by gr.file_source. Choose 32bit
> floats for real data, write real,imag,real,imag,... for complex data.
> The MATLAB manual is your friend. ;)
>

or you can use one of the programs in
gnuradio-core/src/utils/write_float_binary.m etc

Karthik
This topic is locked and can not be replied to.