大红鹰dhy登录界面「网站首页」欢迎您 /en/tsmaster-function-dbc-sending/ Thu, 11 May 2023 09:35:59 +0000 /?p=3023 overview Overview: Today we introduce you to TSMaster's little feature of how to monitor a particular DBC message sending cycle in a graph, and you want to [...]

The post TSMaster灏忓姛鑳戒箣濡備綍鍦ㄥ浘褰腑鐩戞帶鏌愪竴鏉BC鎶ユ枃鍙戦€佸懆鏈燂紵 first appeared on 涓婃捣鍚屾槦鏅鸿兘绉戞妧鏈夐檺鍏徃.

]]>
overview

Overview:

Today we introduce you to the TSMaster small function of how to monitor a certain DBC message sending cycle in the graph.

Step 1

1.聽Create a user variable Cycle, which is used to display in the graph.

How to monitor the sending cycle of a DBC message in the graph of TSMaster's small function?


Step 2

2. Add monitoring of Cycle to the graphics module.

Picture 2 TSMaster Small Functions


Step 3

3.聽Create a C applet that creates the message delivery event to be monitored (in this case, the message with identifier 0X64).

How to monitor the sending cycle of a DBC message in the graph of TSMaster's small function?


Step 4

4.聽The send event will be triggered after each 0x64 message is successfully sent, just get the current message send time, and then subtract the last message send time, you can get the send cycle, the implementation code is as follows.

How to monitor the sending cycle of a DBC message in the graph of TSMaster's small function?
How to monitor the sending cycle of a DBC message in the graph of TSMaster's small function?


Step 5

5.聽Code Analysis

The first line indicates that this send function is for channel 1, so if you need it to work for all channels, just comment it out.

Line 3 is to get the timestamp (which is the same as the absolute time in the message message field of the message) via the message structure ACAN FD.

In line 4, if the message is sent for the first time, the period is not counted.

In line 11, the library function assigns the cycle value to the user variable Cycle, so that it can be monitored in the graph.

How to monitor the sending cycle of a DBC message in the graph of TSMaster's small function?

The post TSMaster灏忓姛鑳戒箣濡備綍鍦ㄥ浘褰腑鐩戞帶鏌愪竴鏉BC鎶ユ枃鍙戦€佸懆鏈燂紵 first appeared on 涓婃捣鍚屾槦鏅鸿兘绉戞妧鏈夐檺鍏徃.

]]>