Cypress provides the BLE stack as a library for PSoC 6 BLE, similar to PSoC 4 BLE. Stack debugging with source code is not possible. But if you let us know what you are looking for, maybe we can figure out a way to help get debug data from the stack.
I think you may have misunderstood what I mean. I mean that when using the BLE protocol stack how to debug the project, because now the situation is as long as I break the point in the project and then full-speed operation, the Bluetooth is broken or abnormal.
Ahh okay. Instead of doing breakpoint based debugging, you could use an UART to send debug data over a serial connection to a terminal. This way, you can ensure that the BLE connection is active and you are able to debug.
Let me know if the above clarifies things a bit.
This is a very common practice, I usually do this to debug, but this can only solve part of the problem, some hidden deeper problems, using this method is difficult to find the root cause of the problem, if you can use the Bluetooth protocol Stack at the same time can also breakpoint based debugging,this is the best way.
...Adding to SNVN's response.
It is very difficult to debug a project with breakpoint and an active BLE connection.
That said in PSoC 6, the BLE stack can run completely in M0+ or in dual-core mode (M0+ running the controller and M4 running the host). This lets you breakpoint debug M4, while M0+ maintains the connection (though again certain host side operations should be allowed at appropriate time when running dual-core stack mode). Again, this is not as good as running the full debug alongside the stack. This however provides an additional depth to the debug by enabling access to the RAM (which is shared) through M4. This combined with UART dump can be more useful than just the UART dumps. You can even dump logs/data over IPC to M4 for further debug.
Thanks for your detailed reply.
1、Since i can breakpoint debug M4,while M0+ maintains the connection,why is this not as good as running the full debug alongside the stack?
2、Do you have tutorials or instructions for the additional debugging methods you have said?
1. That is because you still do not have control/info on the instruction/code executed by M0+. You can only sniff the RAM and possibly the MMIO registers.
2. We do have plans for tutorials on such advanced concepts.
Millions of thanks.I get it,hope that the tutorial can come out as soon as possible.