RF Measurement Devices

cancel
Showing results for 
Search instead for 
Did you mean: 

NI-RFSG Instrument Driver Programming Flow

Solved!
Go to solution

Hello:

 

This is a question about programming NI PXI-5673 in the streaming mode.

According to the manual the flow should be like this:

  1. niRFSG Initialize—Opens a session to the NI-RFSG device and initializes both the AWG and the upconverter hardware.
  2. niRFSG Configure RF—Configures the frequency and power level of the RF output signal.
  3. niRFSG Initiate—Initiates signal generation.
  4. niRFSG Check Generation Status—Monitors signal generation status and checks for any errors which may occur during signal generation.

 

So the idea is to run niRFSG Check Generation Status in a loop until it says that the generation is done. Is this correct? However, I keep getting error 0xBFFA4208 from this function:

 

The AWG reported the following error:

The data being written to the streaming waveform cannot keep up with the output.
Decrease the sample rate or write data to the streaming waveform more frequently.

Device:  PXI1Slot15

Status Code: -219106

 

This error comes up at the end of the generation.

 

Then I have a couple of questions about the program flow:

  1. If I don't have any more data to generate and my code won't write any more data, will this underflow error always come up?
  2. Is there any algorithm that can avoid that?
  3. At what point the niRFSG Check Generation Status function will return isDone=TRUE, but not return this error? It seems that I need a real time task that checks the generation status.
  4. Is there any way to tell RFSG that there won't be any more data and that it should stop when done and not complain?

 

Thank you,

-Ilya.

0 Kudos
Message 1 of 4
(6,698 Views)
Solution
Accepted by topic author ilyak

Community Admin Note:  The article link has been removed due to invalid information

Hello Ilya,

Below is the general flow of RFSG

test.png

The error you are receiving is because you are either not generating or buffer is empty. Here is that shows on how to deal with such a situation in the playback section.You are right your code will generate underflow error when there is nothing to generate. niRFSG Check Generation Status VI is used to make sure that the device is in the correct state and no overflow or underflow errors occurs. The isDONE? terminal is true if errors occurs during generation or if the generation is done. The another exmaple you can reffer is RFSG Finite Generation.vi from LabVIEW example finder, shows if you do not have any more wavefrom data to generate it goes ahead and turns the isDONE? terminal True. Sometimes if you know that there is no data or it has generated all the data points that you have written you can program it to ignore that specific error by using clear error.vi.

 

Thanks and have a great day!

 

Regards

NI-khil

 

 

 

 

0 Kudos
Message 2 of 4
(6,643 Views)

NI-khil:

 

Thanks for the explanation. 

So basically, from RFSG's standpoint the lack of data indicates an error condition. It is up to the higher level application to interpret it as an end condition.

 

-Ilya.

0 Kudos
Message 3 of 4
(6,634 Views)

Hello Ilya,

That is correct !

 

Regards

NI-khil

0 Kudos
Message 4 of 4
(6,614 Views)