get Results from SvcReadMemoryByAddress_2013

A free API for the communication with control devices according to UDS (ISO 14229-1)
Post Reply
Rommel
Posts: 10
Joined: Sat 11. Jan 2025, 10:08

get Results from SvcReadMemoryByAddress_2013

Post by Rommel » Sun 2. Mar 2025, 23:35

Hi

I am struggling to extract the returned information

I checked the CAN comunication and it looks fine. THe UDS Message is send and the ECU Returns some values.
And API is returning StatusiO. But I do not get the retunred information back.

status = UDSApi.SvcReadMemoryByAddress_2013(tp_handle, config, out request, address_buffer,2, result_buffer,2);
if (UDSApi.StatusIsOk_2013(status))
status = UDSApi.WaitForService_2013(tp_handle, ref request, out response, out confirmation);

First I thougtht the answer is stored inside result_buffer or is it returned at responce ?

I checked your documenation, but this parameters are not 100% clear to me
thanks

F.Vergnaud
Software Development
Software Development
Posts: 305
Joined: Mon 9. Sep 2013, 12:21

Re: get Results from SvcReadMemoryByAddress_2013

Post by F.Vergnaud » Mon 3. Mar 2025, 09:36

Hello,

Your variable "result_buffer" is wrongly named: it is actually an input buffer for the size of the memory that you want to read in the UDS request.
Please note that those parameters are based on ISO 14229-1, you can check this standard if you want to learn more on UDS service ReadMemoryByAddress (23h).

All PCAN-UDS functions starting with Svc (for Service) only transmit a UDS request and the parameters are used to initialize that request.
The ECU's response is received and made available to the user via the WaitForService functions:
- Your variable "response" will be filled with the UDS response of the ECU that contains the memory data.

For function "UDS_SvcReadMemoryByAddress_2013", you can find a C/C++ sample in example "06_client_all_request", check function "testReadMemoryByAddress".
Best regards,
Fabrice

Post Reply