Test Automation and Test Scripting Support by Universal Debug Engine with Python and other scripting languages
The Universal Debug Engine (UDE) is a powerful development platform to develop, test and maintain microcontroller software applications. Besides its interactive debugging capabilities UDE provides an open and flexible interface for scripting as well as for debug and test automation.
UDE Object Model
UDE’s object model is the base technology of the provided interface.
- Allows access to debugger kernel functions and components based on Microsoft® COM (Component Object Model)
- Covers functions from basic debugging to complex trace and analysis use cases.
To get an easy access to its powerful functionality UDE’s object model is described in detail by the UDE help system. In addition to the programmer’s reference, examples guide you during the first steps.
Test Scripting with UDE
UDE supports internal scripts – macros for routine and test tasks during interactive debug sessions – and external scripts for debugger automation. The creation of scripts and macros is not bound to a proprietary language. Rather, any language can be used which provides support for Microsoft® COM. This includes for example (without any claim to completeness):
- Python
- VisualBasic
- JavaScript
- Perl.
The open and flexible test automation interface can be utilized by 3rd party tools. A number of test tool vendors are using UDE’s object model functions since years to get direct access to the target embedded system. If you develop your own test and analysis tools, the language independent COM interfaces allow an easy and standardized way to communicate with UDE and getting access to its powerful debug and test features.
Scripting with Python
Python is a modern scripting language with COM support. UDE supports internal Python scripts that can be executed in the UDE Python Script Console, which implements an interactive command line interface to an embedded Python 3 interpreter. Currently, a Python 3.12 interpreter is embedded in UDE.
In addition, external Python scripts can control UDE in a similar way via the COM interface.
UDE Python Scripting Console
The Python script console can be used to enter Python instructions directly into the console or to load from external sources, the output is displayed in the UDE Python Script console view. Following functions are supported
- Embedded Python V3.10.4+ (UDE 2023) / V3.12.2+ (UDE 2024) interpreter
- Inline execution of simple Python statements and execution of external Python scripts
- Auto-completion of Python keywords and UDE class methods and properties, variable inspections
- Callback functions for UDE events
- External dialog interface.
Accessing the UDE object model
The Python script console provides some predefined COM objects of UDE. The following script gives an example of simple accessing the UDE debugger, break the current execution and list the UDE workspace used:
>>> UDEDebugger = UDEWorkspace.GetActiveDebugger() >>> UDEDebugger.Break() >>> UDEWorkspace.ProjectTitle()
Supported Architectures with Universal Debug Engine (UDE Debugger)
- TriCore™ AURIX™ TC4x Microcontrollers from Infineon
- TriCore™ AURIX™ TC32, TC33, TC35, TC36, TC37, TC38, TC39 Microcontrollers from Infineon
- TriCore™ AURIX™ TC21, TC22, TC23, TC24, TC26, TC27, TC29 Microcontrollers from Infineon
- TriCore™ AUDO TC1767ED, TC1797ED, TC1798 Microcontrollers from Infineon
- Synopsys ARC® Processors
- RISC-V Based Microcontrollers
- Power Architecture® MPC57xx Microcontrollers from NXP
- Power Architecture® S32R Microcontrollers from NXP
- Power Architecture® SPC57x Microcontrollers from STMicroelectronics
- Power Architecture® SPC58x Microcontrollers from STMicroelectronics
- Power Architecture® MPC56xx Microcontrollers from NXP
- Power Architecture® SPC56x Microcontrollers from STMicroelectronics
- RH850 G3K, G3M, G4M Microcontrollers from Renesas
- Cortex-R52 S32Z and S32E Real-Time Processors from NXP
- Cortex-R52 S32S Microcontrollers for Safe Vehicle Dynamics from NXP
- Cortex-R52, Cortex-M7 Stellar Automotive Microcontrollers from STMicroelectronics
- Cortex-A53 S32G Vehicle Network Processors from NXP
- Cortex-A53 S32V234 Automotive Platform from NXP
- Cortex-A53 TI Sitara AM64x Processors from Texas Instruments
- Cortex-A72 TI Jacinto 7 TDA4 and DRA8 from Texas Instruments
- Cortex-A9 Zynq-7000 Microcontrollers from Xilinx
- Cortex-A8 i.MX51, OMAP35 Microcontrollers
- Cortex-R4 TMS570 Microcontrollers
- Cortex-R5F TI Sitara AM243x Microcontrollers from Texas Instruments
- Cortex-M7 STM32, Kinetis Microcontrollers
- Cortex-M7 i.MX RT Microcontrollers from NXP
- Cortex-M7 S32K3 General Purpose MCUs for Automotive and Electrification ApplicationsApplications
- Cortex-M4 XMC4000, XMC4500, FM4, Kinetis, LPC4000, STM32, S32K Microcontrollers
- Cortex-M3 LPC1000, STM32, TMS470, TLE9860 Microcontrollers
- Cortex-M33 STM32L5, STM32U5 Microcontrollers from STMicroelectronics
- Cortex-M33 RA Family from Renesas
- Cortex-M0 XMC1000, Kinetis, NUC100, STM32, S32K Microcontrollers
- SuperH™ SH-2A Microcontrollers from Renesas
- XC2000, XE166 Microcontrollers from Infineon
- XC166, XC161, XC164, XC166 Microcontrollers from Infineon
- Arm7™ Microcontrollers
- Arm9™ Microcontrollers
- Arm11™ Microcontrollers
- Power PC™ PPC440, PPC460 Microcontrollers from AMCC
- XScale™ Microcontrollers from Marvel/Intel
- ST10™ ST10F276, ST10F269, ST10F296 * Microcontrollers from STMicroelectronics
- C166™ C161, C165, C166, C167, C16x * Microcontrollers from Infineon
- C166CBC, C161U, SDA6000 * Microcontrollers from Infineon