07-05-2022 08:37 AM
Yes, it seems that the XY-Relations are not correctly set. I will get in contact with R&D.
07-05-2022 08:58 AM
where can that be? by me while writing the code or by a normal file before evaluation?
here is the code for low pass filter :
Set ChnResult = ChnFiltCalc("[1]/Zeit 1 - Standardmessrate", "[1]/a-5-3 X", "/Filter-a-5-3 X", "IIR", "Bessel", "Low pass", 2, 25, 0, 0, 1.2, 25, "Hamming", False, False)
And still looking for the code for the event, as I said, I used it 15 times for 15 channels:
Call Data.Root.ChannelGroups.Add("Ereignisse -Filter-a-5-3 X ", 3).Activate()
ChnEventList1 = ChnEventDetectionWindow("Zeit 1 - Standardmessrate", "Filter-a-5-3 X", 0.5, 100, 0, 0)
ChnEventList1 = ChnEventFilter(ChnEventList1, "Peaks", 0.08, "Value")
ChnEventList2 = ChnEventDetectionWindow("Zeit 1 - Standardmessrate", "Filter-a-5-3 X", -0.8, -100, 0, 0)
ChnEventList2 = ChnEventFilter(ChnEventList2, "Peaks", 0.08, "Value")
ChnEventResultList = ChnEventOperationOR(ChnEventList1, ChnEventList2)
ChnEventList1 = ChnEventResultList
Call ChnEventCreateXYChannels("Zeit 1 - Standardmessrate", "Filter-a-5-3 X", ChnEventList1)
You mean I have to tune in a code for the xy axis for the events?
07-05-2022 09:41 AM
Unfortunately, it didn't quite work, as mentioned, it's about the length of each event that appears.
I limited it in the report for 12 events for each channel.
if i write code in the script for each events then it shows an error if the events don't appear.
In the picture, for example, for the channel (Filter-a-5-3 Y) there are only 6 events after the evaluation, so there is an error on line 83 because 7 events are not defined.
It seems difficult to solve the problem like this. Hopefully there is a possibility to define the problem without code for xy axis in events! maybe change something in this code directly to define the yx axis for each event.
07-06-2022 12:29 AM
Yes, of course have different measurement results different numbers of event matches. Here is the way I would solve that:
dim oResGroup, oResGroupChns, iNoOfMatches, iLoop
set oResGroup = Data.Root.ChannelGroups.Add("Ereignisse -Filter-a-5-3 Y")
set oResGroupChns = oResGroup.Channels
call oResGroup.Activate
ChnEventList1 = ChnEventDetectionWindow("Zeit 1 - Standardmessrate", "Filter-a-5-3 Y", 0.3, 100, 0, 0)
ChnEventList1 = ChnEventFilter(ChnEventList1, "Peaks", 0.008, "Value")
ChnEventList2 = ChnEventDetectionWindow("Zeit 1 - Standardmessrate", "Filter-a-5-3 Y", -0.3, -100, 0, 0)
ChnEventList2 = ChnEventFilter(ChnEventList2, "Peaks", 0.008, "Value")
ChnEventResultList = ChnEventOperationOR(ChnEventList1, ChnEventList2)
iNoOfMatches = ChnEventCount(ChnEventResultList)
msgbox iNoOfMatches
Call ChnEventCreateXYChannels("Zeit 1 - Standardmessrate", "Filter-a-5-3 Y", ChnEventResultList)
for iLoop = 1 to (iNoOfMatches * 2) step 2
oResGroupChns(iLoop).XRelation = Nothing
oResGroupChns(iLoop + 1).XRelation = oResGroupChns(iLoop)
next
07-06-2022 08:31 AM
Hi Walter,
Thank you very much
I don't understand the code here very well.
for iLoop = 1 to (iNoOfMatches * 2) step 2
oResGroupChns(iLoop).XRelation = Nothing
oResGroupChns(iLoop + 1).XRelation = oResGroupChns(iLoop)
next
Can you please explain it according to the example?
Best regards