Dialog ‘Breakpoint Properties’

Function: This dialog is used for displaying and changing the properties of the selected breakpoint.

Call: Button 856c9c91143f7db4c0a8640e01212a94_f82d5dd1405a2449c0a8640e0130c654 in the Breakpoints view

Requirement: The application is in online mode.

Tab ‘Condition’

This dialog defines the requirements for which program processing should halt at a breakpoint.

Tasks
Only break if the breakpoint is hit in one of the following tasks

856c9c91143f7db4c0a8640e01212a94_9a3f06830c0506c5c0a8640e012f0ace : CODESYS passes the breakpoint only if it is reached by specific tasks. The required tasks must be activated.

For example, you can define a single debug task and also prevent other tasks that use the same block from being affected when debugging.

Hit Count
Hit Count

Break always: The program always halts at this breakpoint.

Alternative: The program halts at the breakpoint when the breakpoint has been hit as often as defined in the following (type in the required hit count or select it from the number list):

  • Break when the hit count is equal to
  • Break when the hit count is a multiple of
  • Break when the hit count is greater than or equal to
Condition
Break, if true

With CODESYS runtime system >= 3.5.4.0, you can use conditional breakpoints. The condition can be defined only in online mode.

856c9c91143f7db4c0a8640e01212a94_9a3f06830c0506c5c0a8640e012f0ace : CODESYS passes the given condition and halts the program at the breakpoint only when the result yields TRUE. You can define a condition as a valid Boolean expression. Examples: x>100, x[y]=z, a AND b, boolVar.

Attention

Using conditional breakpoints slows down code execution, even when the condition does not yield TRUE.

Tab ‘Data’

In this tab, the variable for which a data breakpoint is set is displayed and it can be modified.
Interrupt execution if the value of the specified variable changes:
  • Input of a qualified variable name
  • 856c9c91143f7db4c0a8640e01212a94_21d51bd0cd4519c1c0a8640e00abb4b7 : Selection of a variable in the Input assistant dialog (category: Watch variables)

Tab ‘Execution point settings’

Execution point (execution does not stop at breakpoint)

856c9c91143f7db4c0a8640e01212a94_9a3f06830c0506c5c0a8640e012f0ace : The breakpoint becomes an execution point. Processing does not halt at this point and the given code is executed.

  • Execution point of a breakpoint: activated: 856c9c91143f7db4c0a8640e01212a94_973f893e1c48ff2bc0a8640e00c95eda ; deactivated: 856c9c91143f7db4c0a8640e01212a94_71f71bf61c4dc012c0a8640e01b5f4d5
  • Execution point of a data breakpoint: activated: 856c9c91143f7db4c0a8640e01212a94_3cde2c2dcb404c29c0a864631ccb517b ; deactivated: 856c9c91143f7db4c0a8640e01212a94_8fe1ad38cb3d51e1c0a86463428457fa
Execute the following code

Code that is executed when the execution point is reached.

Looping structures (For, While) and IF or CASE expressions are not possible.

Print a message in the device log

This option is available only when you select the Enable logging in breakpoints check box in Project Settings ‣ Compiler options.

CODESYS can print variables with the placeholder {variable name} in the message text.

Tab ‘Location’

POU Block of the active application where the breakpoint should be placed.
Position Position of the breakpoint in the POU. Entry as row and column numbers (text editor) or as network or element numbers.
Instances:

In the case of function blocks, you must define whether the breakpoint should be set in the implementation or in an instance.

856c9c91143f7db4c0a8640e01212a94_9a3f06830c0506c5c0a8640e012f0ace CODESYS sets the breakpoint in the instance. For this option, select Instance Path.

856c9c91143f7db4c0a8640e01212a94_4681610f0c058035c0a8640e0049916a CODESYS sets the breakpoint in the implementation.

See also