winIDEA SDK
Loading...
Searching...
No Matches
test_delete_all_hwbp.py
1# This script is licensed under BSD License, see file LICENSE.txt.
2# (c) TASKING Germany GmbH, 2023
3#
4# This Pyton script is used to delete all hardware breakpoints.
5
6import isystem.connect as ic
7
8
9winidea_id = ''
10
11
12def test_deleteAllHWBP():
13 connMgr = ic.ConnectionMgr()
14 connMgr.connect(ic.CConnectionConfig().instanceId(winidea_id))
15 ic.CExecutionController(connMgr).reset()
16
17 bpCtrl = ic.CBreakpointController(connMgr)
18 bpCtrl.setHWBP(ic.IConnectDebug.bHW_accRD,
19 ic.IConnectDebug.bHW_SizeDefault,
20 ic.IConnectDebug.bHW_DataLSB0,
21 True, # monitor all addresses of the symbol
22 "mainLoopCounter",
23 42) # compare value
24 bpCtrl.setHWBP(ic.IConnectDebug.bHW_accRD,
25 ic.IConnectDebug.bHW_SizeDefault,
26 ic.IConnectDebug.bHW_DataLSB0,
27 0, # main memory space
28 0x20000400,
29 0) # compare value
30
31 bpCtrl.deleteAllHWBP()
32 print("All HW BPs deleted.")
33
34
35if __name__ == "__main__":
36 test_deleteAllHWBP()