how to read marker data with script block
Quote from Almer on 28/09/2022, 12:05Hello
how may I read marker variables by code in Script block?
I mean the information which is shown near the marker and by default is white as shown in the attached picture
Hello
how may I read marker variables by code in Script block?
I mean the information which is shown near the marker and by default is white as shown in the attached picture
Uploaded files:Quote from mm_dev on 29/09/2022, 09:41That data apparently isn't exposed to the script engine yet as far as I can tell.
I've added this to our TODO list.
That data apparently isn't exposed to the script engine yet as far as I can tell.
I've added this to our TODO list.
Quote from OG on 07/11/2023, 12:44Could you please provide an example? I find it really hard to understand the dataflow in scripts.
I see the getMarkers in the documentation, but an example of usage would be highly appreciated.
Could you please provide an example? I find it really hard to understand the dataflow in scripts.
I see the getMarkers in the documentation, but an example of usage would be highly appreciated.
Quote from fw_dev on 13/11/2023, 10:37Attached is an example that shows how to use the getMarkers function inside a Mission.
Attached is an example that shows how to use the getMarkers function inside a Mission.
Uploaded files:Quote from Almer on 27/12/2023, 14:38Quote from fw_dev on 13/11/2023, 10:37Attached is an example that shows how to use the getMarkers function inside a Mission.
Dear Aaronia Support Team
thanks for the mentioned mission
but I still have a problem with reading marker's function's value (for example: halfpower value)
Is it possible to read it?
if yes can you advice me a way? since when I use getMarkers() method, it is a dictionary that contained "Marker" which is a list of dictionaries for x and z (x is the frequency , z is the power) and there isn't any information about the function values there
Quote from fw_dev on 13/11/2023, 10:37Attached is an example that shows how to use the getMarkers function inside a Mission.
Dear Aaronia Support Team
thanks for the mentioned mission
but I still have a problem with reading marker's function's value (for example: halfpower value)
Is it possible to read it?
if yes can you advice me a way? since when I use getMarkers() method, it is a dictionary that contained "Marker" which is a list of dictionaries for x and z (x is the frequency , z is the power) and there isn't any information about the function values there
Quote from Almer on 02/01/2024, 11:30Thanks,
I have still a problem, If for any reason the "Spectrum" block become hidden or minimized, my script which use .getmarker() method, doesn't work so I think that the markers are inaccessible while "Spectrum" block is hidden. Can you suggest me a trick?
Thanks,
I have still a problem, If for any reason the "Spectrum" block become hidden or minimized, my script which use .getmarker() method, doesn't work so I think that the markers are inaccessible while "Spectrum" block is hidden. Can you suggest me a trick?
Quote from mm_dev on 02/01/2024, 13:40When the viewport of the Spectrum block isn't visible its contents aren't updated (this is a general performance optimization). That includes traces, and as a result also markers, as they were originally only accessible in the viewport. I've marked this issue for review, but it might take a while.
The easiest option for now is to just ensure that some part of the Spectrum viewport remains visible on screen, a single pixel would be sufficient. Alternatively if you really need the Spectrum block to be able to be closed/invisible, you could also just ignore the standard marker system and calculate them yourself from incoming samples, potentially using DSP processing blocks inside the script block (this is unfortunately not really documented).
When the viewport of the Spectrum block isn't visible its contents aren't updated (this is a general performance optimization). That includes traces, and as a result also markers, as they were originally only accessible in the viewport. I've marked this issue for review, but it might take a while.
The easiest option for now is to just ensure that some part of the Spectrum viewport remains visible on screen, a single pixel would be sufficient. Alternatively if you really need the Spectrum block to be able to be closed/invisible, you could also just ignore the standard marker system and calculate them yourself from incoming samples, potentially using DSP processing blocks inside the script block (this is unfortunately not really documented).