The OTX DiagManager (short DiagManager) is a software component between diagnostic applications and various, interchangeable diagnostic runtime systems. The DiagManager is part of the OTX-Runtime API, but it can also be used stand-alone.
The picture shows the functional diagram of the software components of the DiagManager. The layers from top to bottom first contain the diagnostic application (1st layer). The diagnostic application is a process that integrates the DiagManager via the APIs (2nd layer). The APIs cover different function groups (e.g. OtxDiagApi, NoneOtxDiagApi etc.) and are available for C++, DotNet and Java. They don't have to be used at all. Each API generates commands that are transferred to the server (4th layer) via the client (3rd layer). A distinction is made between standard and non-standard commands. The structure of standard commands is the same like all diagnostic related actions and terms in OTX, e.g. GetComChannel. Non-standard commands can transport functions which are not described in OTX, e.g. ReleaseDiagService.
A client is assigned to each diagnostic application (process). There is a transport layer between client and server with interprocess communication (IPC) via SOCKETS or PIPES and alternatively without interprocess communication via direct function calls (RAW). Since the server and all layers below are in unmanaged C ++, RAW can only work together with the C ++ OTX-Runtime API. The server serializes the commands and forwards it to the CommandProcessor (5th layer). The diagnostic communication can be optimized (caching, prioritization, limitation etc.) inside the CommandProcessor. The DiagRuntimeSystem (6th layer) adapts the commands to methods of a specific diagnostic runtime system (7th layer). In addition, specific proprietary functions can be called up using non-standard commands (7th layer).
The DiagManager consists of the following APIs which can be integrated into the diagnostic application. Except the OtxDiagApi all other APIs are optionally.
1 import java.util.ArrayList;
16 public class OtxDiagExample {
17 public static void main(String... strings)
20 IOtxDiag otxdiag = OtxDiagFactory.createSocketOtxDiag(8888);
22 IDiagCom diagcom = otxdiag.getDiagCom();
28 IComChannel comchannel = diagcom.GetComChannel(
"LL_GatewUDS",
"EV_GatewLear_006",
false);
32 IDiagService diagservice = diagcom.CreateDiagServiceByName(comchannel,
"DiagnServi_ReadDataByIdentECUIdent");
37 IRequestParameter rq_Param_RecorDataIdent = DataTypeFactory.CreateRequestParameter(
"Param_RecorDataIdent", DataTypeFactory.CreateValue(
"ECU Supplier Number"));
40 IRequestParameters RequestParameters = DataTypeFactory.CreateRequestParameters();
41 RequestParameters.add(rq_Param_RecorDataIdent);
44 IResponseParameters rsp_Resp_ReadDataByIdentECUIdent = DataTypeFactory.CreateResponseParameters(
"Resp_ReadDataByIdentECUIdent");
45 IResponseParameter rsp_Param_RespoServiId = DataTypeFactory.CreateResponseParameter(
"Param_RespoServiId");
46 IResponseParameter rsp_Param_RecorDataIdent = DataTypeFactory.CreateResponseParameter(
"Param_RecorDataIdent");
47 IResponseParameter rsp_Param_MatchRecorDataIdent = DataTypeFactory.CreateResponseParameter(
"Param_MatchRecorDataIdent");
48 IResponseParameter rsp_Param_ECUSupplNumbe = DataTypeFactory.CreateResponseParameter(
"Param_DataRecor.Param_ECUSupplNumbe");
49 rsp_Resp_ReadDataByIdentECUIdent.add(rsp_Param_RespoServiId);
50 rsp_Resp_ReadDataByIdentECUIdent.add(rsp_Param_RecorDataIdent);
51 rsp_Resp_ReadDataByIdentECUIdent.add(rsp_Param_MatchRecorDataIdent);
52 rsp_Resp_ReadDataByIdentECUIdent.add(rsp_Param_ECUSupplNumbe);
54 ArrayList<IResponseParameters> ResponseParameters =
new ArrayList<IResponseParameters>();
55 ResponseParameters.add(rsp_Resp_ReadDataByIdentECUIdent);
58 OutArg<OtxResultStates> resultstate =
new OutArg<OtxResultStates>(
OtxResultStates.ALL_INVALID);
60 diagcom.ExecuteDiagService(diagservice, RequestParameters, ResponseParameters, resultstate,
false,
false);
62 System.out.println(
"ResultState: " + resultstate.getValue());
64 System.out.println(
"Resp_ReadDataByIdentECUIdent");
65 System.out.println(
"\t" +
"Param_RespoServiId" +
"\t\t" + rsp_Param_RespoServiId.getValue().getParameterValue());
66 System.out.println(
"\t" +
"Param_RecorDataIdent" +
"\t\t" + rsp_Param_RecorDataIdent.getValue().getParameterValue());
67 System.out.println(
"\t" +
"Param_MatchRecorDataIdent" +
"\t" + rsp_Param_MatchRecorDataIdent.getValue().getParameterValue());
68 System.out.println(
"\t" +
"Param_DataRecor");
69 System.out.println(
"\t\t" +
"Param_ECUSupplNumbe" +
"\t" + rsp_Param_ECUSupplNumbe.getValue().getParameterValue());
Factory class for creating the DataTypeFactory.
Definition: DataTypeFactory.java:11
Factory class for creating the DiagOtxApi.
Definition: OtxDiagFactory.java:14
Represents the OutArg.
Definition: opentestsystem.otxdiagmanager.otxdiagapi/src/opentestsystem/otx/diagmanager/otxdiagapi/OutArg.java:6
Identical to an enumeration in the OTX standard ISO 13209. A detailed specification can be found ther...
Definition: OtxResultStates.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IComChannel.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IDiagService.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IRequestParameter.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IRequestParameters.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IResponseParameter.java:6
Identical to a datatype in the OTX standard ISO 13209. A detailed specification can be found there.
Definition: IResponseParameters.java:6
The class is identical to an extension in OTX standard ISO 13209. A detailed specification can be fou...
Definition: IDiagCom.java:10
The class is identical to an extension in OTX standard ISO 13209. A detailed specification can be fou...
Definition: IOtxDiag.java:8
The class is identical to an extension in OTX standard ISO 13209. A detailed specification can be fou...
Package covering all actions and terms of all diagnostic related OTX extension by an identical method...
Package containing all objects for the communication to various, interchangeable diagnostic runtime s...
Package containing all objects which are standardized according to ISO 13209 (OTX)
Package containing all objects related to testing inside automotive industry.
Before the OTX-Runtime can communicate with a diagnostic runtime system, the DiagManager must be started. The different ways to start the DiagManager are described in Configuration. The easiest way to start the DiagManager ist to start the utility OpenTestSystem.Otx.DiagManager.Monitor.exe
, see DiagManager Sample Program.
The right ODX data base must be selected and the DiagManager server must be started. In the example the server is listening at port 8888 for clients to connect.