# Streaming from Lime Suite to the LimeSDR

**URL:** https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463
**Category:** Lime Suite
**Created:** [23 August 2016 11:05 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463 "2016-08-23T11:05:36Z")
**Posts on this page:** 19
**Page:** 1

<div class="post-metadata">

### Author: ![pturner](https://avatars.discourse-cdn.com/v4/letter/p/8797f3/32.png) [@pturner](https://discourse.myriadrf.org/u/pturner)
#### Post date: [23 August 2016 11:05 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/1 "2016-08-23T11:05:36Z")

</div>

Hi All,

I wonder if someone could provide guidance as to how to sucessfully stream a .wfm file from Lime Suite (version 16.6.6.818 running over USB 3.0 on win7 x64) to the LimeSDR platform. I’m able to use the Lime Suite waveform loader to download a .wfm file to the LimeSDR waveform player and obtain the expected RF output using “FPGA Controls”, “Play”. However, when an attempt is made to stream the same .wfm file from PC disk using “FPGA Controls”, “Select File”, “Start streaming” Lime Suite consistently crashes. The crash occurs when the Start streaming button is pressed.

I noticed that the “Stream Protocol.pdf” document provides register settings for streaming configuration. Are these background configured by Lime Suite, or should I be programming them explicitly?

Regards,

Paul

---

<div class="post-metadata">

### Author: ![W7BOT](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/w7bot/32/422_2.png) [@W7BOT](https://discourse.myriadrf.org/u/W7BOT)
#### Post date: [6 March 2017 05:45 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/2 "2017-03-06T05:45:31Z")

</div>

Paul,

