3 Replies Latest reply on May 13, 2013 6:27 PM by hubert.jetschko

    Problem using PSoC Sensei Parallel FIFO in PSoC Creator 2.2

    hubert.jetschko

      I have a design in PSoC Creator 2.1 which works on a PSoC 5. I recently moved over to a PSoC5LP, which mean I must move my design over to PSoC Creator 2.2. I updated all the components and all of them compiles fine except the PSoC Sensei Parallel FIFO. I deleted it and recreated it with the default name so that all its source code is cleaned and recompiled but still no luck. The error message is:

         

      .\Generated_Source\PSoC5\FIFOIn_1.c:60: error: 'FIFOIn_1_AsyncCtl_ControlReg__CONTROL_REG' undeclared (first use in this function)

         

      In the h file it is used as a define:

         

      #define FIFOIn_1_CONTROL_REG      (* (reg8 *) FIFOIn_1_AsyncCtl_ControlReg__CONTROL_REG)

        • 1. Re: Problem using PSoC Sensei Parallel FIFO in PSoC Creator 2.2
          user_14586677

          The FIFOIn_1.c file has a #include FIFOIn_1.h in it ?

             

           

             

          Regards, Dana.

          • 2. Re: Problem using PSoC Sensei Parallel FIFO in PSoC Creator 2.2
            hubert.jetschko

            FIFOIn_1.h is included in the c file. This all works in PSoC Creator 2.1. It looks like the compiler cannot resolve 

               

             FIFOIn_1_AsyncCtl_ControlReg__CONTROL_REG. 

            • 3. Re: Problem using PSoC Sensei Parallel FIFO in PSoC Creator 2.2
              hubert.jetschko
                      I fixed the problem but not in the right way. In the FIFOIn_v1_0 component, inside FIFOIn.h all the defines are built using the instance name as part of the define. The control register define adds another name called $CtlModeReplacementString which gets replaced by "Async". The component define looks like this: #define `$INSTANCE_NAME`_CONTROL_REG (* (reg8 *) `$INSTANCE_NAME`_`$CtlModeReplacementString`_ControlReg__CONTROL_REG) which looks like this after compilation: #define FIFOforDMA_CONTROL_REG (* (reg8 *) FIFOforDMA_AsyncCtl_ControlReg__CONTROL_REG) In PSoC Creator 2.1, after the design was synthesized, in fitter.h there is a match for FIFOforDMA_AsyncCtl_ControlReg__CONTROL_REG. In PSoC Creator 2.2 Async was replace by Sync, so the definition if for: FIFOforDMA_SyncCtl_ControlReg__CONTROL_REG And that is why it does not compile I fixed the problem by changing the define in the FIFO component header file to: #define `$INSTANCE_NAME`_CONTROL_REG (* (reg8 *) `$INSTANCE_NAME`_SyncCtl_ControlReg__CONTROL_REG) This fixes the problem for PSoC Creator 2.2 but if anything changes again it will be broken again. It looks like PSoC Creator 2.2 does not assign the correct value to $CtlModeReplacementString