Waring occurs every time using PCAN-UDS to send request

A free API for the communication with control devices according to UDS (ISO 14229-1)
Locked
Francredy
Posts: 3
Joined: Thu 5. Sep 2019, 13:36

Waring occurs every time using PCAN-UDS to send request

Post by Francredy » Tue 19. Nov 2019, 02:32

Hello together,

I'm using PCAN-UDS to test the ECU UDS stack, but sometimes ECU does not response when request with multiple frame, like 2E F1 90 XX .. XX; then the trace was checked, it is found Waring occurs every time using PCAN-UDS to send request, no matter request with single frame or multiple frame, how can i solve this issue?

I'm looking forward for your help :)

following is the trace:

Code: Select all

  3714)     16084.8  Tx         0724  8  03 28 03 01 55 55 55 55 
  3715)     16086.4  Warng  FFFFFFFF  8  03 28 03 01 
  3716)     16086.0  Rx         072C  8  02 68 03 AA AA AA AA AA 
  3717)     18174.3  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3718)     18175.9  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3719)     18176.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3720)     18177.3  Tx         0724  8  21 20 20 20 20 20 20 20 
  3721)     18178.9  Warng  FFFFFFFF  8  21 20 20 20 
  3722)     18179.1  Tx         0724  8  22 20 20 20 20 20 20 20 
  3723)     18180.8  Warng  FFFFFFFF  8  22 20 20 20 
  3724)     18180.1  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3725)     18241.9  Rx         072C  8  03 6E F1 90 AA AA AA AA 
  3726)     19287.3  Tx         0724  8  10 0D 2E F1 97 20 20 20 
  3727)     19288.9  Warng  FFFFFFFF  8  10 0D 2E F1  BUSOFF
  3728)     19288.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3729)     19289.2  Tx         0724  8  21 20 20 20 20 20 20 20 
  3730)     19290.8  Warng  FFFFFFFF  8  21 20 20 20 
  3731)     19290.1  Rx         072C  8  03 7F 2E 13 AA AA AA AA 
  3732)     20652.6  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3733)     20654.4  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3734)     20654.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3735)     20655.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3736)     20657.1  Warng  FFFFFFFF  8  21 20 20 20 
  3737)     20657.3  Tx         0724  8  22 20 20 20 20 20 20 55 
  3738)     20658.9  Warng  FFFFFFFF  8  22 20 20 20 
  3739)     22879.4  Tx         0724  8  07 2E F1 99 00 00 00 00 
  3740)     22881.1  Warng  FFFFFFFF  8  07 2E F1 99  BUSHEAVY BUSOFF
  3741)     22882.1  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3742)     23203.5  Rx         072C  8  03 6E F1 99 AA AA AA AA 
  3743)     24620.9  Tx         0724  8  07 2E F1 9D 00 00 00 00 
  3744)     24622.8  Warng  FFFFFFFF  8  07 2E F1 9D  BUSLIGHT BUSHEAVY BUSOFF
  3745)     24622.1  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3746)     24683.9  Rx         072C  8  03 6E F1 9D AA AA AA AA 
  3747)     26296.7  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3748)     26298.4  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3749)     26298.0  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3750)     26299.7  Tx         0724  8  21 20 20 20 20 20 20 20 
  3751)     26301.4  Warng  FFFFFFFF  8  21 20 20 20 
  3752)     26301.5  Tx         0724  8  22 20 20 20 20 20 20 20 
  3753)     26303.3  Warng  FFFFFFFF  8  22 20 20 20 
  3754)     26304.1  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3755)     26373.8  Rx         072C  8  03 6E F1 90 AA AA AA AA 
  3756)     27826.3  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3757)     27828.0  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3758)     27828.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3759)     27829.4  Tx         0724  8  21 20 20 20 20 20 20 20 
  3760)     27831.1  Warng  FFFFFFFF  8  21 20 20 20 
  3761)     27831.3  Tx         0724  8  22 20 20 20 20 20 20 20 
  3762)     27832.9  Warng  FFFFFFFF  8  22 20 20 20 
  3763)     30168.4  Tx         0724  8  10 0D 2E F1 97 20 20 20 
  3764)     30170.0  Warng  FFFFFFFF  8  10 0D 2E F1  BUSOFF
  3765)     30170.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3766)     30171.4  Tx         0724  8  21 20 20 20 20 20 20 20 
  3767)     30173.0  Warng  FFFFFFFF  8  21 20 20 20 
  3768)     30172.1  Rx         072C  8  03 7F 2E 13 AA AA AA AA 
  3769)     31461.6  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3770)     31463.2  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3771)     31464.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3772)     31465.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3773)     31467.1  Warng  FFFFFFFF  8  21 20 20 20 
  3774)     31467.2  Tx         0724  8  22 20 20 20 20 20 20 55 
  3775)     31468.8  Warng  FFFFFFFF  8  22 20 20 20 
  3776)     33633.7  Tx         0724  8  07 2E F1 9D 00 00 00 00 
  3777)     33635.1  Warng  FFFFFFFF  8  07 2E F1 9D  BUSLIGHT BUSHEAVY BUSOFF
  3778)     33636.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3779)     33704.0  Rx         072C  8  03 6E F1 9D AA AA AA AA 
  3780)     34494.1  Tx         0724  8  07 2E F1 9D 00 00 00 00 
  3781)     34495.8  Warng  FFFFFFFF  8  07 2E F1 9D  BUSLIGHT BUSHEAVY BUSOFF
  3782)     34496.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3783)     34564.0  Rx         072C  8  03 6E F1 9D AA AA AA AA 
  3784)     35332.1  Tx         0724  8  07 2E F1 9D 00 00 00 00 
  3785)     35333.9  Warng  FFFFFFFF  8  07 2E F1 9D  BUSLIGHT BUSHEAVY BUSOFF
  3786)     35334.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3787)     35403.9  Rx         072C  8  03 6E F1 9D AA AA AA AA 
  3788)     36489.5  Tx         0724  8  07 2E F1 99 00 00 00 00 
  3789)     36491.1  Warng  FFFFFFFF  8  07 2E F1 99  BUSHEAVY BUSOFF
  3790)     36492.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3791)     36553.9  Rx         072C  8  03 6E F1 99 AA AA AA AA 
  3792)     37831.7  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3793)     37833.4  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3794)     37834.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3795)     37835.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3796)     37837.2  Warng  FFFFFFFF  8  21 20 20 20 
  3797)     37837.3  Tx         0724  8  22 20 20 20 20 20 20 55 
  3798)     37838.9  Warng  FFFFFFFF  8  22 20 20 20 
  3799)     40665.6  Tx         0724  8  10 0D 2E F1 97 20 20 20 
  3800)     40667.2  Warng  FFFFFFFF  8  10 0D 2E F1  BUSOFF
  3801)     40668.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3802)     40669.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3803)     40671.2  Warng  FFFFFFFF  8  21 20 20 20 
  3804)     40672.2  Rx         072C  8  03 7F 2E 13 AA AA AA AA 
  3805)     41986.7  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3806)     41988.3  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3807)     41988.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3808)     41989.4  Tx         0724  8  21 20 20 20 20 20 20 20 
  3809)     41991.1  Warng  FFFFFFFF  8  21 20 20 20 
  3810)     41991.2  Tx         0724  8  22 20 20 20 20 20 20 20 
  3811)     41992.9  Warng  FFFFFFFF  8  22 20 20 20 
  3812)     41992.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3813)     42054.0  Rx         072C  8  03 6E F1 90 AA AA AA AA 
  3814)     43835.9  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3815)     43837.4  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3816)     43838.1  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3817)     43839.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3818)     43841.2  Warng  FFFFFFFF  8  21 20 20 20 
  3819)     43841.4  Tx         0724  8  22 20 20 20 20 20 20 55 
  3820)     43843.1  Warng  FFFFFFFF  8  22 20 20 20 
  3821)     47749.8  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3822)     47751.5  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3823)     47752.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3824)     47753.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3825)     47755.2  Warng  FFFFFFFF  8  21 20 20 20 
  3826)     47755.3  Tx         0724  8  22 20 20 20 20 20 20 55 
  3827)     47757.1  Warng  FFFFFFFF  8  22 20 20 20 
  3828)     49899.6  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3829)     49901.2  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3830)     49902.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3831)     49903.5  Tx         0724  8  21 20 20 20 20 20 20 20 
  3832)     49905.1  Warng  FFFFFFFF  8  21 20 20 20 
  3833)     49905.1  Tx         0724  8  22 20 20 20 20 20 20 55 
  3834)     49906.8  Warng  FFFFFFFF  8  22 20 20 20 
  3835)     49906.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3836)     49973.9  Rx         072C  8  03 6E F1 98 AA AA AA AA 
  3837)     51033.3  Tx         0724  8  10 13 2E F1 98 20 20 20 
  3838)     51035.0  Warng  FFFFFFFF  8  10 13 2E F1  BUSOFF
  3839)     51034.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3840)     51036.3  Tx         0724  8  21 20 20 20 20 20 20 20 
  3841)     51037.9  Warng  FFFFFFFF  8  21 20 20 20 
  3842)     51038.0  Tx         0724  8  22 20 20 20 20 20 20 55 
  3843)     51039.7  Warng  FFFFFFFF  8  22 20 20 20 
  3844)     51040.2  Rx         072C  8  03 7F 2E 78 AA AA AA AA 
  3845)     51104.0  Rx         072C  8  03 6E F1 98 AA AA AA AA 
  3846)     52439.6  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3847)     52441.3  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3848)     52442.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3849)     52443.6  Tx         0724  8  21 20 20 20 20 20 20 20 
  3850)     52445.3  Warng  FFFFFFFF  8  21 20 20 20 
  3851)     52445.4  Tx         0724  8  22 20 20 20 20 20 20 20 
  3852)     52447.2  Warng  FFFFFFFF  8  22 20 20 20 
  3853)     54584.1  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3854)     54585.7  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3855)     54586.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3856)     54587.7  Tx         0724  8  21 20 20 20 20 20 20 20 
  3857)     54589.3  Warng  FFFFFFFF  8  21 20 20 20 
  3858)     54589.4  Tx         0724  8  22 20 20 20 20 20 20 20 
  3859)     54591.0  Warng  FFFFFFFF  8  22 20 20 20 
  3860)     56734.1  Tx         0724  8  10 14 2E F1 90 20 20 20 
  3861)     56735.9  Warng  FFFFFFFF  8  10 14 2E F1  BUSOFF
  3862)     56736.2  Rx         072C  8  30 00 01 AA AA AA AA AA 
  3863)     56737.6  Tx         0724  8  21 20 20 20 20 20 20 20 
  3864)     56739.3  Warng  FFFFFFFF  8  21 20 20 20 
  3865)     56739.4  Tx         0724  8  22 20 20 20 20 20 20 20 
  3866)     56741.0  Warng  FFFFFFFF  8  22 20 20 20
