LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

rfsa error

Hi Robert,

- when you use "niRFSA_FetchIQMultiRecordComplexI16" it means the data captured is 16-bit integer is this not so?

- probably i should have seeked clarification on the capability of NI 5663E, so as not to divert from its potential.Cause basically am doing research on GSM signals. So i intend to capture IQ GSM data, synthesis it and see all what it carries i.e signalling info, data, and voice. Since most of your examples narrows on areas of measurement and gives no information on to actually what am doing where limitations could be in the functions of labwindows.  So if you can give me guidance on this will help me to understand the direction of my research.

 

 

Thanks,

Moses.

0 Kudos
Message 31 of 56
(2,430 Views)

Hi Robert,

- when you use "niRFSA_FetchIQMultiRecordComplexI16" it means the data captured is 16-bit integer is this not so?

- probably i should have seeked clarification on the capability of NI 5663E, so as not to divert from its potential.Cause basically am doing research on GSM signals. So i intend to capture IQ GSM data, synthesis it and see all what it carries i.e signalling info, data, and voice. Since most of your examples narrows on areas of measurement and gives no information on to actually what am doing where limitations could be in the functions of labwindows.  So if you can give me guidance on this will help me to understand the direction of my research.

 

 

Thanks,

Moses.

0 Kudos
Message 32 of 56
(2,430 Views)

Moses,

 

I think we may be missing some steps here.

 

Expecting to decode the various modulated bits from the niRFSA fetch function will be pretty tough. A better route would be to use some of the GSM Toolkit functions to return the demodulated bit trace. You can use the niGSMA_ModAccGetCurrentIterationDemodulatedBitTrace funtion to do this I believe. Hopefully this helps.

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 33 of 56
(2,420 Views)

Hi Robert,

I appreciate your guidance although still get the same results even after the changes.

i applied this  function before fetching the signals.


checkWarn(niGSMSA_ModAccGetCurrentIterationDemodulatedBitTrace(aSession,  demodulatedBits, numberOfSamples/*int32 dataArraySize*/, &actualNumDataArrayElements));

and enabled this properties

    checkWarn(niGSMSA_SetScalarAttributeI32(aSession, NULL, NIGSMSA_MODACC_ENABLED,NIGSMSA_VAL_TRUE));
    checkWarn(niGSMSA_SetScalarAttributeI32(aSession, NULL, NIGSMSA_MODACC_ALL_TRACES_ENABLED,NIGSMSA_VAL_TRUE));

but i still get the same unreadable binary data.Even after applying a code to return regular characters.

 

I ask is it necessary to apply Frequency demodulation after capturing the signals using function "ModtFMDemodulateEx()"?

 

0 Kudos
Message 34 of 56
(2,411 Views)

Moses,

 

You will have to demodulate the waveform using GSM toolkit VI's first, then use the DemodulatedBitTrace function. Let me know if that works.

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 35 of 56
(2,406 Views)

Hi Robert,

 

Sincerely on this you lost me, as you know am still a newbie on this. I checked the manual on GSM labview toolkit but i didnt come across any function that talks about demodulation. -please can you guide me on how to come up with such a VI and may be refer me to related examples. - also help me with the chronology of steps cause am not sure whether this VI and DemodulatedBitTrace function are supposed to come before or after the niRFSA_Fetch.

 

 

Thanks, Moses

0 Kudos
Message 36 of 56
(2,394 Views)

Hi Robert,

 

I went through the manuals further and i came across functions that appears to do demodulation. I want to show you some of this functions you advise me accordingly.

First i did some filtering like this

 

  float64 *t0=0;
 float64 *dt;
int enableDifferentialEncoding =0;

int reset = 1;
int numInputWaveformElements;
int *numRecoveredWaveformElements;
int *numRecoveredBitStreamElements;
unsigned char *recoverdBitStream = NULL;
int  *oldNumRecoverdBitStream = 0; 

int numMatchedFilterCoeff, oldNumMatchedFilterCoeff = 0;
double *matchedFilterCoefficents= NULL;


unsigned char *recoverdBitStream = NULL;
int  numSymbols, txFilter,filterLen;
double symbolRate, txFilterAlpha;

NIComplexI16* waveform = NULL;



