- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello
I want to run the sample programs mesh_vendor_server, mesh_provision_client, sensor notion or the other CYBT-213043-MESH examples with breakpoints because I need to see the behavior of the program step by step, but I think I need to debug the example codes in CYBT-213043-MESH, can someone explain to me how to do it in modustoolbox 2.0?
please
can you help me?
Solved! Go to Solution.
- Labels:
-
ispn:40214:1:0
-
l1:314:1:0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Please see the WICED-Hardware-Debugging.pdf for source-code-level debugging.
btsdk-docs/WICED-Hardware-Debugging.pdf at master · cypresssemiconductorco/btsdk-docs · GitHub https://github.com/cypresssemiconductorco/btsdk-docs/blob/master/docs/BT-SDK/WICED-Hardware-Debuggin...
But, for mesh application debugging, I would suggest you to use Mesh model, core traces by enabling below flags in the makefile. You can get sufficient information logs from mesh model, core, provisioner libraries to debug your mesh application in this method.
# These flags control whether the prebuilt mesh libs (core, models)
# will be the trace enabled versions or not
MESH_MODELS_DEBUG_TRACES ?= 0
MESH_CORE_DEBUG_TRACES ?= 0
You may need to enable it in the .c file also.
#if 0
// Set Debug trace level for mesh_models_lib and mesh_provisioner_lib
wiced_bt_mesh_models_set_trace_level(WICED_BT_MESH_CORE_TRACE_INFO);
#endif
#if 0
// Set Debug trace level for all modules but Info level for CORE_AES_CCM module
wiced_bt_mesh_core_set_trace_level(WICED_BT_MESH_CORE_TRACE_FID_ALL, WICED_BT_MESH_CORE_TRACE_DEBUG);
wiced_bt_mesh_core_set_trace_level(WICED_BT_MESH_CORE_TRACE_FID_CORE_AES_CCM, WICED_BT_MESH_CORE_TRACE_INFO);
#endif
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Please see the WICED-Hardware-Debugging.pdf for source-code-level debugging.
btsdk-docs/WICED-Hardware-Debugging.pdf at master · cypresssemiconductorco/btsdk-docs · GitHub https://github.com/cypresssemiconductorco/btsdk-docs/blob/master/docs/BT-SDK/WICED-Hardware-Debuggin...
But, for mesh application debugging, I would suggest you to use Mesh model, core traces by enabling below flags in the makefile. You can get sufficient information logs from mesh model, core, provisioner libraries to debug your mesh application in this method.
# These flags control whether the prebuilt mesh libs (core, models)
# will be the trace enabled versions or not
MESH_MODELS_DEBUG_TRACES ?= 0
MESH_CORE_DEBUG_TRACES ?= 0
You may need to enable it in the .c file also.
#if 0
// Set Debug trace level for mesh_models_lib and mesh_provisioner_lib
wiced_bt_mesh_models_set_trace_level(WICED_BT_MESH_CORE_TRACE_INFO);
#endif
#if 0
// Set Debug trace level for all modules but Info level for CORE_AES_CCM module
wiced_bt_mesh_core_set_trace_level(WICED_BT_MESH_CORE_TRACE_FID_ALL, WICED_BT_MESH_CORE_TRACE_DEBUG);
wiced_bt_mesh_core_set_trace_level(WICED_BT_MESH_CORE_TRACE_FID_CORE_AES_CCM, WICED_BT_MESH_CORE_TRACE_INFO);
#endif
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
# These flags control whether the prebuilt mesh libs (core, models)
# will be the trace enabled versions or not
MESH_MODELS_DEBUG_TRACES? = 1
MESH_CORE_DEBUG_TRACES? = 1
But I'm not sure
what i want is to run step by step each example program like mesh_color_ligth or mesh_provision_client or mesh_vendor
I want to use the break points to see the behavior and flow of the example codes and also because I need to see the data that is read and sent to other modules CYBT-213043-MESH PROVISION_CLIENT with the break points
the example is shown in the image
Can you explain me
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI,
If you want to do source code level debugging please follow WICED-Hardware-Debugging.pdf document.
btsdk-docs/WICED-Hardware-Debugging.pdf at master · cypresssemiconductorco/btsdk-docs · GitHub
Maximum you can set 3 break point.
Please note this debugging technique often conflicts with the real-time requirements of IoT, since it stops the CPU at breakpoints and providing the ability to check on the state of code and data using source code symbols.
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can the MiniProg4 be used to debut the CYBT-213043-MESH kit?
If MiniProg4 can be used to debug CYBT-213043-MESH, CYBT-213043-MESH does not have the socket to connect MiniProg4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
You need to fly-wire the setup.
On the meshkit, please use P12(SWDCK) and P13(SWDIO) for the connection. Please see the spar_utils.h of 20819A1.
For MinProg pinout, please check MiniProg 4 kit guide.
Thanks,
-Dheeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can the CYBT-213043-MESH board be debugged with the MiniProg4?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Yes, It should be possible.
Please check the document: btsdk-docs/WICED-Hardware-Debugging.pdf at master · cypresssemiconductorco/btsdk-docs · GitHub
CYBT-213043-MESH is a module kit based on 20819 silicon. But, module kit does not have a dedicated SWD debug probe socket.
Fly-wiring the setup as I said in my previous comment should work.
Thanks,
-Dheeraj