1、传输层解读
2、DLC的理解【CAN FD单帧最大字节数为64(CAN为8)】
从DLC转字节长度的C#源码:
/// <summary>
/// Gets the data length of a CAN message
/// </summary>
/// <param name="dlc">Data length code of a CAN message</param>
/// <returns>Data length as integer represented by the given DLC code</returns>
public static int GetLengthFromDLC(int dlc)
{
switch (dlc)
{
case 9: return 12;
case 10: return 16;
case 11: return 20;
case 12: return 24;
case 13: return 32;
case 14: return 48;
case 15: return 64;
default: return dlc;
}
}
3、参考:CAN标准帧刷写【理解34服务和36服务的详细传输过程】