11-29-2023 01:05 PM
New to Diadem again.
I'm bus converting CAN log files from a Vector .asc file & from a .dbc. So far so good.
The .asc file has time in the format of : say 1701043218.001, before decimal is Linux time in seconds and after is milliseconds.
Once inside Diadem after Bus covert, all channel groups have a Time channel (123 s)
When I drag to a 2d for view, the x axis shows tick labels as 1.7000.. +09.
How do Time into a human readable format in View ?
Solved! Go to Solution.
11-30-2023 01:24 AM
Hello TimRMS,
If I have understood correctly, after loading your data you will have a numerical channel with time in seconds from January 1, 1970 (Unix time definition).
If you want to show the channel as a date on the X-axis of a 2D axis system in VIEW, you can convert your numerical channel into a time channel first. This can be done using the function ChnConvertNumericToTime in the ANALYSIS module.
In the dialog, enter the date 1.1.1970 and your numeric channel. The result channel is your x-channel for the 2D axis system in VIEW.
If you want to automate the conversion, you can do this with this line of code:
call ChnConvertNumericToTime("YourGroup/YourChannel", 6.21671328E+10, True)
11-30-2023 10:40 AM
So far so good, thank you.
Each CAN Id is put into a channel group. The data from a CAN ID can be 1 or more values. Each value is then a Channel in the group.
Each group has a Time channel. The time is the time the CAN message arrived.
There is over 130 groups and hence over 130 Time channels.
Do I need to convert each Time channel in each group?
If so, I'll need to look into how to automate that. Is that under script?
11-30-2023 03:24 PM
Update.
I scripted that Time conversion call. It loops over ever group converting Time to a time channel.
Seems to work well.
Thank you your help and pointing me in the right direction.