5 Replies Latest reply on Oct 9, 2018 9:43 PM by srnt

    fx2lp delay macro

    Geethanjali_3054931

      Hello,

      why should we use below macro?

      #define _IFREQ  24000            // IFCLK constant for Synchronization Delay

      #define _CFREQ  48000            // CLKOUT constant for Synchronization Delay

       

      in my application project,

      IFCLK is 27mhz,should i use #define _IFREQ  27000  ?

      and

      i am not using clock out pin ,can i ignore this?

       

      regards,

      geetha.

        • 1. Re: fx2lp delay macro
          srnt

          Hello Geetha,

           

          These macro definitions are used for the calculation of the SYNCDELAY. You can refer to the syncdly.h file in the project folder where these values are used in the computation of the SYNCDELAY.

           

          #define _SCYCL ( 3*(_CFREQ) + 5*(_IFREQ) - 1 ) / ( 2*(_IFREQ) )

           

          #if( _SCYCL == 1 )

          #define SYNCDELAY _nop_( )

          #endif

           

          #if( _SCYCL == 2 )

          #define SYNCDELAY _nop_( ); \

                            _nop_( )

          #endif

           

          #if( _SCYCL == 3 )

          #define SYNCDELAY _nop_( ); \

                            _nop_( ); \

                            _nop_( )

          #endif

           

          This macro definition does not affect the IFCLK/ CLKOUT frequency.

           

          Best regards,

          Srinath S

          • 2. Re: fx2lp delay macro
            Geethanjali_3054931

            Hello shrinath,

            I am asking you about syncdelay calculation.

            in my project ,i am using 27MHZ IFCLK,

            do i need to change these macros?that will effect syncdelay?

             

            regards,

            geetha

            • 3. Re: fx2lp delay macro
              srnt

              Hello Geetha,

               

              Yes, modifying these macros will affect the SYNCDELAY if you are using the same syncdly.h header file.

               

              Best regards,

              Srinath S

              • 4. Re: fx2lp delay macro
                Geethanjali_3054931

                Hello shrinath,

                I am using 27mhz IFCLK,at this condition,can i use #define _IFREQ  48000 ?

                or is it should be at #define _IFREQ  27000 ?

                 

                regards,

                geetha.

                • 5. Re: fx2lp delay macro
                  srnt

                  Hello Geetha,

                   

                  It is not mandatory that the macro definition should be matching with the actual IFCLK frequency. The macro definition is only used for computing the SYNCDELAY. It would be logical if the _IFREQ macro definition matches the IFCLK but is not a mandatory condition.

                  Best regards,

                  Srinath S

                  1 of 1 people found this helpful