SweepStressTest demo output points problem

Quote from testpoint on 11/05/2022, 11:05hi, I run the demo SweepStressTest and have a question about this demo.
The param is like this: start freq is 1000MHz, end freq is 1300MHz, RBW is 1000KHz. The output points size should be (1300MHz-1000MHz)/1000KHz=300 points. But the result is 608 points.
When the RBW is changed to 100KHz, the desired output size should be 3000, but the result is 6000.
The attached is the output table and my demo code.
Moderator note: Topic has been moved to the proper forum
hi, I run the demo SweepStressTest and have a question about this demo.
The param is like this: start freq is 1000MHz, end freq is 1300MHz, RBW is 1000KHz. The output points size should be (1300MHz-1000MHz)/1000KHz=300 points. But the result is 608 points.
When the RBW is changed to 100KHz, the desired output size should be 3000, but the result is 6000.
The attached is the output table and my demo code.
Moderator note: Topic has been moved to the proper forum
Uploaded files:
Quote from testpoint on 11/05/2022, 11:26By the way, could you tell me the meaning of the num field in struct AARTSAAPI_Packet? The comment is like this 'number of samples used in the packet'. But I analyze the data, I found the num is the different samples of the same spectrum. Is that right? If so, which sample I should take to make the result?
By the way, could you tell me the meaning of the num field in struct AARTSAAPI_Packet? The comment is like this 'number of samples used in the packet'. But I analyze the data, I found the num is the different samples of the same spectrum. Is that right? If so, which sample I should take to make the result?

Quote from mm_dev on 11/05/2022, 11:56As you can see in your table, the number of results is about twice the number that you calculated. That is because RBW is not the same as stepsize between sample points, the latter is smaller to avoid problems with signals at the edge of the requested bandwidth. It is not exactly factor 2 due to rounding issues and technical factors.
Quote from testpoint on 11/05/2022, 11:26By the way, could you tell me the meaning of the num field in struct AARTSAAPI_Packet? The comment is like this 'number of samples used in the packet'. But I analyze the data, I found the num is the different samples of the same spectrum. Is that right? If so, which sample I should take to make the result?
The term "sample" in this context means the full spectrum data. So each packet contains "num" samples, and each sample contains "size" values. It is grouped like this to reduce overhead when each sample is relatively short.
As you can see in your table, the number of results is about twice the number that you calculated. That is because RBW is not the same as stepsize between sample points, the latter is smaller to avoid problems with signals at the edge of the requested bandwidth. It is not exactly factor 2 due to rounding issues and technical factors.
Quote from testpoint on 11/05/2022, 11:26By the way, could you tell me the meaning of the num field in struct AARTSAAPI_Packet? The comment is like this 'number of samples used in the packet'. But I analyze the data, I found the num is the different samples of the same spectrum. Is that right? If so, which sample I should take to make the result?
The term "sample" in this context means the full spectrum data. So each packet contains "num" samples, and each sample contains "size" values. It is grouped like this to reduce overhead when each sample is relatively short.

Quote from testpoint on 12/05/2022, 02:58How could I know the exact frequency of each point?
For example, the start freq is 1000MHz, stop freq is 1300MHz, RBW is 1MHz, and I input a sine wave in 1100MHz -50dBm. There are 608 points output, which point is the biggest value?
How could I know the exact frequency of each point?
For example, the start freq is 1000MHz, stop freq is 1300MHz, RBW is 1MHz, and I input a sine wave in 1100MHz -50dBm. There are 608 points output, which point is the biggest value?

Quote from mm_dev on 12/05/2022, 10:48You have startFrequency, stepFrequency and size values in the packet header. So the frequency of the value at index I is startFrequency + (I % size) * stepFrequency.
You have startFrequency, stepFrequency and size values in the packet header. So the frequency of the value at index I is startFrequency + (I % size) * stepFrequency.

Quote from testpoint on 13/05/2022, 02:18Quote from mm_dev on 12/05/2022, 10:48You have startFrequency, stepFrequency and size values in the packet header. So the frequency of the value at index I is startFrequency + (I % size) * stepFrequency.
oh, I see. But that points number is not the same with my seetings, neither with each point frequency. Thank you.
Quote from mm_dev on 12/05/2022, 10:48You have startFrequency, stepFrequency and size values in the packet header. So the frequency of the value at index I is startFrequency + (I % size) * stepFrequency.
oh, I see. But that points number is not the same with my seetings, neither with each point frequency. Thank you.