PSoC4S : API to change Imod settings

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
MiNe_85951
Level 7
Level 7
Distributor - TED (Japan)
50 likes received 500 replies posted 50 solutions authored

Dear Sirs and Madams,

 

We are considering CapSense for PSoC4S.

However, changes in ambient temperature may cause the Raw count to exceed full scale.

We talked about the problem in the following communities.

https://community.infineon.com/t5/PSoC-4/PSoC4000S-Raw-count-of-CapSense-vs-Ambient-temperature-vs-C...

 

Therefore, we started to consider reducing the Imod setting value from 85% to 60%.

Of course, to avoid flat spots, the clock uses PRS.

 

This API is described in line 2372 in CapSense_SensingCSD_LL.c, but the following is described after line 2372 in CapSense_SensingCSD_LL.c.
 
"This function has been deprecated and is retained for backward compatibility only. Instead, you should use the CapSense_CalibrateWidget () function. "
 
 
So I have the following question : 
(1) Is it okay to use the CapSense_CSDCalibrateWidget API?
(2) Is there any other API to change the value of Imod?
(3) Please tell us when to execute the CapSense_CSDCalibrateWidget API.

 

  CapSense_Start

  CapSense_ScanAllWidgets

  CapSense_CSDCalibrateWidget

 

In the above order, it seems that the calibration position change is not processed as desired.
If you have a recommended processing procedure, please let me know.

 

Regards,

0 Likes
1 Solution
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @MiNe_85951 san,

(1) Yes, you may use CapSense_CSDCalibrateWidget API to change the IMOD settings.

(2) CapSense_CSDCalibrateWidget API is one way to do it. Another way would be the expression view for advanced tab in CapSense component.

To do this follow the steps given below:

  • In PSoC Creator, go to Tools -> Options.

ncbs_0-1645518115091.png

  • Go to Design entry -> component catalog and check the checkbox for "enable param edit views". Apply the changes. 
    ncbs_1-1645518294554.png

     

  • Go to CapSense component, double click to open the configurator. Right click on the Advanced tab and select "Show expression view"
    ncbs_2-1645518411358.png

     

  • Change the value of CsdRawCountCalibrationLevel to the desired value.
    ncbs_3-1645518538348.png

     

 

(3) The API order is as follows:

  • When you are using the CapSense_CSDCalibrateWidget API
    • CapSense_Start
    • CapSense_CSDCalibrateWidget
    • CapSense_InitializeWidgetBaseline
    • CapSense_ScanAllWidgets
  • When you change CsdRawCountCalibrationLevel value in the expression view:
    • CapSense_Start
    • CapSense_ScanAllWidgets

 

Regards,
Nikhil

View solution in original post

3 Replies
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @MiNe_85951 san,

(1) Yes, you may use CapSense_CSDCalibrateWidget API to change the IMOD settings.

(2) CapSense_CSDCalibrateWidget API is one way to do it. Another way would be the expression view for advanced tab in CapSense component.

To do this follow the steps given below:

  • In PSoC Creator, go to Tools -> Options.

ncbs_0-1645518115091.png

  • Go to Design entry -> component catalog and check the checkbox for "enable param edit views". Apply the changes. 
    ncbs_1-1645518294554.png

     

  • Go to CapSense component, double click to open the configurator. Right click on the Advanced tab and select "Show expression view"
    ncbs_2-1645518411358.png

     

  • Change the value of CsdRawCountCalibrationLevel to the desired value.
    ncbs_3-1645518538348.png

     

 

(3) The API order is as follows:

  • When you are using the CapSense_CSDCalibrateWidget API
    • CapSense_Start
    • CapSense_CSDCalibrateWidget
    • CapSense_InitializeWidgetBaseline
    • CapSense_ScanAllWidgets
  • When you change CsdRawCountCalibrationLevel value in the expression view:
    • CapSense_Start
    • CapSense_ScanAllWidgets

 

Regards,
Nikhil

MiNe_85951
Level 7
Level 7
Distributor - TED (Japan)
50 likes received 500 replies posted 50 solutions authored

Nikhil-san,

 

I appreciate you answering my questions.

We are considering changing the Imod settings corresponding to the temperature by checking the temperature when PSoC is started.

 

Therefore, I understand that the only way is to use this CapSense_CSDCalibrateWidget API.

 

Regars,

0 Likes
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @MiNe_85951,

Glad your query is resolved.

Please feel free to post any queries or issues you may have on Infineon products in the community and the community will be happy to help.

Regards,
Nikhil

0 Likes