A free API for the communication with control devices according to UDS (ISO 14229-1)
-
huunhan
- Posts: 3
- Joined: Tue 20. Apr 2021, 08:12
Post
by huunhan » Wed 28. Apr 2021, 10:01
Hello everyone,
I am new to UDS. I did about CAN protocol before, I had a CAN Bus system with 3 nodes. Now I want to use PCAN-USB to test a CAN-based UDS project. In my understanding, UDS is the message protocol communicating between Tester and ECU, as shown below:

So the Tester will be the PCAN-USB, but I don't know how to have the ECU. Do I need to buy a real ECU? Or using an ECU Simulator? What type of ECU do you usually use?
Is my concept of the whole system as shown below correct?
Any suggestions are very appreciated.
Thank you in advance.
Best regards,
Nhan Nguyen
-
M.Heidemann
- Sales & Support

- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Post
by M.Heidemann » Wed 28. Apr 2021, 11:12
Hello,
You would use UDS in case you actually need to communicate with an ECU.
If that ECU is physical one or a simulated one is not relevant, as long as it
adheres to the UDS-protocol and is able to send messages on the Bus.
Without an ECU or a simulated ECU there is not much reason to use UDS in the first place.
Further introduction to UDS can also be found in the PCAN-UDS API docuemntation:
https://www.peak-system.com/produktcd/P ... an_eng.pdf
The setup shown in the diagram is correct.
Best Regards
Marvin
---
Marvin Heidemann
PEAK-Support Team
-
huunhan
- Posts: 3
- Joined: Tue 20. Apr 2021, 08:12
Post
by huunhan » Thu 29. Apr 2021, 04:15
Hello Marvin,
Thank you for your quick response.
M.Heidemann wrote: ↑Wed 28. Apr 2021, 11:12
Without an ECU or a simulated ECU there is not much reason to use UDS in the first place.
Because I am working on a project related to UDS. I will work with real ECU in real car later on, currently only in the design and testing process, so I need to test with device as close to real ECU as possible.
I have one more question: can the PCAN-USB be programmed to be an ECU Simulator as shown below?
Thank you!
Best regards,
Nhan Nguyen
-
M.Heidemann
- Sales & Support

- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Post
by M.Heidemann » Thu 29. Apr 2021, 10:54
Hello,
Yes, you can do that.
Please have a look at the example:
PCAN-UDS\Samples\C++\05_server_simulator\
in the PCAN-UDS package to see how this can be implemented.
You can also build the example-application and use it for this purpose,
if it fits your needs already.
Best Regards
Marvin
---
Marvin Heidemann
PEAK-Support Team
-
huunhan
- Posts: 3
- Joined: Tue 20. Apr 2021, 08:12
Post
by huunhan » Fri 30. Apr 2021, 03:52
M.Heidemann wrote: ↑Thu 29. Apr 2021, 10:54
You can also build the example-application and use it for this purpose,
if it fits your needs already.
Hello Marvin,
In that case, can I use PCAN-USB Pro, which has 2 x CAN channels?
I mean 1 CAN channel is used as the tester, 1 CAN channel is used as the ECU Simulator.
Best regards,
Nhan Nguyen
-
M.Heidemann
- Sales & Support

- Posts: 1083
- Joined: Fri 20. Sep 2019, 13:31
Post
by M.Heidemann » Fri 30. Apr 2021, 06:48
Hello Nhan,
yes, you can do that with a 2 channel PCAN-interface.
The channels are handled independently from one another,
Best Regards
Marvin
---
Marvin Heidemann
PEAK-Support Team