Re: [PATCH v2 2/2] can: netlink: add interface for CAN-FD Transmitter Delay Compensation (TDC)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri. 18 Jun 2021 at 18:34, Marc Kleine-Budde <mkl@xxxxxxxxxxxxxx> wrote:
> On 04.06.2021 00:15:50, Vincent Mailhol wrote:
> > Add the netlink interface for TDC parameters of struct can_tdc_const
> > and can_tdc.
> >
> > Contrary to the can_bittiming(_const) structures for which there is
> > just a single IFLA_CAN(_DATA)_BITTMING(_CONST) entry per structure,
> > here, we create a nested entry IFLA_CAN_TDC. Within this nested entry,
> > additional IFLA_CAN_TDC_TDC* entries are added for each of the TDC
> > parameters of the newly introduced struct can_tdc_const and struct
> > can_tdc.
> >
> > For struct can_tdc_const, these are:
> >         IFLA_CAN_TDC_TDCV_MAX
> >         IFLA_CAN_TDC_TDCO_MAX
> >         IFLA_CAN_TDC_TDCF_MAX
> >
> > For struct can_tdc, these are:
> >         IFLA_CAN_TDC_TDCV
> >         IFLA_CAN_TDC_TDCO
> >         IFLA_CAN_TDC_TDCF
>
> I just noticed in the mcp2518fd data sheet:
>
> | bit 14-8 TDCO[6:0]: Transmitter Delay Compensation Offset bits;
> | Secondary Sample Point (SSP) Two’s complement; offset can be positive,
> | zero, or negative.
> |
> | 011 1111 = 63 x TSYSCLK
> | ...
> | 000 0000 = 0 x TSYSCLK
> | ...
> | 111 1111 = –64 x TSYSCLK
>
> Have you takes this into account?

I have not. And I fail to understand what would be the physical
meaning if TDCO is zero or negative.

TDCV indicates the position of the bit start on the RX pin. If
TDCO is zero, the measurement occurs on the bit start when all
the ringing occurs. That is a really bad choice to do the
measurement.  If it is negative, it means that you are measuring
the previous bit o_O !?

Maybe I am missing something but I just do not get it.

I believe you started to implement the mcp2518fd. Can you force a
zero and a negative value and tell me if the bus is stable?


Yours sincerely,
Vincent Mailhol



[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux