Remote control of DiagRA D and Silver Scan-Tool via the optional Web Services API

More and more users of DiagRA D and Silver Scan-Tool are taking advantage of the remote control option via the Webservices API. Via the interface, external applications on the same computer or in the local network can use almost the complete functionality of both applications. For example, flash sequences with subsequent diagnostic tests can be automated via a Python script or special diagnostic tests on HiLs or test benches can be integrated into the experiments. Of course, recurring OBD tests can also be automated very easily.

Technical background: The interface of the web services is given by a machine-processable format, typically by WSDL (Web Services Description Language). The network protocol SOAP (Simple Object Access Protocol) is used for communication. XML is used as the message format and the HTTP protocol for communication within the network. In the case of DiagRA D/Silver Scan-Tool, communication takes place between a client programme and DiagRA D/Silver Scan-Tool, with DiagRA D/Silver Scan-Tool serving as the server application. The web services are implemented as an API for SOAP, so the user does not have to worry about creating the XML messages or HTTP communication.

The example below shows how the communication is first initiated via DiagRA D using a Python script, then all values from mode $01 are read from all OBD ECUs, then the ECU supply voltage PID $42 is specifically read, and finally the MIL status from mode $03 is read. Finally, communication with the OBD system is terminated. In the example, ZEEP is used as the SOAP client. Documentation of the commands can be found directly in existing installations of DiagRA D or Silver Scan-Tool in the Samples folder.
The Webservices plugin is an optional extension of a DiagRA D or Silver Scan-Tool licence and can either be ordered with a licence or added later.
If you are interested, please contact us at info@rac.de.

Example Python script:

#!/usr/bin/python3
# -*- coding: utf-8 -*-

import sys
import time
# PLEASE NOTE:
#   This script uses the third party package Zeep ("A fast and modern Python SOAP client").
#   Find Zeep in the Python package index: https://pypi.org/project/zeep/
#   Find its documentation here: https://docs.python-zeep.org/en/master/
#   Should you be interested in logging, this might help you: https://docs.python-zeep.org/en/master/plugins.html
#   Zeep project and sources on GitHub: https://github.com/mvantellingen/python-zeep
from zeep import Client, Transport, __version__ as zeep_version

# Configure web service connection.
# PLEASE NOTE:
#   If web service is not running on local machine (localhost/127.0.0.1),
#   you will have to call the login method at first, before being able to use any other method.
IP_ADDRESS = "localhost"
PORT = 1024
# Set 'INTRANET_ONLY', if an internet connection is not available.
# PLEASE NOTE:
#   This requires the 'soapencoding.xsd' to reside in './resources' subfolder.
#   It can be downloaded, here: http://schemas.xmlsoap.org/soap/encoding/
INTRANET_ONLY = False


# Web service constants
RETURN_CODE_SUCCESS = 0
COMMUNICATION_STARTED = 0
COMMUNICATION_STOPPED = 1
COMMUNICATION_ESTABLISHED = 2


class TransportIntranetOnly(Transport):

    def load(self, url):
        # See https://stackoverflow.com/a/40280341

        if (url == "http://schemas.xmlsoap.org/soap/encoding/"):
            url = "resources/soapencoding.xsd"

        # print(url)
        return super(TransportIntranetOnly, self).load(url)

def wait_for_communication(get_status):
    result = False
    while True:
        communication_status = get_status()
        print(f"Communication status: {communication_status}")

        if (communication_status == COMMUNICATION_ESTABLISHED):
            result = True
            break
        # Also leave loop if communcation has unexpectedly been stopped.
        if (communication_status == COMMUNICATION_STOPPED):
            print("Communication has been stopped.")
            break

        time.sleep(1)  # Wait before next poll.

    return result


def main(intranetonly):
    print("Web service OBD sample | RA Consulting GmbH 2021 | www.rac.de")
    print("")

    # PLEASE NOTE:
    #   DiagRA D or Silver Scan-Tool needs to be running and web service needs to be activated.

    wsdl = f"http://{IP_ADDRESS}:{PORT}/wsdl/IDiagRAWebservice"

    if intranetonly:
        client = Client(wsdl, transport=TransportIntranetOnly())
    else:
        client = Client(wsdl)

    webservice = client.service
    # factory = client.type_factory("ns0")  # Needed to handle non-primitive argument and return types.

    # Perform login.
    # PLEASE NOTE:
    #   This is required if web service is not running on local machine (localhost/127.0.0.1).
    # webservice.Login("Example python script")
    try:
        # Temporarily increase log level of the web service. Possible values are 1 to 7.
        # The log file is very helpful if things don't work out as expected. It contains all the called methods, the given arguments, the results and the return codes.
        # It is written to '%LocalAppData%\RA Consulting\DiagRA D\Log' or '%LocalAppData%\RA Consulting\Silver Scan-Tool\Log', respectively,
        # and is called 'DiagRA_RemoteControl_*.log'.
        # You can also set a permanent log level in the Windows registry. Have a look into DiagRA D's/Silver Scan-Tool's help file to find out how this is done.
        webservice.Configure("LOGLEVEL", "5")

        # Print versions.
        webservice_version = webservice.GetVersion("")
        print("Versions:")
        print(f"- Python {sys.version}")
        print(f"- Zeep {zeep_version}")
        print(f"- Web service {webservice_version}")
        print()

        # Set addressword for OBD and obtain its index.
        # PLEASE NOTE:
        #   If you like to communicate with a distinct ECU/addressword instead, you need to use 'GetECUIndex'
        #   and the web service's non-OBD methods (the ones not containing 'OBD' in their names).
        #   For a list of all available methods, see web service reference PDF that resides in
        #   subfolder '.\Samples\WebServices\Doc' of the installation directory.
        obd_index = webservice.GetOBDIndex("33", "")
        print(f"OBD index: {obd_index}")
        if (obd_index < RETURN_CODE_SUCCESS):
            print(webservice.GetLastErrorText())
        else:
            # OBD addressword has been successfully set.
            # Now set protocol.
            webservice.Configure("PROTOCOL", "ISO 15765-4 (CAN)")

            # Try to start communication.
            return_code = webservice.StartOBDCommunication(obd_index)
            print(f"Start communication: {return_code}")
            if (return_code == RETURN_CODE_SUCCESS):
                # Communication could be started.
                try:
                    # Wait until communication has fully been established, before requesting data.
                    communication_established = wait_for_communication(lambda: webservice.GetOBDCommunicationStatus(obd_index))

                    if communication_established:
                        # Read current data.
                        result = webservice.GetOBDAllCurrentData(obd_index)
                        print("Current Data: ")
                        for item in result:
                            print(item)

                        # Read module voltage.
                        result = webservice.GetOBDSingleCurrentData(obd_index, "42")
                        print("Control Module Voltage: ")
                        for item in result:
                            print(item)

                        # Get MIL status.
                        result = webservice.GetOBDMILStatus(obd_index)
                        print("Mode 3: ")
                        for item in result:
                            print(item)
                finally:
                    # Stop communication.
                    return_code = webservice.StopOBDCommunication(obd_index)
                    print(f"Stop communication: {return_code}")

    finally:
        # Perform logout.
        # webservice.Logout()
        pass


if (__name__ == "__main__"):
    main(INTRANET_ONLY)

New Board Member and Management at ASAM e.V.

ASAM Board of Directors, term 2021 – 2023 (From left to right: Dr. René Grosspietsch (BMW AG), Prof. Marcus Rieker, Chairman (HORIBA Europe GmbH), Dr. Ralf Nörenberg (HighQSoft GmbH), Armin Rupalla (RA Consulting GmbH), Prof. Frank Köster (DLR e.V.)

ASAM e.V., an international standardization organization in automotive electronics announces important personnel changes with the beginning of the second quarter of 2021.

  • Board of Directors: Dr. René Grosspietsch (BMW AG) was elected to the ASAM Board of Directors at this year’s General Assembly. He replaces Richard Vreeland (Cummins Inc), who did not run again. All other board members retain their positions. Prof. Marcus Rieker (Horiba Europe GmbH) was confirmed as Chairman of the Board.
  • Management: Since 01.04.2021, Peter Voss is the new Managing Director of ASAM e.V. He takes over this task from Dr. Klaus Estenfeld, who will pursue other responsibilities within ASAM.

Hoehenkirchen, Germany – April 21, 2021 – Dr. René Grosspietsch (BMW AG) was elected as a new member of the ASAM Board of Directors at the General Assembly on March 24, 2021. He replaces Richard Vreeland (Cummins Inc.), who did not run for the board position. During his career, Dr. Grosspietsch has gained extensive experience in the areas of strategy and innovation management, especially with regard to the validation of driver assistance systems. “I am convinced that the validation and market introduction of autonomous driving functions require a common technological basis and global understanding of the automotive industry. Standards play a very important role in that regard,” said Dr. Grosspietsch before his election to the board.
Prof. Marcus Rieker (Horiba Europe GmbH) was confirmed in his position as Chairman of the Board during the constituent meeting of the ASAM Board on April 20, 2021. Prof. Rieker has a long-standing and close relationship with ASAM: The new term of office is his seventh on the ASAM Board and his second as Chairman of the Board. He had also been involved in ASAM working groups for many years before his board membership. “Throughout my career, ASAM has always been part of my work. I have seen how great the organization has evolved over the years. Now there are new challenges ahead, which I will be happy to tackle together with my colleagues on the Executive Board,” Prof. Rieker summed up on the occasion of his re-election.
Thus, Prof. Marcus Rieker (HORIBA Europe GmbH), Dr. René Grosspietsch (BMW AG), Prof. Frank Köster (DLR e.V.), Dr. Ralf Nörenberg (HighQSoft GmbH) and Armin Rupalla (RA Consulting GmbH) will continue the board activities for the next two years.
The major tasks of the Board of Directors will be to continue the internationalization of the organization and to further develop the ASAM standards portfolio. The new standardization domain “Simulation”, which supports the implementation of highly automated and autonomous driving, shall be further extended and merged with activities in the classic domains. For the Board of Directors, cooperation with other standardization organizations and participation in publicly funded projects is another important strategic point.

General Management
At the same time, ASAM announces another recruitment: Peter Voss has taken over the position of Managing Director at ASAM e.V. as of 01.04.2021. He succeeds Dr. Klaus Estenfeld, who is leaving this position after five years. Prof. Marcus Rieker, Chairman of the ASAM Board of Directors, pays tribute to Dr. Estenfeld’s work: “The last 5 years that Dr. Estenfeld has served as Managing Director have been exceptional for ASAM e.V. in every aspect. We thank him for his intensive and very successful work as well as his tireless commitment. At the same time, we are pleased to have been able to win Mr. Voss as our new Managing Director. We are convinced that Mr. Voss, together with the experienced ASAM team, will further develop our organization and drive it to new peaks.” Dr. Estenfeld will continue to serve ASAM as an Executive Advisor.

Peter Voss (left) is new Managing Director at ASAM e.V. He has taken over from Dr. Klaus Estenfeld (right) who is leaving this position after five years. Source. ASAM e.V.

About ASAM e.V.
ASAM e.V. (Association for Standardization of Automation and Measuring Systems) is actively promoting standardization in the automotive industry. Together with its more than 350 member organizations worldwide, the association develops standards that define interfaces and data models for tools used for the development and testing of electronic control units (ECUs) and for the validation of the entire vehicle. The ASAM portfolio currently comprises 33 standards that are applied in tools and tool chains in automotive development worldwide.

Source: ASAM e.V.

Alternativ Text

News about DiagRA D and Silver Scan-Tool

Current versions as of December 9, 2020: 7.45.40

  • new recording format MDF4 with selectable MDF version 4.2.0, 4.1.1, 4.1.0 or 4.0.0
  • We have added DiagRA X Viewer to our download server. It is an add-on tool that can open MDF4 files created with DiagRA D’s recording function. We have decoupled it from our DiagRA X application tool for use with DiagRA D. You do not need an additional license for the viewer (just as you do for XML-Convert and XML-to-Excel).
  • The XML-to-PDF help tool has been replaced by the XML-Convert tool. The XML-to-PDF conversion function is again implemented in this new tool and in addition there is an XML-to-HTML function. The reason for this is that there are more and more problems when browsers are supposed to open XML files using a stylesheet. Just install the tool. It removes the XML-to-PDF tool and provides the same functionality plus the HTML conversion feature.
  • XML-to-Excel lets you convert OBD data from XML outputs of DiagRA D measurement runs to Excel. One can convert multiple XML files to one Excel file, simultaneously or sequentially, to compare them.
  • Adaptation work for the new SAE J1979-2 has started. We expect to provide a first version in the middle of Q1 2021.
  • Extensive enhancements for NOx binning and Green House Gas in SAE J1939 and in SAE J1979 Mode $09.

DiagRA D only

  • Support for CAN FD. Many interface types are already supported. Communication with ECUs supporting CAN FD is much faster – especially flash programming via DiagRA D Flash Plugin.
  • Autosar XML for parameterization of FlexRay communication
DiagRA® Flash Station Banner

News Story DiagRA Embedded

Our DiagRA Embedded component provides a complete diagnostic stack as well as ECU flash programming on both Windows and embedded Linux devices. As a component library, it provides a C/C++ API. As a standalone version it is available with an integrated web server providing ReST and SOAP APIs. The following diagnostic standards are currently supported: ISO 14229 (UDS), ISO 27145, SAE J1939, SAE J1979, OBDII and WWH-OBD. CAN, CAN-FD, DoIP are supported. Currently already supported interfaces are SocketCAN, PEAK, Kvaser, PassThru and RP1210.

 

Possible Use-Cases

  • Engineering: as an application component for diagnostics or programming of test systems in the laboratory, on test setups during the diagnostic development process
  • Testing: as a component integrated in test benches or HiL test systems
  • Testing and verification of real driving emissions: as a component integrated on data loggers and telematic control units
  • Production: as an end-of-line update and test system, for automated programming stations or in a stand-alone Flash application during vehicle transport. Already available in the DiagRA Flash Station tool, which can program up to 10 ECUs on 10 separate vehicle buses.
  • After Sales: integrated in the workshop tester or as a component for diagnostics in the back-end.

Customized Training

Are you interested in an individual training in your own company?
Our experienced team of trainers offers customized training courses worldwide, tailored specifically to your requirements. Whether you prefer practical training in the vehicle or theoretical sessions, we are specialized in creating a program according to your requirements.

For further information or a customized offer for an individual training, we are at your disposal.

Read more

Testing Expo 2019

Also this year we were represented together with our partners Intrepid Control Systems and emotive at the Testing Expo in Stuttgart. We would like to thank all interested parties, customers, partners and (business) friends for the exciting and interesting exchange and look forward to Testing Expo 2020.

On-Board Diagnostics Symposium – Americas

This year’s symposium dealt with OBD topics for passenger cars, light and heavy commercial vehicles, but also for off-road vehicles and motorcycles. As an exhibitor, we were once again able to demonstrate our expertise. The annual event gives us the opportunity to get in personal contact with many users from all areas (OEM, suppliers and authorities) of our software DiagRA D and Silver Scan-Tool. In addition, the symposium offered us the opportunity to meet new customers, exactly those who have to deal with the OBD conformity of their vehicles or those who work on the OBD certification on behalf of the OEM.

We would like to thank everyone for the friendly and interesting discussions and suggestions.

ASAM plans cooperation with CATARC to open up Chinese market

The standardisation organisation ASAM e.V. and the Chinese state-owned company CATARC have signed a declaration of intent for strategic cooperation with the aim of promoting and disseminating ASAM standardisation on the Chinese market.

Höhenkirchen, – July 10, 2019 – ASAM (Association for Standardization of Automation and Measuring Systems) and CATARC (China Automotive Technology and Research Center) intend to cooperate on the Chinese market in the future. On May 17, 2019 in Tianjing, China, they signed a Memorandum of Understanding providing for strategic cooperation to promote and disseminate ASAM standardization in the Chinese automotive industry.

It has been agreed that ASAM will expand its activities to the Chinese market. To this end, ASAM intends to promote standardization in the local automotive industry by setting up a standardization process locally and introducing standards for the more efficient design of vehicle development processes and workflows.

CATARC will work with ASAM in the area of Jihu Zheng, CEO ofCATARC Automotive Data Center (left)and Armin Rupalla, Member of the Board of ASAM e.V. (right) after signing the letter of intent. (Source: CATARC)
standardization and implementation of these goals. In addition, you will assist in the acquisition and integration of Chinese members. As a state-owned company, CATARC also offers the opportunity to support ASAM in administrative matters.

For cooperation, ASAM and CATARC have decided to establish a working group called “C-ASAM”. This working group will represent ASAM in the Chinese market and will ensure the implementation of the vision and development plan as defined in the Declaration. C-ASAM will conduct ASAM-relevant research activities, provide demonstrations and training for local companies and market ASAM standards.

Armin Rupalla, member of the board of ASAM e.V., explains: “This cooperation takes ASAM a big step forward in its internationalization. It enables us to further disseminate the standards and to expand the competences in ASAM through new members. We are looking forward to a fruitful cooperation”.

Mr. Shuai Zaho, representative of CATARC Automotive Data Center, explains: “CATARC’s goal is to promote innovation and efficiency in China. We are convinced that ASAM and especially the ASAM standards will help the Chinese automotive industry to increase process efficiency. In addition, our companies will be able to operate globally and collaborate with partner companies worldwide. We are pleased to offer our services to ASAM and future ASAM members in this regard”.

The final contract to establish C-ASAM is expected to be signed before the end of this year.

Source: Asam

ASAM and CATARC Launch Joint Initiative for ASAM Standardization in China

The standardization organization ASAM e.V. and the Chinese state-owned company CATARC Automotive Data Center jointly launch an initiative to promote the use of ASAM standards in the Chinese automotive industry and to support the development of new ASAM standards as well as the further development of existing ASAM standards according to Chinese requirements. To achieve these goals, a joint organization “C-ASAM” was founded.

Hoehenkirchen, – October 10, 2019 – In a ceremony held on September 27, 2019, ASAM e.V. (Association for Standardization of Automation and Measuring Systems) and CATARC Automotive Data Center founded a joint organization to establish ASAM in China. The newly formed working group “C-ASAM” has the task to promote interest in ASAM and its standards within the local automotive industry, to accompany local companies in the use of ASAM standards, to hold training on ASAM standards and to drive the acquisition and integration of Chinese ASAM members. An important goal of C-ASAM is to establish and implement local standardization activities and thus further expand the international acceptance of ASAM standards.

With the foundation of C-ASAM, ASAM is expanding its global footprint to one of the most important automotive markets. After Europe, Japan and the US, ASAM expects a strong membership growth in China within the next few years and a prosperous standardization community.

First activities of C-ASAM in regards to the ASAM OpenX standards in the domain “Simulation” are already in planning. Due to the great amount of new membership requests from China, driven by the cooperation with CATARC, ASAM anticipates a number of standardization impulses from China in the next years.

Dr. Klaus Estenfeld, Managing Director of ASAM e.V., welcomes the joint project: “In recent years, ASAM and CATARC have established a very good and stable relationship. This is based in particular on our common interest in new technologies, such as ADAS and AV, and their successful implementation via the usage of standards. We are convinced that the automotive industry worldwide must work together on these issues and are therefore pleased to have found CATARC as a perfect partner for the dissemination of ASAM standards in China”.

Jihu Zheng, General Manager of CATARC Automotive Data Center, also sees the cooperation as positive: “The goal of CATARC ADC is to promote cooperation between the Chinese and the international automotive industry.  Standardization is the key to do this. Since ASAM offers some of the leading standards for validating autonomous driving functions, we consider the cooperation with ASAM to be very important in order to bring in the interests of the Chinese automotive industry. We will support local companies in using the ASAM standards effectively and in incorporating their local requirements”.

About ASAM e.V.

ASAM e.V. (Association for Standardization of Automation and Measuring Systems) is actively promoting standardization within the Automotive Industry. Together with its more than 270 member organizations worldwide, the association develops standards that define protocols, interfaces and data models for tools used for the development and testing of electronic control units (ECUs) and for the validation of the total vehicle. Currently, ASAM represents 30 standards that are applied in the automotive industry worldwide with the purpose to enable easy integration of tools into existing value chains and to enable a seamless data exchange.  (www.asam.net)

About CATARC Automotive Data Center

China Automotive Technology and Research Center Co., Ltd. (CATARC) is a central government-level enterprise belonging to the State-owned Assets Supervision and Administration Commission of the State Council and a comprehensive science and technology corporate group with extensive influence in the automotive industry home and abroad. As one of the most important organizations of CATARC, the Automotive Data Center (ADC) actively promotes the integration of information technologies and industry, provides integrated solutions for the automotive industry to grow sustainably, and establishes a multi-dimensional business framework on the basis of big data, large platforms and huge computation. With one-stop solutions to help the industry and companies to grow, ADC aims to be a national data center for the automotive industry. (www.catarc.ac.cn/ac_en)

Quelle: www.asam.net

© RA Consulting GmbH, 2025    USt.-Ident.-Nr.: DE143081464    HRB: 231127 ASAMAETAElektromobilität Süde-West
RA Consulting GmbH