DoIP (ISO13400) Client Stack

DoIP Client Overview

RAPIDSEA supports DoIP protocol as explained in the ISO13400 - DoIP Protocol page. This page explains the client architecture and details how the user should interface the stack with their custom logic and realize the Tester implementation quickly. It also provides guidelines on adopting the stack for different systems.

The below diagram captures the block level diagram of the DoIP client and how it interfaces with other modules.

DoIP Client Block Diagram

Application Interface

While the RAPIDSEA DoIP client stack can handle most of the functionality such as message validation,vehicle identification process, routing activation process, Diagnostic response messages handling etc, the business logic has to implement the application functionality. The RAPIDSEA DoIP client clearly defines API and callback functions that are essential for the user to use/implement.

The below table captures the function that are to be called from the application logic.

API Functions

Function

Description

rs_iso13400_client_open

To initialize the DoIP client instance structure for both UDP and TCP process.

rs_iso13400_client_timer_init

To initialize the DoIP client timer

rs_iso13400_client_run

To be called to set the run state for state machine for both UDP and TCP process.

rs_iso13400_client_udp_set_tx_msg_buf

To set up the transmit buffers to be used for the DoIP client UDP communication

rs_iso13400_client_udp_set_rx_msg_buf

To set up the receive buffers to be used for the DoIP client UDP communication.

rs_iso13400_client_tcp_set_tx_msg_buf

To set up the transmit buffers to be used for the DoIP client TCP communication

rs_iso13400_client_tcp_set_rx_msg_buf

To set up the receive buffers to be used for the DoIP client TCP communication.

rs_iso13400_client_set_tx_msg_buf

To set up the transmit buffers to be used for the DoIP client and UDS communication.

rs_iso13400_client_set_rx_msg_buf

To set up the receive buffers to be used for the DoIP client and UDS communication.

rs_iso13400_client_comm_process

To be called periodically to process the incoming/outgoing messages of both UDP and TCP process.

rs_iso13400_client_process

To be called periodically to get the request from the UDS stack and frame doip layer on top of UDS request and sent to server.

rs_iso13400_client_close

To be called to release the DoIP client handle

These functions are documented in detail in the below sections. It is important for the client to implement these functions correct for proper operation of the system.

Implementation Guide

This section explains how the DoIP client can be implemented using the RAPIDSEA stack. Whether the stack is available in source form or in binary form, the steps to be followed are

  • Implement the Callback functions mentioned above

  • Initialize the buffers necessary for the operation

  • Initialize the DoIP stack function.

  • Periodically call the communication process and server process functions so that internal timeouts are handled.

High level flow chart is depicted below:

DoIP Client Flow Diagram

The below diagram captures the high level sequence of operations associated with the DoIP client stack.

DoIP Client High level Sequence Diagram

This can be implemented in a bare-metal system or over RTOS or over full fledged OS such as Linux etc.

Dependency

This stack depends on the below RAPIDSEA interfaces that can be obtained or custom implemented.

Example demo

An example implementation is available along with the release and is described in DoIP UDS Client Demo.

DoIP Client Header

Documentation from the relevant header as follows:

Warning

doxygenfile: Cannot find file “rs_iso13400_client.h