<?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>nrf_drv_saadc_abort doesn&amp;#39;t raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/112138/nrf_drv_saadc_abort-doesn-t-raise-saadc-done-task</link><description>I have an application where I am using the SAADC to take ADC samples. At any point during the measurements, I want to be able to stop the samples prior to the ADC buffer filling completely. I&amp;#39;ve created a mock project of the general issue shown where</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 25 Jun 2024 11:54:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/112138/nrf_drv_saadc_abort-doesn-t-raise-saadc-done-task" /><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/490613?ContentTypeID=1</link><pubDate>Tue, 25 Jun 2024 11:54:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cbb405bc-947a-405f-bb71-8d443f131ca3</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi there,&lt;/p&gt;
&lt;p&gt;I totally forgot that you had already shared the code. I see that you start the abort task periodically by using the app timer, can you try to shorten the app timer interval to for example 900 or extend it to 3700 and see if it results in any difference on the number of samples reported when abort is called?&lt;/p&gt;
&lt;p&gt;regards&lt;br /&gt;Jared&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489556?ContentTypeID=1</link><pubDate>Wed, 19 Jun 2024 13:49:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e91d8c4f-4574-4abe-93d1-8c1afcc4888a</guid><dc:creator>LimeSlice</dc:creator><description>&lt;p&gt;See post&amp;rsquo;s original attachment&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489518?ContentTypeID=1</link><pubDate>Wed, 19 Jun 2024 12:51:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0919bd82-2845-4280-8a24-5831066f7bd6</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;How are you aborting the sampling, how is it triggered, can you show me the code? I&amp;#39;m not 100% sure, but I would expect it to report the exact number of samples in that interval even though it didn&amp;#39;t manage to sample all enabled channels,&lt;/p&gt;
&lt;p&gt;regards&lt;/p&gt;
&lt;p&gt;Jared&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489351?ContentTypeID=1</link><pubDate>Tue, 18 Jun 2024 14:53:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:20bcb8ee-c772-4a14-bb17-a0694f4eeebc</guid><dc:creator>LimeSlice</dc:creator><description>&lt;p&gt;This is true that this works to get the last frame&amp;#39;s number of samples. However, my 512 measurements are occurring from my SAADC being connected to a timer through the PPI to measure at a specific frequency. With this, each measurement is triggering a START then STOP event in the SAADC. Consequently, when I call&lt;span style="font-family:courier new, courier;"&gt; nrf_saadc_amount_get()&lt;/span&gt; to read the RESULT.AMOUNT register, I am only receiving a value from the last measurement interval. For example, I have 3 SAADC channels, so whenever I read RESULT.AMOUNT, my value is either 3 or occasionally 6.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489322?ContentTypeID=1</link><pubDate>Tue, 18 Jun 2024 13:15:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f6571e09-8fc1-4bc0-a144-9ac0d06f3c98</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;When you call&amp;nbsp;nrfx_saadc_abort() it will effectively call trigger the&amp;nbsp;NRF_SAADC_TASK_STOP task which will eventually result in the&amp;nbsp;EVENTS_STOPPED to be generated. When that event has been generated, you can check the&amp;nbsp;RESULT.AMOUNT register to see how many samples that has been transferred to RAM.&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;regards&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Jared&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489131?ContentTypeID=1</link><pubDate>Mon, 17 Jun 2024 13:53:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cc80e243-5733-4f1a-a878-fd537bbbeab0</guid><dc:creator>LimeSlice</dc:creator><description>&lt;p&gt;Thanks &lt;a href="https://devzone.nordicsemi.com/members/jared"&gt;Jared&lt;/a&gt; for the info!&lt;/p&gt;
&lt;p&gt;I need to be able to cause an early stop using while still knowing how many samples were taken during the period before &lt;span style="font-family:courier new, courier;"&gt;nrfx_saadc_abort&lt;/span&gt; was called. For example, my sampling period fills a buffer of 512 ADC measurements. If the abort is called and only 300 measurements were taken, I need to know this number and be able to still convert the 300 measurements with &lt;span style="font-family:courier new, courier;"&gt;nrfx_saadc_buffer_convert&lt;span style="font-family:arial, helvetica, sans-serif;"&gt;. Do you have a suggestion on how I would accomplish this if &lt;span style="font-family:courier new, courier;"&gt;nrfx_saadc_abort&lt;/span&gt; does not propogate the HW event to the application?&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/489086?ContentTypeID=1</link><pubDate>Mon, 17 Jun 2024 11:48:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b8458d21-69cf-4256-809f-a35f3a22d05e</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m guessing that your basing your assumption on this comment regarding the driver function:&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1718624262681v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;NRFX_SAADC_EVT_DONE is a HW event that isn&amp;#39;t propagated to the application in this case. Calling nrfx_saadc_abort() will trigger the task&amp;nbsp;NRF_SAADC_TASK_STOP which again will generate the&amp;nbsp;NRF_SAADC_EVENT_STOPPED.&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;regards&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Jared&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf_drv_saadc_abort doesn't raise SAADC DONE task</title><link>https://devzone.nordicsemi.com/thread/488910?ContentTypeID=1</link><pubDate>Fri, 14 Jun 2024 16:40:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:00c80707-b2fc-4d46-b855-b01c2f824053</guid><dc:creator>LimeSlice</dc:creator><description>&lt;p&gt;A little more info: I do observe the SAADC stop sampling, but I am not receiving a &lt;span style="font-family:courier new, courier;"&gt;NRF_DRV_SAADC_EVT_DONE SAADC&lt;/span&gt; event in my &lt;span style="font-family:courier new, courier;"&gt;saadc_callback&lt;/span&gt; handler as I would expect.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>