7 Replies Latest reply on Apr 19, 2018 11:31 AM by hest_3255776

    PSoC 4 not programmable after debug select gpio



      for power saving I changed the SWD pins to GPIO like in the application note but since then psoc creator doesn't show the target MCU and not even psoc programmer can connect to it. This happend on my custom board programmed with kitprog from CY8KIT-043 and also on CY8CKIT-062-BLE Kit.

      I just reproduced it with my CY8KIT-043, after flashing it with SWD pins changed to GPIO it can't be programmed..

      The Kitprog doesn't seem to reset the psoc (attatched oscilloscope). Is the Kitprog not able to recover my psoc 4?


      Please help, how do I recover my PSOCs?

        • 1. Re: PSoC 4 not programmable after debug select gpio

          Did you try power cycling the board, then reconnecting with the PSoC Programmer?

          Did you flash it with a program/image that uses the SWD pins? If so, can you attach the project for us to see the pin settings/use?

          Did you try reconnecting the PSoC programmer to make sure the connection isn't loose/faulty?

          Did the PSoC programmer finish successfully/normally when you programmed the chips? (Could be it failed and that is why it is not showing up?)

          • 2. Re: PSoC 4 not programmable after debug select gpio

            I assumed that flashing a program with this setting causes the psoc to not respond anymore. And I guess I was right..

            To test this I created a project for the CY8KIT-043 and programmed it with a blinking LED, then changed the SWD pins to GPIO and it doesn't work anymore.

            This is the Project: (I named it killing because I intended to reproduce this problem)

            killing2.cydsn.zip - Google Drive

            Power cycle / plugging in and out and so on doesn't help. A Loose connection is impossible because the CY8KIT-043 is directly attatched to the programmer. And just before the programming it worked.


            Also the last software that I flashed (with SWD as GPIOs) was correctly flashed and the LED blinks with the correct speed.


            Can anyone test this project? I just don't know what to do now...

            • 3. Re: PSoC 4 not programmable after debug select gpio

              Are you powering the kit using the programmer? Or are you powering it with an external wire? Changing the programming mode to power cycle and running the board power through the programmer might have a positive effect?

              I don't see any issues with the project you posted (fyi there is an attach capability for the "advanced editor" when responding to posts for attaching files/projects). I'll try testing it on a board and get back to you on my results.

              Have you tried varying the programmer's clock speed to see if that has an effect?

              • 4. Re: PSoC 4 not programmable after debug select gpio

                The kit is powered by the programmer and my custom pcb has its own supply. Both have the same problem.

                As far as I know does the kitprog2 not support other frequencies or programming modes other than reset programming mode (which is NOT triggered, I attatched an oscilloscope on the reset pin. Maybe a kitprog2 bug?) My kitprog2 has the latest firmware.

                Thank you for testing and helping!

                • 5. Re: PSoC 4 not programmable after debug select gpio

                  You could try opening a case with Cypress; The kitprog2 very likely has quirks and bugs just as the Miniprog3 (which I use) has.

                  • 6. Re: PSoC 4 not programmable after debug select gpio

                    Hello. I just tried this on a CY8CKIT-042 and had no issues.


                    I changed the Debug Select in the Systems tab to GPIO and programed the board. I was then able to reprogram the board again. When I hit the program button the select debug target window appears. I right clicked on the kitprog and clicked "port acquire" after doing this the PSoC 4200 device appeared and I clicked on that and then clicked OK/Connect and the board programmed.


                    If that doesn't work for you it sounds like there is an issue with your hardware.

                    • 7. Re: PSoC 4 not programmable after debug select gpio


                      thank you for testing. I forgot to mention that "port aquire" doesn't work for me. There is an error that it can't aquire the device.

                      But good to know that it worked on your board. I will look tomorrow if the port aquire toggles the reset pin because I suspect that it doesn't reset the device and thus no programming is possible.

                      Maybe my kitprog hardware has an issue...



                      edit: Now its working! And the reset line is now pulled to GND correctly.


                      I did update my CMSIS-DAP windows driver and used an other programmer mode (hold the RST button for a few seconds) and on the CYCKIT-062 BLE it was pressing "Mode Select" (SW3).

                      When it shows version "CMSIS-DAP 1.0" on device selection it didn't work. Now it shows something different.


                      Thank you guys!!!