0

I am trying to open Trace32 (t32start.exe) by running Powershell code (or simply from the command line), then running a .cmm practice script to open the PowerDebug. (It's for starting the program when the PC is turned on after e.g. a power cut.) The script opens a modified GUI of the Power Debug software. When manually opening it, the procedure is running t32start.exe, which opens a GUI.

Here, choosing the TriCore MCU and pressing Start, the GUI is opened. As far as I believe, it opens by running the script file seen on the picture under the StartupScript folder, looking into the file, it's very likely. When Start is pressed, this is logged: "Create Config Files for item "Single/single...".

Based on these, I tried to run this code in Powershell: C:\...\t32start.exe -s C:\...\StartupIfx.cmm

Opening t32start.exe is successful, I even tried -c C:\...\T32Start_Config.ts2 and in both cases, t32start.exe opens correctly (which I am not sure if is needed), in the second case, it logs that Configuration Tree was loaded, with 1352 items. However, when trying to run the practice script, it said: " Cannot append to item of type "Configuration Container V2.2" an item of type "PRINT" ! ". It then says it had an error while processing command line parameters, and tries to help with the usage of T32start. What should I fix in order to successfully open the Power Debug?

me9hanics
  • 3
  • 2

1 Answers1

0

You are mixing here the command line options for TRACE32 PowerView and t32start.

PowerView is the GUI for which you can pass a configuration file with -c <config-file> and a PRACTICE script with -s <cmm-file>.

t32start is a launcher which generates config-files for PowerView and allows you to directly start PowerView with such a generated config-file. It has totally different command line options. (See the manual app_t32start.pdf clicking the button Help within t32start.)

A config-file is a text file which basically tells PowerView how to open the GUI and which debug back-end it should use.

To start TRACE32 PowerView without further usage of t32start do the following:

  1. Open t32start
  2. Right-click on the Lauterbach icon representing the GUI you want to start. In your case that line is labeled with 1: Tricore:
    enter image description here
  3. Choose "Show Start Environment" from the context menu. A window opens labled with "Start Environment Viewer"
  4. Click in the right bottom corner on "Save Config As..." to save the config-file. (Let's assume you have saved it at C:\T32\myconfig.t32)
  5. Click next the button "Save Batch Job As..." to save the windows batch file. (Let's assume you have saved it at C:\T32\startTricrore.cmd)
  6. Now open the the windows batch file you have just saved (startTricrore.cmd) with text editor and check that the path to the config-file (you have just saved) is correct. In the end you should have a line which looks like this:
    start C:\T32\bin\windows64\t32mtc.exe -c C:\T32\myconfig.t32 -s C:\T32\StarupIfx.cmm
  7. You can now launch PowerView for TriCore by just executing your batch file startTricrore.cmd

For your HSM I recommend to launch that extra GUI from within the GUI for TriCore with the command TargetSystem.NewInstance hsm /ARCHitecture ARM /ONCE

Holger
  • 3,920
  • 1
  • 13
  • 35
  • Thank you, this worked like a charm! Not the first time one of your answers helped me. You're awesome! – me9hanics Oct 15 '22 at 22:05
  • To follow up this question, I have posted another question, this time about automating this process (to automatically generate config files and use them without knowing much about the PC used). Can you please check it out? https://stackoverflow.com/questions/75522974/automatically-generating-t32-config-file-at-a-given-path-with-a-given-name – me9hanics Feb 21 '23 at 16:13