09-08-2026 08:07 AM
Hello,
I am trying tu use script with the write arbitrary waveform function. Configure generation Mode is set in script mode. Export Signal is set in Marker Event with Marker0 an PFI0.RF data and makers are not synchronized .
IQ datas are :
32 samples Amplitude 0.1
64 samples Amplitude 0.3
20 samples Amplitude 0.5
80 samples Amplitude 0.7
Script :
script mpSubset
generate mp0 subset(0,196) marker0 (0,56,120,140,195)
end script
Result :
--> 2.6 ms delay @ IQ rate 9.6kS/s : 24.96samples So 25 samples too late
Now I had 25 fake samples (amplitute 0.3) at the beginning of IQ data. It should be 4, 28 because it should be divided dy 4 (see help Commeon Scripting Use Case)
IQ datas are :
25 samples Amplitude 0.3
32 samples Amplitude 0.1
64 samples Amplitude 0.3
20 samples Amplitude 0.5
80 samples Amplitude 0.7
Script :
script mpSubset
generate mp0 subset(25,221) marker0 (25,56,120,140,220)
end script
Result :
OK, right in phase
Now I double the same subset in the script :
script mpSubset
generate mp0 subset(25,221) marker0 (25,56,120,140,220)
wait 20
generate mp0 subset(25,221) marker0 (25,56,120,140,220)
end script
Result :
The fisrt marker of the second subset is not generated and the fake data are generated unless the offset of 25 is specified.
Just changing indexes of the second subset by :
generate mp0 subset(25,221) marker0 (0,25,121,141,219)
Result :
Markers are generated correctly but IQ data are still not as expected. It looks like end of 80 amples packet is generatad before the rest of the subset (like a logical right shift).
What is wrong ? is it possible to use the subset command many times in the same script ?
Thank you,
Regards
09-09-2026 08:36 AM
What device type are you using?
09-09-2026 09:46 AM
hello,
PXI5672
Regards
09-09-2026 11:55 AM
I don't have experience with that device type. Sorry. That's an old device type (I just googled it and says its release date was in 2007).
Few general suggestions. Not sure if your application allows this, but if you could make your subsets multiples of powers of 2 samples, that may help (i.e. try 4, 8, 16; even 32). Similarly for marker positions.