if(txFilter == MODT_NO_FILTER) numMatchedFilterCoeff = 16; else if(txFilter == MODT_RAISED_COSINE_FILTER) numMatchedFilterCoeff = 1; else if(txFilter == MODT_ROOT_RAISED_COSINE_FILTER) numMatchedFilterCoeff = (16 * filterLen) + 1; if(numMatchedFilterCoeff > oldNumMatchedFilterCoeff) { free(matchedFilterCoefficents); matchedFilterCoefficents = malloc(numMatchedFilterCoeff * sizeof(double)); oldNumMatchedFilterCoeff = numMatchedFilterCoeff; } checkWarn(ModtGenerateMatchedFilterCoefficients(4 ,txFilter,16,txFilterAlpha,filterLen, numMatchedFilterCoeff,matchedFilterCoefficents));/*  540, 5    warning: incompatible pointer to integer conversion passing 'int **' to parameter of type 'int'

*/

 then called

 checkWarn (niRFSA_FetchIQMultiRecordComplexI16 (rfsaSession,0,0,NUMBER_OF_RECORDS,numberOfSamples,-1,waveform,wfmInfo));     

 after which i started to demodulate like below

	checkWarn(ModtMSKDemodulate ( mtSession, 0.0, 1.0, waveform,  numInputWaveformElements,  enableDifferentialEncoding, 16, NULL, matchedFilterCoefficents , numMatchedFilterCoeff, NULL, NULL, reset, &numRecoveredWaveformElements, &numRecoveredBitStreamElements, NULL)); /*  540, 5    warning: incompatible pointer to integer conversion passing 'int **' to parameter of type 'int' 

*/ if(numRecoveredBitStreamElements > oldNumRecoverdBitStream) { free(recoverdBitStream); recoverdBitStream = malloc(numRecoveredBitStreamElements * sizeof(unsigned char));/*  536, 66    error: invalid operands to binary expression ('int *' and 'unsigned int')*/

oldNumRecoverdBitStream = numRecoveredBitStreamElements; } checkWarn(ModtGetRecoveredBitStream(mtSession,&numRecoveredBitStreamElements,recoverdBitStream));/*  540, 5    warning: incompatible pointer to integer conversion passing 'int **' to parameter of type 'int'

*/

 

I have highligted the errors as coments in the code so that you understand where am getting the errors and assist.
Also what will be the variables to put in this function as they differ in representation  from the variables above.

 checkWarn(niGSMSA_ModAccGetCurrentIterationDemodulatedBitTrace(mtSession,  demodulatedBits, number, &actualNumDataArrayElements));

also what are this errors

  "dModt_Demodulation.h"(369,28)   C:\Program Files (x86)\National Instruments\Shared\CVI\include\dModt_Demodulation.h:369:22: note: passing argument to parameter 'inputWaveform' here
   "dModt_Demodulation.h"(379,14)   C:\Program Files (x86)\National Instruments\Shared\CVI\include\dModt_Demodulation.h:379:8: note: passing argument to parameter 'numRecoveredWaveformElements' here




Thanks,

Moses

0 Kudos
Message 37 of 56
(2,384 Views)

Moses,

 

I guess I am still a bit confused on exactly what it is you are looking for. I'm going to try and take a step back and describe what it is I think you are looking for and you can correct me if I'm wrong.

 

I'll start on the generation side, which I realize is not the side you are currently working on. To generate, you have some message (whether it be voice, text, or some other data). This is then mapped into symbols and built into a GSM Packet and transmitted at some carrier frequency.

 

On the analysis side, we have to know what carrier this packet is being transmitted at so that we can mix it down and acquire it. We also need to know the modulation scheme which is defined by the GSM standard. Using this information, we can use the scheme that was used to encode the data to decode it. That is, we have to downconvert the signal from the carrier and read in the waveform, then demodulate it so that we can get the packet. Then we need to pull the symbols from the packet (encoded when we generated the signal) and unmap them and convert those back to the raw data that was originally transmitted.

 

My confusion is exactly what information you are trying to get. Do you want the raw binary data that was originally generated (before it was mapped, modulated, and transmitted)? Or are you looking to get the symbol bits (i.e. the I/Q from RFSA)? Or, are you seeing the information that you want and simply aren't able to save it to file in the format that you want?

 

Lastly, is it possible that you might consider using LabVIEW? There are similar examples in LabVIEW that can get you close and there are built in File I/O functions to make logging the data easier. 

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 38 of 56
(2,375 Views)

Hi Robert,

My answer to your question "Do you want the raw binary data that was originally generated (before it was mapped, modulated, and transmitted)?" is absolutely yes cause i believe am getting the IQ with niRFSA_fetch. So i want to do the demodulation and unmap. GSM standard for modulation/demodulation is GMSK and i ask in NI functions  does modtMSK... serve the purpose of GMSK.

Iam not good in LabView so it will complicate matters for me.

 

 

Thanks,

Moses

0 Kudos
Message 39 of 56
(2,359 Views)

Moses,

 

After speaking with one of my colleagues, it sounds like to modulate/demodulate GMSK you'll also need to apply a gaussian filter. The ModtMSK should be OK after the filter has been applied.

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 40 of 56
(2,340 Views)