Last edited by M.Gerber on Tue 19. Nov 2019, 14:53, edited 1 time in total.
Reason: Inserted [code] tags for improved readability

M.Heidemann
Sales & Support
Sales & Support
Posts: 463
Joined: Fri 20. Sep 2019, 13:31

Re: Waring occurs every time using PCAN-UDS to send request

Post by M.Heidemann » Tue 19. Nov 2019, 08:41

Hello,

Those error-messages indicate that there seems to be an issue with the CAN bus itself.

Please make sure your CAN bus is properly terminated and that you use the correct configuration to communicate with your ECU.


Best Regards

Marvin

Francredy
Posts: 3
Joined: Thu 5. Sep 2019, 13:36

Re: Waring occurs every time using PCAN-UDS to send request

Post by Francredy » Fri 22. Nov 2019, 02:51

thank you for your reply

Here is my code , Could you help me check it?

Code: Select all

	UDS_Channel = PUDS_USBBUS1;

	// Initializing of the UDS Communication session 
    UDS_Initialize(UDS_Channel, PUDS_BAUD_500K, PCAN_TYPE_ISA, 0x0100, 3);

	// Define Address
	UDS_iBuffer = 0x01;
	UDS_SetValue(UDS_Channel, PUDS_PARAM_SERVER_ADDRESS, &UDS_iBuffer, 1);

	UDS_ulBuffer = 2000;
	UDS_SetValue(UDS_Channel, PUDS_PARAM_TIMEOUT_REQUEST, &UDS_ulBuffer, sizeof(UDS_ulBuffer));
	UDS_SetValue(UDS_Channel, PUDS_PARAM_TIMEOUT_RESPONSE, &UDS_ulBuffer, sizeof(UDS_ulBuffer));

    // Note: Channel is properly initialized with UDS_Initialize(..) 
    UDS_Message.NETADDRINFO.SA=0xF1;
    UDS_Message.NETADDRINFO.TA=0x01;
    UDS_Message.NETADDRINFO.TA_TYPE=PUDS_ADDRESSING_PHYSICAL;
    UDS_Message.NETADDRINFO.RA=0x00;
    UDS_Message.NETADDRINFO.PROTOCOL=PUDS_PROTOCOL_ISO_15765_2_11B;
    UDS_Message.LEN=8;
    UDS_Message.DATA.RAW[0]=0x00;
    UDS_Message.DATA.RAW[1]=0x00;
    UDS_Message.DATA.RAW[2]=0x07;
    UDS_Message.DATA.RAW[3]=0x2C;
    UDS_Message.DATA.RAW[4]=0x00;
    UDS_Message.DATA.RAW[5]=0x00;
    UDS_Message.DATA.RAW[6]=0x07;
    UDS_Message.DATA.RAW[7]=0x24;
    UDS_SetValue(UDS_Channel,PUDS_PARAM_MAPPING_ADD,&UDS_Message,sizeof(UDS_Message));

    UDS_Message.NETADDRINFO.SA=0x01;
    UDS_Message.NETADDRINFO.TA=0xF1;
    UDS_Message.NETADDRINFO.TA_TYPE=PUDS_ADDRESSING_PHYSICAL;
    UDS_Message.NETADDRINFO.RA=0x00;
    UDS_Message.NETADDRINFO.PROTOCOL=PUDS_PROTOCOL_ISO_15765_2_11B;
    UDS_Message.LEN=8;
    UDS_Message.DATA.RAW[0]=0x00;
    UDS_Message.DATA.RAW[1]=0x00;
    UDS_Message.DATA.RAW[2]=0x07;
    UDS_Message.DATA.RAW[3]=0x24;
    UDS_Message.DATA.RAW[4]=0x00;
    UDS_Message.DATA.RAW[5]=0x00;
    UDS_Message.DATA.RAW[6]=0x07;
    UDS_Message.DATA.RAW[7]=0x2C;
    UDS_SetValue(UDS_Channel,PUDS_PARAM_MAPPING_ADD,&UDS_Message,sizeof(UDS_Message));

