Trace32有办法知道PRACTICE cmm是否完成吗?

huangapple go评论87阅读模式
英文:

Trace32 is there way to know if PRACTICE cmm finished?

问题

我正在使用RCL来远程控制Trace32。
众所周知,当以交互方式运行任何PRACTICE命令(例如cd.do my_script.cmm)时,命令本身会立即完成,而CMM脚本会继续运行。
在远程执行命令时也是如此。
我的问题是:Trace32中是否有任何函数可以调用,以确定当前是否正在运行任何CMM?不是代码(代码使用STATE.RUN()),而是PRACTICE脚本。

英文:

I am using RCL for controlling Trace32 remotely.
It is well-known that when running any PRACTICE command interactively (e.g. cd.do my_script.cmm) the command itself completes immediately, while the CMM script continues to run.

Same applies when executing command remotely.

My question: if there any function in Trace32 that I could call and determine if any CMM is currently running? Not code (that one is STATE.RUN()), but PRACTICE script.

答案1

得分: 4

使用函数 int T32_GetPracticeState ( int *pstate ); 查看当前是否正在运行 PRACTICE 脚本。有关 pstate 的详细信息和可能的值,请参阅 api_remote_c.pdf。

英文:

Use the function

int T32_GetPracticeState ( int *pstate );

to find out if a PRACTICE script is currently running. See api_remote_c.pdf for details and possible values of pstate.

答案2

得分: 2

提供的答案由 @dev15 提供:

有一个隐藏的 API dbg.library.t32_getpracticestate(),类似于 T32_GetPracticeState

无法接受之前的答案,因为我的问题是特别针对 RCL,而不是 ctype DLL。

还可以使用额外的堆栈深度检查 dbg.fnc.practice_stackdepth() 来确定 Trace32 是否在 CMM 脚本的中间。

英文:

Answer provided by @dev15:

> There is hidden API dbg.library.t32_getpracticestate() which is similar to T32_GetPracticeState.

Couldn't accept previous as answer because my question was specifically for RCL, not ctype DLL.

Also can be used addition check of stack depth dbg.fnc.practice_stackdepth() to determine if Trace32 is in middle of CMM script or not.

huangapple
  • 本文由 发表于 2023年4月11日 00:42:02
  • 转载请务必保留本文链接:https://go.coder-hub.com/75978927.html
  • lauterbach
  • trace32
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定