CSD2X User Module Issue with CY8C21x45/CY8C22x45 PSoC 1 Device – KBA97550

Version 2

    Version: **

     

    Translation - Japanese: CY8C21x45/CY8C22x45 PSoC 1デバイスでのCSD2Xユーザーモジュールの問題 – KBA97550 - Community Translated (JA)

     

    Question:

    The project based on the CY8C21x45/CY8C22x45 device does not work after the CSD2X User Module update to Ver 4.00. How can I resolve this issue?

     

    Answer:

    The situation appears only if you select the “Single-channel with IDAC configuration only” option of CSD2X User Module and the baDACCodeBaselineL array is located not at RAM page 0. Location of the baDACCodeBaselineL array in RAM can be checked in the *.mp file located in the project’s output directory.

     

    If the CSD2X User Module in your project uses the configuration and RAM location described above, then perform the following steps to restore project functionality:

     

    1. Adapt the CSD2X User Module parameters in the Parameters window and wizard
    2. Lock the CSD2X User Module
    3. Open the CSD2X.asm file
    4. Replace the CSD2X_SetIdacValue API code by the following:

     

    CSD2X_SetIdacValue:
    _CSD2X_SetIdacValue:
          RAM_PROLOGUE RAM_USE_CLASS_4
    IF (CSD2X_AUTOCALIBRATION)
    ELSE
         RAM_SETPAGE_CUR >CSD2X_baDACCodeBaselineR
         mov [CSD2X_baDACCodeBaselineR], A ; Store

     

    left DAC value
         mov [CSD2X_baDACCodeBaselineL], X ; Store

     

    right DAC value
         RAM_SETPAGE_CUR 0
    ENDIF
         mov reg[IDACR_D], A
         swap A, X
         mov reg[IDACL_D], A
         RAM_EPILOGUE RAM_USE_CLASS_4
         ret