K.Wagner
Software Development
Software Development
Posts: 767
Joined: Wed 22. Sep 2010, 13:36

Re: Waring occurs every time using PCAN-UDS to send request

Post by K.Wagner » Fri 22. Nov 2019, 09:00

Hello,
  1. As Marvin said, the errors are triggered due to a physical problem (wrong bit rate, wrong electrical resistance a.k.a. termination, etc).
  2. You are trying to define already existing mappings, without removing them. Mappings with Source 0xF1 (test equipment) and ECU1 (0x01) are already configured in UDS. See help file chapter 4.3
  3. You are changing the default node address for "test equipment" (your application) to 0x1,
    Francredy wrote:   // Define Address
       UDS_iBuffer = 0x01;
       UDS_SetValue(UDS_Channel, PUDS_PARAM_SERVER_ADDRESS, &UDS_iBuffer, 1);
    and later down you still use "0xF1"
    Francredy wrote:    // Note: Channel is properly initialized with UDS_Initialize(..) 
        UDS_Message.NETADDRINFO.SA=0xF1;
        UDS_Message.NETADDRINFO.TA=0x01;
Please be sure you are using the right termination of 120 ohm, and that the bitrate being used by your ECU is the same as in your application.

Please read the mentioned chapter, 4.3. "UDS and ISO-TP Network Addressing Information". Here you will find information about already defined Mappings, how to configure the API in a non-standard context, for example, removing/changing standard mappings, changing the SA (source address), and even an example demonstrating this (chapter 4.3.3, page 343).

By the way, the initialization of the channel
Francredy wrote:   // Initializing of the UDS Communication session
UDS_Channel = PUDS_USBBUS1;
UDS_Initialize(UDS_Channel, PUDS_BAUD_500K, PCAN_TYPE_ISA, 0x0100, 3);
the last 3 parameters are only needed when using non plug&play hardware. Since you are using an USB adapter, you just need to call this function with the channel number and the desired bit rate, like this

Code: Select all

UDS_Initialize(UDS_Channel, PUDS_BAUD_500K);
Best regards,
Keneth

K.Wagner
Software Development
Software Development
Posts: 767
Joined: Wed 22. Sep 2010, 13:36

Re: Waring occurs every time using PCAN-UDS to send request

Post by K.Wagner » Fri 20. Mar 2020, 16:19

- Closed -
Best regards,
Keneth

Locked