<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>What does the Nordic device actually do when oversampling is selected for the ADC</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/44569/what-does-the-nordic-device-actually-do-when-oversampling-is-selected-for-the-adc</link><description>Hi 
 I used your example to try out the ADC. 
 If I have 10 or 12 bit ADC selected and I am collecting 4 samples as per the example and I select 8x oversampling I assume this effectively 32x oversampling if I add the 4 samples and divide by 4. 
 What</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 12 Mar 2019 10:11:52 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/44569/what-does-the-nordic-device-actually-do-when-oversampling-is-selected-for-the-adc" /><item><title>RE: What does the Nordic device actually do when oversampling is selected for the ADC</title><link>https://devzone.nordicsemi.com/thread/175592?ContentTypeID=1</link><pubDate>Tue, 12 Mar 2019 10:11:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9fd5fd0c-f967-40d4-b90f-e9166aeeef7b</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi Robin,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;[quote user="radams"][/quote]&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Sampling event is setup for 1ms&lt;br /&gt;With the SAMPLES_IN_BUFFER set to 1 only&lt;br /&gt;Acquisition time 10us&lt;br /&gt;ADC 10 bit&lt;br /&gt;Oversample 8x&lt;/p&gt;
&lt;p&gt;SO with the above settings I think the hw/sw will perform like this&lt;br /&gt;Every 1ms it will collect 8 samples but the result sample will be 8 samples divided by 8, is this correct ?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Yes, that is correct.&lt;/p&gt;
&lt;p&gt;If you set 8x oversampling, and 10 acq time, it will take 8 * 10 us to finish. The finished sample will then be already averaged for you.&lt;/p&gt;
&lt;p&gt;[quote user="radams"][/quote]&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;How will the samples be collected ? &lt;br /&gt; Is the acquisition window opened 8 x 10us periods and if so what is the time between each acquisition&amp;nbsp; window opening?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;It will be 8 * 10 us for this scenario.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote user="radams"]Also if I change the SAMPLES_IN_BUFFER from 1 to 4 for example &lt;br /&gt;Does this mean 4 result samples will be collected once every 1ms or does it mean there will be 4 result samples available after&amp;nbsp;4 ms.&lt;br /&gt;If all 4 result samples are collected once every 1 ms following on from previous question does that&lt;br /&gt;mean there will be 8 x 4 10us acquisition periods. IE the acquisition window opens 8 times for each result sample, meaning it opens and closes 32 times.[/quote]
&lt;p&gt;&amp;nbsp;This will mean that all 4 will be available after 1 ms, resulting in 8 x 4 *10 us period.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What does the Nordic device actually do when oversampling is selected for the ADC</title><link>https://devzone.nordicsemi.com/thread/175142?ContentTypeID=1</link><pubDate>Fri, 08 Mar 2019 20:55:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a29544e5-e83a-4a25-abd5-4470ff614b6e</guid><dc:creator>robin</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;thanks for the reply&lt;/p&gt;
&lt;p&gt;I think I understand this but just to clarify can you answer the following&lt;/p&gt;
&lt;p&gt;I am using&amp;nbsp; nRF5_SDK_15.2.0_9412b96\examples\peripheral\saadc&lt;/p&gt;
&lt;p&gt;example as the base for this, with some modification.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Sampling event is setup for 1ms&lt;br /&gt;With the SAMPLES_IN_BUFFER set to 1 only&lt;br /&gt;Acquisition time 10us&lt;br /&gt;ADC 10 bit&lt;br /&gt;Oversample 8x&lt;/p&gt;
&lt;p&gt;SO with the above settings I think the hw/sw will perform like this&lt;br /&gt;Every 1ms it will collect 8 samples but the result sample will be 8 samples divided by 8, is this correct ?&lt;/p&gt;
&lt;p&gt;How will the samples be collected ? &lt;br /&gt; Is the acquisition window opened 8 x 10us periods and if so what is the time between each acquisition&amp;nbsp; window opening?&lt;/p&gt;
&lt;p&gt;Also if I change the SAMPLES_IN_BUFFER from 1 to 4 for example &lt;br /&gt;Does this mean 4 result samples will be collected once every 1ms or does it mean there will be 4 result samples available after&amp;nbsp;4 ms.&lt;br /&gt;If all 4 result samples are collected once every 1 ms following on from previous question does that&lt;br /&gt;mean there will be 8 x 4 10us acquisition periods. IE the acquisition window opens 8 times for each result sample, meaning it opens and closes 32 times.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks Robin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What does the Nordic device actually do when oversampling is selected for the ADC</title><link>https://devzone.nordicsemi.com/thread/174971?ContentTypeID=1</link><pubDate>Fri, 08 Mar 2019 09:31:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f0ac610a-75f0-4f22-8145-5770e8838bcb</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi Robin,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;[quote user=""][/quote]&lt;/p&gt;
&lt;p&gt;If I have 10 or 12 bit ADC selected and I am collecting 4 samples as per the example and I select 8x oversampling I assume this effectively 32x oversampling if I add the 4 samples and divide by 4.&lt;/p&gt;
&lt;p&gt;What I want to know is what does selecting 8x oversampling actually do&lt;/p&gt;
&lt;p&gt;Do you take 8 samples and then provide 1 result ?&amp;nbsp; If so then I could simply take 8 samples and do the same.&lt;/p&gt;
&lt;p&gt;Or does your HW do something different ?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Yes, in your case, the hardware will do 32x samples and provide 4x samples to the application when it&amp;#39;s done.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The SAADC peripheral, when configured with 8x oversampling, will then take 8 samples for every 1 sample that is transferred to the application.&lt;/p&gt;
&lt;p&gt;When oversampling is enabled, you get a EVENTS_DONE for every sample that is taken, and a EVENTS_RESULTDONE when the oversample process is finished and the result is transferred to RAM.&lt;/p&gt;
&lt;p&gt;If BURST is not enabled, you then have to trigger the TASKS_SAMPLE 8 times in the case you have oversampling=8x, as described in the PS:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/saadc.html?cp=2_1_0_36_4_2#saadc_operationmodes_oversample"&gt;http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/saadc.html?cp=2_1_0_36_4_2#saadc_operationmodes_oversample&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>