KitProg3 issue when program over python_ex

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
ChGa_3974281
Level 1
Level 1
Welcome! First question asked First solution authored

Hi,

We use a python script using python_ex and a KitProg3 to program the PSoC4 devices. Now we have the issue that since we upgrade all to teh latest version (PSoC Programmer 3.29.0, FW 2.10.878) that we can only program empty devices. When a device is already programmed (we lock teh chip) then we get the follow error message:

"Invalid Chip Protection Mode. Command not available in the current chip protection mode."

But if I use th ePSoC Programmer Tool an can erase or reprogram the chip.

0 Likes
1 Solution

Hi Rakshith,

The code to remove the protection was already in the Python_Ex script.

The last post of the Porting example code to python 3 fixed the issue.

Regards Christoph

View solution in original post

0 Likes
8 Replies
Rakshith
Moderator
Moderator
Moderator
250 likes received 1000 replies posted 750 replies posted

Hi ChGa_3974281​,

According to my understanding, you are using a custom script to program your PSoC 4 device. The script was working with previous versions of PSoC Programmer and it is failing with PSoC Programmer 3.29.

Can you please try out the following and let me know the results -

1. Program the device using PSoC Programmer 3.29 with protection enabled and try to reprogram the device.

2. Program the device using the script without any protection settings enabled and try to reprogram the device.

Also, can you let me know the version of PSoC Programmer in which the script was working?

Thanks and Regards,

Rakshith M B

Thanks and Regards,
Rakshith M B
0 Likes

I think it was version 3.27.1 that worked on the PC.

0 Likes

Hi Christoph,

Please let me know if you were able to get the script working on your PC. Is PSoC Programmer and its functionalities working properly for you? Also, is the script working without the protection settings disabled?

Best Regards,

Rakshith

Thanks and Regards,
Rakshith M B
0 Likes

Hi Rakshith,

We tried the two points now:

1. Program the device using PSoC Programmer 3.29 with protection enabled and try to reprogram the device.

-> Yes this works but then we can not erase the chip using the script.

2. Program the device using the script without any protection settings enabled and try to reprogram the device.

-> This does works also

I alredy thought that we have a problem do erase the chip compleatly when protection is set.

This is the call we get the error when it is protecetd:

    #Erase All

    hr = PSoC4_EraseAll()

    if (not SUCCEEDED(hr)): return hr

Regards Christoph

0 Likes

Hi Christoph,

I think the issue that you are facing is similar to the one discussed on this thread - How do I remove protection on PSoC4

Can you try the workaround mentioned here and let me know if that helps.

Thanks and Regards,

Rakshith M B

Thanks and Regards,
Rakshith M B
0 Likes

Hi Rakshith,

The code to remove the protection was already in the Python_Ex script.

The last post of the Porting example code to python 3 fixed the issue.

Regards Christoph

0 Likes

Hi Christoph,

Thank you for providing an update on this thread

Best Regards,

Rakshith M B

Thanks and Regards,
Rakshith M B
0 Likes
ChGa_3974281
Level 1
Level 1
Welcome! First question asked First solution authored

Hi Rakshith,

On this PC there was a very old version of the PSoC Programmer may even still used as KitProg2. Probably I'm no more able to sort out the version but I will try to roll back to a previos version. What is starge is that I have try the script with the same Kitprog and board on my development PC ant there it works. On this PC ther was never a so old version installed. I have then tried to desinstall all the older version of cypress tools and reinstall PSoC Progrmmer 3.29.0 but still the same issue.

I will try now to rollback the versions.

Regards Christoph

0 Likes