- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I would like to ask again about the calculation of Cs.
PSoC5LP Get Seneor Capasitance API
We refer to the project you received.
Please tell us about the number 100663 about the calculation result in the project,
Vref : 1.024V
Resolution : 16bit = 65536
*fs = 100663 / ( 1.024 / 65535 ) = 1.5
fs = 0.667
fs is "the switching voltage of the pre-charge clocks".
We understand that fs is not frequency[Hz] but voltage
Where should this value refer to a project?
Regards,
Solved! Go to Solution.
- Labels:
-
PSoC 5LP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Masashi,
We have an equation to calculate raw count,
RC/ Cs = (2^N - 1)(Fs)(Vref) / Idac (1)
The answer for your question i.e. from where the number 100663 was obtained is, by substituting the values Vref,resolution(N) and switching frequency(Fs).
The switching frequency Fs is in "Hz" and is calculated by dividing the scan time by analog switch divider.
In this case,
Fs = mod clock frequency/ analog switch divider = 24MHz/16 = 1.5MHz
Vref : 1.024V
Resolution : 16bit = 65536
Therefore,
(2^N - 1)(Fs)(Vref) = 100663
substituting this value in eq (1),
RC/Cs = 100663/Idac , where Idac = 190uA.
RC/Cs = 100663/190 =sensitivity.
Hence, Cs = RC /sensitivity
Raw count value can be obtained by using the API CapSense_sensorRaw.
Thus the value of Cs can be calculated.
We hope our information is clear kindly come back if you have any queries.
Regards
Alakananda
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Masashi,
We have an equation to calculate raw count,
RC/ Cs = (2^N - 1)(Fs)(Vref) / Idac (1)
The answer for your question i.e. from where the number 100663 was obtained is, by substituting the values Vref,resolution(N) and switching frequency(Fs).
The switching frequency Fs is in "Hz" and is calculated by dividing the scan time by analog switch divider.
In this case,
Fs = mod clock frequency/ analog switch divider = 24MHz/16 = 1.5MHz
Vref : 1.024V
Resolution : 16bit = 65536
Therefore,
(2^N - 1)(Fs)(Vref) = 100663
substituting this value in eq (1),
RC/Cs = 100663/Idac , where Idac = 190uA.
RC/Cs = 100663/190 =sensitivity.
Hence, Cs = RC /sensitivity
Raw count value can be obtained by using the API CapSense_sensorRaw.
Thus the value of Cs can be calculated.
We hope our information is clear kindly come back if you have any queries.
Regards
Alakananda
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Alakananda-san,
Thank you for you reply.
I did not understand the meaning of the "1.5" value,
I understand it by your explanation.
-- fs is described as "the switching voltage of the pre-charge clocks" but it is not a switching voltage.
-- fs is not reciprocal
-- MHz (10^6 ) is omitted.
I will be careful about the above from now on.
Regards,
Masashi