4 Replies Latest reply on Dec 18, 2012 8:59 AM by msur

    about Amux in CY8C28445

    arief.sudarmaji

      Dear PSOC,

         
      I am trying to use module AMuxN in CY8C28445 from wizard and its datasheet.  I am going to set AMUX into single mode with 14 analog inputs. but i found the wierd error when compiling. The error is: cannot include source file "AMuxN.h"; file not found!! why PSOC did not attach the AMuxN.h file in PSOC Designer 5.3 ??  besides, I also try to use article form Mr Ganesh to build my AMUX but still not work when compiling. there is an error that is:  on sintax--> DAC_CR &= ~0x80; ( undeclared identifier `DAC_CR') why?? would you give solution??
         
      Tq
        • 1. Re: about Amux in CY8C28445
          user_1377889

          It is always advisable to post your complete project here whenever possible (use the archive-function provided in PSoC Developer 5.3). This will help us to distinguish between naming-errors or mis-installations for instance.

             

          Otherwise our advices to overcome the errors are more or less guesses into the blue.

             

           

             

          Bob

             

          PS: If you do not use Developer 5.3 I would suggest to update to the latest version

          • 2. Re: about Amux in CY8C28445
            rajiv.vasanth.badiger

            Can you please attach your project?

               

             

               

            -Rajiv Badiger

            • 3. Re: about Amux in CY8C28445
              user_27941315

              This problem may happen if you compile your code and that you have just modify something in the configuration of the User Module or you changed the User Module name.  In both case you need to generate the configuration file by pressing F6 to build the whole project. 

                 

               

                 

              Regards

              • 4. Re: about Amux in CY8C28445
                msur

                Hello Arief,

                   

                 

                   

                The cause for the error can as trivial as EricS point, either you did not build (F6) the project after renaming your UM instance to 'AMuxN' or you may not have changed the name of the UM instance from the default 'AMuxN_1' to 'AMuxN' to comply with the UM sample code (Please find attached a snapshot showing the error you got).

                   

                 

                   

                For 2, there is no register as DAC_CR, it is either IDAC_CR0 or IDAC_CR1 (might have been pointed as IDAC_CRx). And for AMUX case, i believe IDAC_CR0 is the register whose MSB bit needs to be cleared for spliting the MUX. refer CY8C28xxx TRM for more details. I believe we had DAC_CRx notation in older versions of designer which got changed to IDAC_CRx to be in alignment with TRM register map in the latest designer releases.

                   

                 

                   

                Regards,

                   

                MSUR