<?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>Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities</link><description>Hello! 
 I use NRF Connect SDK 1.8.0, but peripherials are configured using nrfx library. 
 My task is to implement serial interface where I have PIN_TX and PIN_RX. I transmit data over PIN_TX, when I&amp;#39;m transmitting data on PIN_TX I&amp;#39;ve got feedback on</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 18 Oct 2022 18:51:19 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities" /><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/391291?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 18:51:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2c221a6e-199b-4992-9a63-03a61501794b</guid><dc:creator>trafficode</dc:creator><description>[quote userid="6207" url="~/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities/391095"] I can mark this thread as verified so that it can help others if that is ok?[/quote]
&lt;p&gt;Yeap :)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/391290?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 18:50:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:29e2a596-772e-4564-b728-867b25381113</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;It works for me too :) thx&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/391265?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 15:22:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:20378e5d-dbaf-4f79-8d3b-85b99b2f7106</guid><dc:creator>hmolesworth</dc:creator><description>&lt;p&gt;&lt;span&gt;I also had trouble for &amp;quot;Reply&amp;quot; or &amp;quot;More&amp;quot; for years, then found that by shrinking the display with Ctrl&amp;#39;-&amp;#39; (Ctrl Minus) all the &amp;quot;Reply&amp;quot; and &amp;quot;More&amp;quot; buttons magically appear. Then after selecting &amp;quot;Reply&amp;quot; I enlarge with Ctrl&amp;#39;+&amp;#39; so I can read easily&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/391095?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 07:41:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f5df2cc2-0f78-4447-a228-83bcb64cd172</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="trafficode"]Is there something wrong with buttons &amp;quot;Reply&amp;quot; &amp;quot;Verify Answer&amp;quot; and &amp;quot;More&amp;quot; at the bottom of posts...? Sometimes they appear but sometimes don&amp;#39;t...[/quote]
&lt;p&gt;I have noticed that sometimes too. I&amp;#39;ll report that internally. Thanks for the feedback. Since this is a public case, I can mark this thread as verified so that it can help others if that is ok?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/391087?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 06:56:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fe77ad5c-98ec-48ef-96cd-09cb9f4cfd98</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;Now it&amp;#39;s clear. But I did about 20k erase/write cycles and still below 5ms on nrf52832 - but of course it could be not a rule.&lt;/p&gt;
&lt;p&gt;Thank You for help!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Question from a different barrel...&lt;/p&gt;
&lt;p&gt;Is there something wrong with buttons &amp;quot;Reply&amp;quot; &amp;quot;Verify Answer&amp;quot; and &amp;quot;More&amp;quot; at the bottom of posts...? Sometimes they appear but sometimes don&amp;#39;t...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/390893?ContentTypeID=1</link><pubDate>Mon, 17 Oct 2022 06:43:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:00b49d59-b76c-4cc3-bdbd-1280594e11ee</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="trafficode"] To this day I was sure that there is no sdk_config.h in NRF Connect SDK, where should I looking for this file?[/quote]
&lt;p&gt;Sorry no, there is no sdk_config.h file in nRF Connect SDK and I got confused answering threads on both SDKs. These settings are the default from the template project you took for your project or this settings must have been set in the proj.conf.&amp;nbsp;&lt;/p&gt;
[quote user="trafficode"]Should I expect that this erase time for both cpu&amp;#39;s(nrf52832 and nrf52833) can be in this range...??? Let&amp;#39;s say, it is possible that on some pieces with nrf52832 erase can take 80ms and on some pieces on nrf52833 can take 5ms???[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I had found some older discussions on this and this info was new to me aswell. So to answer your question,&amp;nbsp;&lt;/p&gt;
&lt;div&gt;the flash in nRF52832 is a special one. it has a variable erase time per page, between 2 and 80-something ms. This is based on the flash wear of each page. This means that in the beginning of the specific nRF52832 lifetime, the erasetime is quicker, and after doing X amount of erase cycles, it will become slower. Other nRF52-series devices have a fixed erase time.&amp;nbsp;&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/390159?ContentTypeID=1</link><pubDate>Tue, 11 Oct 2022 07:13:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb214319-bfd8-4a48-a8df-b9e2b24a5f81</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;Let&amp;#39;s not focus on the case with ble enabled. To this day I was sure that there is no sdk_config.h in NRF Connect SDK, where should I looking for this file? That&amp;#39;s the option and I&amp;#39;m still not sure that I&amp;#39;ll enable ble in production version, right now it&amp;#39;s only to make debug easier.&lt;/p&gt;
&lt;p&gt;One more time... I&amp;#39;m developing two projects right now. One of them is based on nrf52832, there I have about 50 pieces. Within all of them, flash erase time not exceed 5ms. Second project is based on nrf52833 and flash erase time is about 80ms.&lt;/p&gt;
&lt;p&gt;Documentation say, that erase time on nrf52 can take ~2-90ms(if I remember well). 5ms and 80ms are in this range. It&amp;#39;s a bit wierd that on 50 pieces with nrf52832 it is 5ms but it is so much more using nrf52833.&lt;/p&gt;
&lt;p&gt;Should I expect that this erase time for both cpu&amp;#39;s(nrf52832 and nrf52833) can be in this range...??? Let&amp;#39;s say, it is possible that on some pieces with nrf52832 erase can take 80ms and on some pieces on nrf52833 can take 5ms???&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/390137?ContentTypeID=1</link><pubDate>Tue, 11 Oct 2022 05:33:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:797eae54-3864-4e2c-8227-7bf147d3a9af</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="trafficode"]&lt;p&gt;# RC as Low Frequency clock&lt;br /&gt;CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC=y&lt;br /&gt;CONFIG_CLOCK_CONTROL_NRF_K32SRC_250PPM=y&lt;/p&gt;
&lt;p&gt;But, like I mention before, currently I&amp;#39;m developing two projects parallel. One of them is based on nrf52832 and second one use nrf52833. Clock source type, configuration and hardware close around those cpu are the same. And on nrf52832, erase and write takes max 6ms in case of nrf52833 erase and write takes about 100ms. I use the same zephyr&amp;#39;s api and I use storage partition&lt;/p&gt;[/quote]
&lt;p&gt;You mentioned that you enabled Bluetooth functionality by enabling the softdevice (BLE protocol stack). If you are using RC as your LFCLK for the softdevice (check&amp;nbsp;&lt;span&gt;NRF_SDH_CLOCK_LF_SRC in your sdk_config.h file) then the softdevice also starts the calibration of this clock based on the calibration configuration that is set in the same file (sdk_config.h). This calibration is triggered at regular intervals as mentioned in&amp;nbsp;NRF_SDH_CLOCK_LF_RC_CTIV or if the temperature of the chip changes. This is very time consuming process (sometimes can take 80ms based on how many rounds of calibration is needed to bring the LF RC clock back to same accuracy). Also flash erase does not happen during an on going radio activity. If your flash operation is requested&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;span&gt;During the calibration process or&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;During on going BLE activity (while radio being active) then&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;span&gt;the flash operation is queued until the above operation is first completed.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If you see different times of flash completions then it most likely is due to you using internal RC for your LFCLK for the softdevice. If you have XTAL LFCLK, change the configuration in&amp;nbsp;NRF_SDH_CLOCK_LF_SRC and&amp;nbsp;CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC so that you use XTAL instead of RC. The calibration time can differ for the chips of the same product type and version.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/390045?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 13:26:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:55caafeb-66e6-4c8e-9eb0-90ffa0eb180d</guid><dc:creator>trafficode</dc:creator><description>[quote userid="6207" url="~/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities/390025"]In anycase, you should not create a system which is that time critical as this and give the same priorities to both modules. There are good enough depth of priorities that you can use on the interrupts to solve this problem.[/quote]
&lt;p&gt;I understand.&amp;nbsp;This problem like I said is fixed and hundred of thousand tests passed. Worst thing for is flash issue that I mention few posts above. &lt;a href="https://devzone.nordicsemi.com/members/aryan"&gt;Susheel Nuguru&lt;/a&gt;&amp;nbsp;Please take a look on them and give me some answer. Big thank You for Your help.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/390025?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 13:07:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bb0f217a-fd0b-4b88-bf2f-c489cf6a2d86</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;In the case that you have one event that can&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;has the interrupt enabled with respect to that event and&lt;/li&gt;
&lt;li&gt;the same event is connected to gpiote and the gpiote interrupt also enabled&amp;nbsp;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;then there is no guarantee in the order in which the actual interrupt from the timer or gpiote were pended to the ARM NVIC registers. It is possible that there is implementation specific delays which are most of the time consistent in the order they are fired and rarely they can be different.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Also, it is not clear what the ARM cortex M4 does when two different NVIC bits are set at once? then the NVIC has to break a tie using the hardware priorities. It might be possible that the GPIOTE (peripheral index 6) be having higher priority in the tie breaking scenarios with Timer (peripheral id 8).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;In anycase, you should not create a system which is that time critical as this and give the same priorities to both modules. There are good enough depth of priorities that you can use on the interrupts to solve this problem.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/389959?ContentTypeID=1</link><pubDate>Mon, 10 Oct 2022 09:18:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:57732382-d55b-41a1-aacb-542f969c969c</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;To be honest, I really need answer what is a time that I have to assume for erasing and writing page... Is that &amp;lt;5ms like it is in case of usage nrf52832 or should I also expect time about 100ms for this cpu... Using ble couse longer time of operation on flash... so, there is some lock/mutex used on flash driver layer, can I access to this mutex make my code more safety?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/389188?ContentTypeID=1</link><pubDate>Tue, 04 Oct 2022 11:41:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b9c2ee05-c32b-49c7-b026-3c42c026df0b</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;When RADIO(bluetooth) is added to project, then erase page time is not const and it is between 90-180ms(20 trys) when no bluetooth enabled this is constant 87ms.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m using RC HF CLOCK, in project configuration file I have those two lines:&lt;/p&gt;
&lt;p&gt;# RC as Low Frequency clock&lt;br /&gt;CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC=y&lt;br /&gt;CONFIG_CLOCK_CONTROL_NRF_K32SRC_250PPM=y&lt;/p&gt;
&lt;p&gt;But, like I mention before, currently I&amp;#39;m developing two projects parallel. One of them is based on nrf52832 and second one use nrf52833. Clock source type, configuration and hardware close around those cpu are the same. And on nrf52832, erase and write takes max 6ms in case of nrf52833 erase and write takes about 100ms. I use the same zephyr&amp;#39;s api and I use storage partition&lt;br /&gt;storage_partition: partition@7a000 {&lt;br /&gt; label = &amp;quot;storage&amp;quot;;&lt;br /&gt; reg = &amp;lt;0x0007A000 0x00006000&amp;gt;;&lt;br /&gt; };&lt;br /&gt;I have tested this erase time on dk too, and results are the same as withim our custom board.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/389179?ContentTypeID=1</link><pubDate>Tue, 04 Oct 2022 11:13:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:862e6918-53cf-46a5-9830-00f3a50d279d</guid><dc:creator>trafficode</dc:creator><description>&lt;p&gt;I can&amp;#39;t do it in that way. Those &amp;quot;external effects&amp;quot; - You mean feedback delay... are desirable. It depends on kind of used hardware layer to implement this type of serial interface. In this way there is 1us delay but there is also another usage/hardware where is 80us and this problem not occur.&lt;/p&gt;
&lt;p&gt;Like I said. I have implemented &amp;quot;temporary&amp;quot; solution and problem isn&amp;#39;t occure right now. I didn&amp;#39;t tests this with nrf_power_task_trigger(NRF_POWER, NRF_POWER_TASK_CONSTLAT) yet, maybe problem won&amp;#39;t occure.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/389070?ContentTypeID=1</link><pubDate>Mon, 03 Oct 2022 17:38:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:84d93c20-91b9-437f-bc00-0675996a4b30</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;I should have asked you this in the very beginning, but before I test this I need to know if this is on custom hardware or on our nRF52833 DK? If you are using custom hardware and If you have not already tested this on the DK, I would recommend you to test it first on DK to see if it is the same behavior.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/389045?ContentTypeID=1</link><pubDate>Mon, 03 Oct 2022 15:38:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b5d9b3aa-32ab-4f10-8683-63a07a3ee9c5</guid><dc:creator>hmolesworth</dc:creator><description>&lt;p&gt;There is a simple test you can do to isolate the external effects of the TX_PIN and RX_PIN&amp;nbsp; connection (which includes pin capacitance) by using internal loopback. Change the RX_PIN to instead use TX_PIN (this works, I use it on serial loopback testing) and enable the input thus:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;    nrf_gpio_cfg(TX_PIN, NRF_GPIO_PIN_DIR_OUTPUT, NRF_GPIO_PIN_INPUT_CONNECT, NRF_GPIO_PIN_NOPULL, NRF_GPIO_PIN_H0H1, NRF_GPIO_PIN_NOSENSE);
&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/388985?ContentTypeID=1</link><pubDate>Mon, 03 Oct 2022 12:04:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:01b3eced-87aa-4519-a7b9-2e22ab020597</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="trafficode"]There is one another thing that can has same influence here... I noticed that when I excluded ble stack from project some another latency is provided to measuring distance between edges... Solution that I found is to set&amp;nbsp;NRF_POWER-&amp;gt;TASKS_CONSTLAT = 1. Then measuring is much more accurate. What is the way to configure this in right way, is there some zephyr api to this or some nrfx library api to configure this... What are all consequences of setting this to 1...?[/quote]
&lt;p&gt;There is the nRFX library where you can use&amp;nbsp;&lt;span&gt;nrf_power_task_trigger&lt;/span&gt;&lt;span&gt;(NRF_POWER, NRF_POWER_TASK_CONSTLAT). There is no other API tapping into this functionality of constlat register.&lt;/span&gt;&lt;/p&gt;
[quote user="trafficode"]Next issue is connected with erasing/writing flash memory. I&amp;#39;m developing projects based on nrf52832 and nrf52833, erasing page on first of them takes 2ms but on second of them above 80ms! I found information that this operation can take from 2 - 90 ms on nrf52 mcu&amp;#39;s. It means that it depends on cpu production series, every cpu can have this time in range(2, 90), or maybe there is some way configure this time?[/quote]
&lt;p&gt;Is there any RADIO activity while requesting the flash erase? it should not be that much difference in time Which HFLCK are you using? is it XTAL or internal RC HFCLK?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/388470?ContentTypeID=1</link><pubDate>Thu, 29 Sep 2022 07:28:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c321ad9-fb28-4f38-9b39-b59a6201a9ad</guid><dc:creator>trafficode</dc:creator><description>[quote userid="6207" url="~/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities/386624"]On &lt;a href="https://community.arm.com/arm-community-blogs/b/embedded-blog/posts/cutting-through-the-confusion-with-arm-cortex-m-interrupt-priorities"&gt;ARM Cortex M4&lt;/a&gt;&amp;nbsp;same priority interrupts cannot pre-empt an existing interrupt with same priority. Are you toggling some gpios that are connected to compare event to measure the distance or do you rely on interrupt service routines for few measurements?[/quote]
&lt;p&gt;I&amp;#39;m doing this to measure&amp;nbsp;the&amp;nbsp;distance between edges and in interrupt service runtime I&amp;#39;m verifying if this distance is proper...&lt;/p&gt;
[quote userid="6207" url="~/f/nordic-q-a/92043/timer-and-gpiote-interrupts-priorities/386624"]I am quite confident that there is no known problem in context prioritizing within ARM controller.&amp;nbsp;&lt;br /&gt;I need to understand more on how you concluded that it could be priority issue. If you have ISR involved in any of these measurements, then I can say that the timings of ISR running are not the same as the timings of interrupt happening.[/quote]
&lt;p&gt;I think that this issue is not connected with strictly ARM related implementation couse to triger on compare pin toggle we need to engage gpiote task and ppi peripherials... And this latency can be generated here in my opinion...&lt;/p&gt;
&lt;p&gt;I can resolve this issue by using some software trick&amp;nbsp;and by setting timer iqr priority to higher than gpio.&lt;/p&gt;
&lt;p&gt;&lt;span&gt;There is one another thing that can has same influence here... I noticed that when I excluded ble stack from project some another latency is provided to measuring distance between edges... Solution that I found is to set&amp;nbsp;NRF_POWER-&amp;gt;TASKS_CONSTLAT = 1. Then measuring is much more accurate. What is the way to configure this in right way, is there some zephyr api to this or some nrfx library api to configure this... What are all consequences of setting this to 1...?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Next issue is connected with erasing/writing flash memory. I&amp;#39;m developing projects based on nrf52832 and nrf52833, erasing page on first of them takes 2ms but on second of them above 80ms! I found information that this operation can take from 2 - 90 ms on nrf52 mcu&amp;#39;s. It means that it depends on cpu production series, every cpu can have this time in range(2, 90), or maybe there is some way configure this time?&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Timer and GPIOTE interrupts priorities</title><link>https://devzone.nordicsemi.com/thread/386624?ContentTypeID=1</link><pubDate>Fri, 16 Sep 2022 11:48:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b41e7657-6040-478a-8d3c-1dbb503c5a36</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user=""]* Interrupt can interrupt other interrupt with the same priority? (to this day I have been convinced that it is not)[/quote]
&lt;p&gt;On &lt;a href="https://community.arm.com/arm-community-blogs/b/embedded-blog/posts/cutting-through-the-confusion-with-arm-cortex-m-interrupt-priorities"&gt;ARM Cortex M4&lt;/a&gt;&amp;nbsp;same priority interrupts cannot pre-empt an existing interrupt with same priority. Are you toggling some gpios that are connected to compare event to measure the distance or do you rely on interrupt service routines for few measurements?&lt;/p&gt;
&lt;p&gt;This is purely ARM related implementation and I have not heard that there is a bug in priority handling in such contexts.&amp;nbsp;&lt;/p&gt;
[quote user=""]* Is that mybe known problem and there is some solution to fix it? I have not so big experience with nrf52. I have never had similar situation when I was working with stm32...[/quote]
&lt;p&gt;I am quite confident that there is no known problem in context prioritizing within ARM controller.&amp;nbsp;&lt;br /&gt;I need to understand more on how you concluded that it could be priority issue. If you have ISR involved in any of these measurements, then I can say that the timings of ISR running are not the same as the timings of interrupt happening.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>