10 Replies Latest reply on Jun 3, 2018 9:15 AM by bneduva_3294706

    Getting a weird TCPWM error??

    bneduva_3294706

      I've been trying to get an ISR for PWMs working, to control LED configurations, and for some reason I started getting weird errors (see attached) as soon as I switched the IRQ to Core0 which prevent me from programming my PSoC6. Is this a bug or am I missing something? Thank you!

        • 1. Re: Getting a weird TCPWM error??
          user_242978793

          Please post your code so we can check it.  Click on File then on Create_Work_Space_Bundle and attach the Zip file to a new comment.

          • 2. Re: Getting a weird TCPWM error??
            msur

            Can you copy paste the error message? The image does not show the error.

             

            Regards,

            Meenakshi Sundaram R

            • 3. Re: Getting a weird TCPWM error??
              user_242978793

              Since you haven't posted your program I made one with the components you used and got this note. The pin named CY_CPUSS_SWJ_SWCLK_TCLK(0) at location P6[7] prevents usage of special purposes: TCPWM[3].line_compl.

              The system gave this information. The pin is able to perform some fixed special functions, yet the pin was not used for any of those special purposes. Since the pin is not used for any special purpose, if you lock the pin placement, you will be blocked from using any of those special features in the future.

              This is like your errors but I don't have your code so I can't determine any more information on your error.

              • 4. Re: Getting a weird TCPWM error??
                bneduva_3294706

                I've gone ahead and attached my project. The error previously mentioned is the exact one that I am getting, but I do not understand since I did not use that pin and I don't know why it's popping up. Maybe seeing my code will help?

                • 5. Re: Getting a weird TCPWM error??
                  user_242978793

                  I didn't get your errors however I got an error with this  line __NVIC_ClearPendingIRQ(LightTimer_IRQ_cfg.intrSrc); not defined.

                  other than that the program compiled with out errors.  What version of Psoc Creator are you using?

                  I am using PSoC Creator  4.2 (4.2.0.641).

                  • 6. Re: Getting a weird TCPWM error??
                    msur

                    Hello,

                     

                    The issue is compilation of "LightControl.c" file is enabled for both CM0p and CM4. Since you have mapped "LightTimer_IRQ" to CM0+ only, the LightTimer_IRQ_cfg structure is not generated for CM4. Hence you see the structure not defined error when the IDE compiles the code for CM4.

                     

                    In order to compile the file for a specific core do the below -

                    1. Right-click the file in the "Workspace explorer"

                    2. Select "Properties"

                    3. In the pop-up that appears, set the "Cores" and "Processors" field to the value you need the file to be included during compilation. For instance, in your case, you need to set these fields to "CortexM0p", as the interrupt config you are trying to access is enabled only for CM0p.

                     

                    I hope this helps.

                     

                    Regards,

                    Meenakshi Sundaram R

                    • 7. Re: Getting a weird TCPWM error??
                      user_242978793

                      I didn't have the issues he was having when I unzipped his program and compiled it on my system. I just got an issue with a variable not defined.  Also Meenakshi your example of right clicking on the program didn't work for me.  What was I doing wrong?

                      • 8. Re: Getting a weird TCPWM error??
                        msur

                        I think he also has the same issue. As whatever image he has posted shows only the 'info' messages from creator (and not error or warning messages).

                         

                        In order to select the core for compilation, you need to right-click the header/source file like shown below and then follow the steps I mentioned in the earlier step.

                         

                        • 9. Re: Getting a weird TCPWM error??
                          user_242978793

                          Okay I found that area to select the processor types.I is set to all.   However when I received his file it didn't show the errors he was referring to at the start of the post.

                          • 10. Re: Getting a weird TCPWM error??
                            bneduva_3294706

                            I now see that the "errors" I was getting were only notes, and that the actual errors that prevented me from programming the device were the ones related to a couple files not being set to the CM0p core. However, the program is still not performing what it is supposed to do, but I will make a separate post addressing that issue. Thank you, everyone, for your patience and assistance!