6 Replies Latest reply on Aug 13, 2016 5:40 PM by content.librarian

    Control file PSoC component

      Hey everyone,


      I am trying to make a dedicated component for future use, and I want that component to force a few pin assignments.


      I found that you can use "control files" to do this, at least I thought so.
      I tried the following line in the control file:
      attribute port_location of Reset : label is "PORT(1,2)";


      The pin instance name is Reset.


      When I include this component en build the project, the pin is just randomly fitted like there was no control file.


      What is it that I am doing wrong?




      Kind regards,
      Niels Kool

        • 1. Re: Control file PSoC component

          I found the answer(partial) :
          attribute port_location of Reset : label is "PORT(1,2)";
          The pin instance name is Reset, but the pin itself is Reset(0).


          So this added up to:
          attribute port_location of \`$INSTANCE_NAME`:Reset(0)\ : label is "PORT(0,4)";


          But I still have one problem left... this can be overridden. 
          When the user has overridden the control file they only get a "note message" I would like it to be an error.... is this possible?




          I think this should be done through the validator parameters, but I can't find anything about how I can retrieve the port location....

          • 3. Re: Control file PSoC component

            Hi Niels,




            if I remember correctly, there's a project setting which treats warnings as errors. However, I don't know if this only applies to the C code or the whole project.


            You can also ask technical support about this, maybe they can help - it's an uncommon issue (I don't know any components which uses fixed locations except where dedicated hardware function pins exist), but it would be useful to know. If you open a support case, please keep this post updated.


            If there are any components with fixed functions in the PSoC component library you might want to check how they work.









            • 4. Re: Control file PSoC component

              Hi Ralf


              Thanks, for the tip. I sort of assumed that technical support also responded to questions here.


              I will update this post with the answer.





              • 5. Re: Control file PSoC component

                On psoc5lp usbfs should be locked to dm and dp in it's code. Maybe look at it.

                • 6. Re: Control file PSoC component

                  Yea tried finding this in the usb component, but couldn't find it. Also suggested this in the support ticket.


                  Still figuring out, will update when i know more.




                  unfortunately this is not possible at the moment.
                  Support staff:


                  The update I got from the Creator developer team is as follows The tool offers multiple ways to assign pins. I understand that you want to protect the pin choices but the whole point of Creator is to allow them to be edited! If we changed the warning to an error then other users would be negatively impacted. So considering the whole purpose of PSoC's flexibility this feature is not likely to be implemented. We are sorry if this causes inconvenience to you.


                  will have to stick with warnings then.