Don’t know if this helps (and I realize it’s 6 months later 🙂) … but check out [https://www.youtube.com/watch?v=Ed7iy0gVywo](https://www.youtube.com/watch?v=Ed7iy0gVywo)

Maybe contact Alex? He’s active on this forum.

73s de Dave W7BOT

---

<div class="post-metadata">

### Author: ![csete](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/csete/32/3326_2.png) [@csete](https://discourse.myriadrf.org/u/csete)
#### Post date: [6 March 2017 12:56 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/3 "2017-03-06T12:56:00Z")

</div>

The video transmission was made with GNU Radio, not LimeSuite.

---

<div class="post-metadata">

### Author: ![W7BOT](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/w7bot/32/422_2.png) [@W7BOT](https://discourse.myriadrf.org/u/W7BOT)
#### Post date: [6 March 2017 17:42 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/4 "2017-03-06T17:42:47Z")

</div>

Your right of course … my bad!!! 🙂

---

<div class="post-metadata">

### Author: ![Lucas](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/lucas/32/1246_2.png) [@Lucas](https://discourse.myriadrf.org/u/Lucas)
#### Post date: [9 October 2017 15:14 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/5 "2017-10-09T15:14:49Z")

</div>

Hello Everyone, how are you? Is there a guide to address this @Zack @andrewback?  
I mean, how can I “construct” a signal, create the .wfm file and transmit it with the LimeSDR?

Thanks in Advance!

Lucas.

---

<div class="post-metadata">

### Author: ![andrewback](https://avatars.discourse-cdn.com/v4/letter/a/22d042/32.png) [@andrewback](https://discourse.myriadrf.org/u/andrewback)
#### Post date: [9 October 2017 15:37 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/6 "2017-10-09T15:37:14Z")

</div>

You can use GNU Octave to synthesize a waveform and transmit this via LimeSDR. E.g. see:

[https://myriadrf.org/blog/limesdr-made-simple-part-5-putting-software-sdr/](https://myriadrf.org/blog/limesdr-made-simple-part-5-putting-software-sdr/)

---

<div class="post-metadata">

### Author: ![Lucas](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/lucas/32/1246_2.png) [@Lucas](https://discourse.myriadrf.org/u/Lucas)
#### Post date: [9 October 2017 16:46 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/7 "2017-10-09T16:46:58Z")

</div>

Thank you @andrewback for your quick response!  
Yes. I’ve already tried that example and those in the LimeSDR workshop (Pothos & Octave).  
My question is if it’s a way to load any waveform (previously created with Octave, Pothos, etc) to the waveform player in LimeSuiteGUI and transmit it. Just the same way the WCDMA example in self\_test.ini works, but with an arbitrary waveform. For example:

[GNU Radio / Signal Source] —\> File Sink.wfm

File Sink.wfm --\> [Load in LimeSuiteGUI - FPGA Controls] --\> Play

The main idea is not use GNU Radio or Pothos to trasmit.

Thanks!

---

<div class="post-metadata">

### Author: ![andrewback](https://avatars.discourse-cdn.com/v4/letter/a/22d042/32.png) [@andrewback](https://discourse.myriadrf.org/u/andrewback)
#### Post date: [9 October 2017 16:58 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/8 "2017-10-09T16:58:04Z")

</div>

Ah, sorry! Not sure about this / file format for LimeSuiteGUI WFM player. @Zack, do you happen to know?

---

<div class="post-metadata">

### Author: ![Zack](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/zack/32/89_2.png) [@Zack](https://discourse.myriadrf.org/u/Zack)
#### Post date: [10 October 2017 05:55 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/9 "2017-10-10T05:55:36Z")

</div>

Hi @Lucas, @andrewback,

Here is a Matlab code which explains everything I think. Should work in Octave as well, although not tested. Let me know if you have some questions.

```
% How to create WFM file
% Samples are signed (2's complement) 16 bit values
% Order of samples is I0, Q0, I1, Q1, I2, Q2, ...
samples = int16([32767, 0, 0, -32768, -32768, 0, 0, 32767, 1]);

% Create file
myfile = fopen('samples_matlab.wfm', 'w');
% Write samples to file in big endian format
written = fwrite(myfile, samples, 'int16', 'ieee-be');
fclose(myfile);
```

---

<div class="post-metadata">

### Author: ![Lucas](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/lucas/32/1246_2.png) [@Lucas](https://discourse.myriadrf.org/u/Lucas)
#### Post date: [10 October 2017 13:23 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/10 "2017-10-10T13:23:48Z")

</div>

Thanks @Zack!  
I have a question, the LimeSDR has a 12-bit DAC, the program into the FPGA will convert the 16 bit data of the .wfm file to a 12-bit stream?

---

<div class="post-metadata">

### Author: ![Zack](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/zack/32/89_2.png) [@Zack](https://discourse.myriadrf.org/u/Zack)
#### Post date: [11 October 2017 06:18 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/11 "2017-10-11T06:18:22Z")

</div>

Hi @Lucas,

Correct, FPGA will discard 4 LSBs to construct 12 bit sample from 16 bit.

---

<div class="post-metadata">

### Author: ![Lucas](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/lucas/32/1246_2.png) [@Lucas](https://discourse.myriadrf.org/u/Lucas)
#### Post date: [11 October 2017 14:12 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/12 "2017-10-11T14:12:19Z")

</div>

Thank you for your help @Zack and @andrewback.  
I’m sharing an example script for Matlab to transmit a Single Side Band Suppressed Carrier (SSBSC) signal:

% Waveform example: Single Side Band Suppressed Carrier (SSBSC) signal.

N = 1000; % Number of points in the waveform  
T = 101;  
phi = (2_pi_T/N)_[0:N-1]; %Instantaneous Phase. LimeSDR’s Sample\_Rate_(T/N) determines the frequency offset from the carrier.  
I = cos(phi); Q = sin(phi);

% Construct a single array with Interleaved IQ data

waveform(1:2:2_N) = I;  
waveform(2:2:2_N) = Q;

%Normalization of the signal (+/-1), scaling to full range of the DAC with 16 bit representation.  
waveform = round(waveform \* (32767 / max(abs(waveform))));

% Create file  
myfile = fopen(‘samples\_matlab.wfm’, ‘w’);  
% Write samples to file in big endian format.  
written = fwrite(myfile, waveform, ‘int16’, ‘ieee-be’);  
fclose(myfile);

Once the file is loaded in FPGA Controls, there are times when the signal appears wrong in the FFT viewer. In that case:

1. Stop the transmission and send the a signal from the GUI (the OneTone signal in the FPGA Controls or the NCO-generated signal in TxTSP).
2. Stop the test signal transmission and play the custom signal again.

I upload a screenshot of the custom signal.

Regards!  
Lucas.

 ![SSBSC](https://yyz2.discourse-cdn.com/flex034/uploads/myriadrf/original/2X/6/616ab96eb4d504724e6202decf00abf2914d7b09.png)

---

<div class="post-metadata">

### Author: ![fltech](https://avatars.discourse-cdn.com/v4/letter/f/97f17d/32.png) [@fltech](https://discourse.myriadrf.org/u/fltech)
#### Post date: [6 November 2017 05:12 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/13 "2017-11-06T05:12:30Z")

</div>

I’m glad I found this topic.

I’ve been looking for scrips or programs for Octave for it to be a frequency counter and waveform generator. But I’m having a hard time finding any. I’ve read Octave can do all o this and more.

Any ideas?

Thanks 🙂

---

<div class="post-metadata">

### Author: ![andrewback](https://avatars.discourse-cdn.com/v4/letter/a/22d042/32.png) [@andrewback](https://discourse.myriadrf.org/u/andrewback)
#### Post date: [6 November 2017 12:05 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/14 "2017-11-06T12:05:02Z")

</div>

Please see the LimeSDR Workshop materials for Octave examples that generate various waveforms:

> **[myriadrf/LimeSDR\_Workshop](https://github.com/myriadrf/LimeSDR_Workshop)**
>
> Intro to software-defined radio with LimeSDR workshop - myriadrf/LimeSDR\_Workshop

Also the LimeSDR Made Simple series, e.g.:

[https://myriadrf.org/blog/limesdr-made-simple-part-5-putting-software-sdr/](https://myriadrf.org/blog/limesdr-made-simple-part-5-putting-software-sdr/)

[https://myriadrf.org/blog/limesdr-made-simple-part-7-one-way-continued/](https://myriadrf.org/blog/limesdr-made-simple-part-7-one-way-continued/)

---

<div class="post-metadata">

### Author: ![397alk](https://avatars.discourse-cdn.com/v4/letter/3/77aa72/32.png) [@397alk](https://discourse.myriadrf.org/u/397alk)
#### Post date: [2 June 2018 21:53 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/15 "2018-06-02T21:53:08Z")

</div>

I’m not sure if you’re still active on this topic, but I recently began working with the LimeSDR and creating .wfm files using your code. Thank you so much for this.

Do you have any advice for creating MIMO .wfm files using Matlab?

---

<div class="post-metadata">

### Author: ![Zack](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/zack/32/89_2.png) [@Zack](https://discourse.myriadrf.org/u/Zack)
#### Post date: [4 June 2018 13:31 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/16 "2018-06-04T13:31:47Z")

</div>

Hi @397alk,

Before answering your question I would like to ask how you are going to upload generated WFM MIMO file?

---

<div class="post-metadata">

### Author: ![397alk](https://avatars.discourse-cdn.com/v4/letter/3/77aa72/32.png) [@397alk](https://discourse.myriadrf.org/u/397alk)
#### Post date: [11 June 2018 01:28 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/18 "2018-06-11T01:28:01Z")

</div>

Thank you for your quick response! I’ve been using Lime Suite GUI.

(I think I forgot to @ you with my first response.)

---

<div class="post-metadata">

### Author: ![Zack](https://yyz2.discourse-cdn.com/flex034/user_avatar/discourse.myriadrf.org/zack/32/89_2.png) [@Zack](https://discourse.myriadrf.org/u/Zack)
#### Post date: [11 June 2018 07:24 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/19 "2018-06-11T07:24:32Z")

</div>

Hi @397alk,

Currently LimeSuiteGUI uploads the same WFM file to both MIMO channels. We can implement separate file upload, but the sample number in both files must be the same.

---

<div class="post-metadata">

### Author: ![397alk](https://avatars.discourse-cdn.com/v4/letter/3/77aa72/32.png) [@397alk](https://discourse.myriadrf.org/u/397alk)
#### Post date: [11 June 2018 07:53 UTC](https://discourse.myriadrf.org/t/streaming-from-lime-suite-to-the-limesdr/463/20 "2018-06-11T07:53:40Z")

</div>

I saw that, but was hoping to play two different signals. How would I go about implementing two separate files–since there is only one place to upload a file?
