11-18-2014 07:35 PM
I have Measurement Studio 2013 Enterprise version for C++ program development and am looking for explanation on CNiMath::RMS() input parameter and use case. The first input parameter is "data to process" according to inline comment. Most API's specify whether time domain signals or power spectrum are expected. This one API does not explain. Would appreciate anyone who has ever used this API to share your first-hand experience. Basically, I need a function to calculate the average power of a sinewave. Thanks in advance.
11-19-2014 05:00 PM
Hi,
Thanks for your post! I have found a different function, that may be better for you to use. Please reference the below link:
CycleRmsAverage Method
http://zone.ni.com/reference/en-XX/help/372636F-01/mstudiowebhelp/html/5722f565/
Also, what device are you using for application?
11-19-2014 05:17 PM
Thanks but your suggestions are good for Visual Basic and C# programmer. I use C/C++ for code development. Also, I am not using any physical device. I am doing post processing on recoreded wave file.
11-20-2014 05:15 PM
Hi,
I was unable to find a definite answer regarding whether this input needs to be a time domain signal or a power spectrum signal. Can you try to use this function and let me know if it works for a time domain signals, frequency spectrum, or both? What type of data is in your recorded file?
11-20-2014 05:45 PM
Recorded are 16-bit PCM wave. Analyze left channel and right channel separately, if stereo.