Good Afternoon
I have a supplier that has recently changed how he implements his can protocol and although I have searched I cannot find any help in the forum or help files to help me implement it in PCAN Explorer. Instead of sending information in several frames he now sends just one frame at speed that constantly refreshes with different data. In that frame he uses the first few bytes of data to identify what the data contained in the rest of the frame is.So in Receive Transmit I only ever see one set of data in one frame as it is constantly overwritten. I can trace and get all the data and If i pause the trace and hover I can read the information correctly. Is there a way to filter or set up instruments or signals dependent on the data contained in the frame and not the CAN ID
Real Time extraction of data
-
- Sales & Support
- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Re: Real Time extraction of data
Hello,
For this purpose you can use a Multiplexer.
A Multiplexer can switch the signal interpretation for a given-frame based
on the value of a certain bitrange/byte.
Here a practical example for illustration purposes:
We’ll mostly work in the Symbol Editor (Tools -> Symbol-Editor)
We assume there are 3 devices. From which device a message/signals was sent is indicated by the Multiplexer (Byte 8),
the signal also reflects the corresponding device in its name.
In our example there are 6 2-byte long Signals in total (2 for each Multiplexer/Device):
All of these signals are sent with CAN-ID 0x100h, to have the multiplexer
switch between interpretations, we’ll have to add Multiplexers to our Symbol for 0x100h (right click your Symbol in the Symbol-Editor):
You can then name your multiplexer, define the multiplexer-range (Start Bit , Length), Data Length (Will only trigger for messages with that data length, if unnecessary “valid for all data lengths” can be checked) and the value for this particular Multiplexer to be triggered:
Repeat the steps for all possible Multiplexer values known:
Afterwards you can assign your signals to the Multiplexer (Right click Multiplexer in the Symbol Editor):
Once fully configured, be sure to save your symbol file and make sure the symbol file is
assigned to your current connection, the Multiplexer will now trigger depending on the value for byte8 of 0x100h:
Here a demonstration on how the Multiplexer will switch the symbolic interpretation:
This example is quite uniform, the workflow of adding Multiplexers however also applies to multiplexers in which the symbolic interpretation varies drastically.
For further questions feel free to contact me again.
Best Regards
For this purpose you can use a Multiplexer.
A Multiplexer can switch the signal interpretation for a given-frame based
on the value of a certain bitrange/byte.
Here a practical example for illustration purposes:
We’ll mostly work in the Symbol Editor (Tools -> Symbol-Editor)
We assume there are 3 devices. From which device a message/signals was sent is indicated by the Multiplexer (Byte 8),
the signal also reflects the corresponding device in its name.
In our example there are 6 2-byte long Signals in total (2 for each Multiplexer/Device):
All of these signals are sent with CAN-ID 0x100h, to have the multiplexer
switch between interpretations, we’ll have to add Multiplexers to our Symbol for 0x100h (right click your Symbol in the Symbol-Editor):
You can then name your multiplexer, define the multiplexer-range (Start Bit , Length), Data Length (Will only trigger for messages with that data length, if unnecessary “valid for all data lengths” can be checked) and the value for this particular Multiplexer to be triggered:
Repeat the steps for all possible Multiplexer values known:
Afterwards you can assign your signals to the Multiplexer (Right click Multiplexer in the Symbol Editor):
Once fully configured, be sure to save your symbol file and make sure the symbol file is
assigned to your current connection, the Multiplexer will now trigger depending on the value for byte8 of 0x100h:
Here a demonstration on how the Multiplexer will switch the symbolic interpretation:
This example is quite uniform, the workflow of adding Multiplexers however also applies to multiplexers in which the symbolic interpretation varies drastically.
For further questions feel free to contact me again.
Best Regards
---
Marvin Heidemann
PEAK-Support Team
Marvin Heidemann
PEAK-Support Team
Re: Real Time extraction of data
Many thanks for the prompt reply
Re: Real Time extraction of data
So that sort of fixed my problem. Until they added a second byte of data as a further identifier. So they have a Frame ID 100h the first byte is an ID from 0-5 which I can multiplex as you suggested, but, then for certain ID's they add a second byte 1 or 2 to substring the info so when I multiplex I only ever get the 2 substring value returned.
so I have this 100h 00 01 a string of "123456"
100h 00 02 a string of "789101112"
But the multiplex only ever returns "789101112"
The of course ID 1-5 also have a substring of 1 or 2 so I cannot set the multiplex to the second byte.
Is there any way to further delineate the multiplex ?
so I have this 100h 00 01 a string of "123456"
100h 00 02 a string of "789101112"
But the multiplex only ever returns "789101112"
The of course ID 1-5 also have a substring of 1 or 2 so I cannot set the multiplex to the second byte.
Is there any way to further delineate the multiplex ?
-
- Sales & Support
- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Re: Real Time extraction of data
Hello,
PCAN-Explorer does not supports multiple Multiplexer ranges.
Are you sure these are Multiplexers (As in they change the whole interpretation of the message)?
Or are you refering to enums?
These would encode different string depending on the value ("0x01h = "Start" , 0x02h = "Stop")
Please report back to us regarding this.
Best Regards
Marvin
PCAN-Explorer does not supports multiple Multiplexer ranges.
Are you sure these are Multiplexers (As in they change the whole interpretation of the message)?
Or are you refering to enums?
These would encode different string depending on the value ("0x01h = "Start" , 0x02h = "Stop")
Please report back to us regarding this.
Best Regards
Marvin
---
Marvin Heidemann
PEAK-Support Team
Marvin Heidemann
PEAK-Support Team
Re: Real Time extraction of data
Hi Marvin
I already use ENUMS for fixed data in the frame. No they use it as a way of reporting serial numbers or part numbers which obviously change from unit to unit. They used to send everything in its own frame but now just the one frame which constantly changes the signal within the frame identifying which signal with the first then the second byte. I get it to work fine using ENUMS which is what I originally did and on a trace that works okay as you see all the data but in real time I only ever see the last transmission. So say they send alarms in frame 100h and several alarms occur at once I only ever see the last alarm as each alarm overwrites the display. Or in the case of the Part or Serial Numbers just the last string.
I already use ENUMS for fixed data in the frame. No they use it as a way of reporting serial numbers or part numbers which obviously change from unit to unit. They used to send everything in its own frame but now just the one frame which constantly changes the signal within the frame identifying which signal with the first then the second byte. I get it to work fine using ENUMS which is what I originally did and on a trace that works okay as you see all the data but in real time I only ever see the last transmission. So say they send alarms in frame 100h and several alarms occur at once I only ever see the last alarm as each alarm overwrites the display. Or in the case of the Part or Serial Numbers just the last string.
-
- Sales & Support
- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Re: Real Time extraction of data
Hello,
This is the behavior of the Receive/Transmit Window, the current value is represented.
A histroical Live-View is not available.
For applications such as your the Trace-Feature is the right choice.
For further questions feel free to contact me again.
Best Regards
Marvin
This is the behavior of the Receive/Transmit Window, the current value is represented.
A histroical Live-View is not available.
For applications such as your the Trace-Feature is the right choice.
For further questions feel free to contact me again.
Best Regards
Marvin
---
Marvin Heidemann
PEAK-Support Team
Marvin Heidemann
PEAK-Support Team