<?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>1 micro second interrupt using timer1? Softdevice is enabled.</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/7590/1-micro-second-interrupt-using-timer1-softdevice-is-enabled</link><description>Is it possible to have 1micro second interrupt using timer 1? 
 I am unable to achieve it. 
 If I try for 4micro second, I observe toggling of pin at 8 micro seconds? 
 Why so? 
 init: 
 TIMER1-&amp;gt;TASKS_STOP = 1; /* Stop timer */ 

TIMER1-&amp;gt;MODE </description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 12 Jun 2015 08:33:25 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/7590/1-micro-second-interrupt-using-timer1-softdevice-is-enabled" /><item><title>RE: 1 micro second interrupt using timer1? Softdevice is enabled.</title><link>https://devzone.nordicsemi.com/thread/27081?ContentTypeID=1</link><pubDate>Fri, 12 Jun 2015 08:33:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4533ebf9-52b2-4513-b265-81d1480567f2</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;You haven&amp;#39;t got even a faint hope of getting that to work using a TIMER interrupt.&lt;/p&gt;
&lt;p&gt;For a start 1us is 16 clock cycles, the cortex M0 has a 16 cycle interrupt latency. So it takes all of 1us just to get the interrupt service routine entered and exited. That&amp;#39;s before any of your code is run.&lt;/p&gt;
&lt;p&gt;Secondly you say you have the softdevice enabled. That adds yet more overhead to the interrupt processing as it bounces through the bootloader and the softdevice and then to your code (the actual timings are in the softdevice spec) and when the softdevice needs to do some work, your interrupts are going to be blocked for milliseconds at at time whilst it&amp;#39;s doing stuff.&lt;/p&gt;
&lt;p&gt;Edit: I had the S110 product sheet open and looked up the extra latency caused by just having the softdevice trampoline the interrupts&lt;/p&gt;
&lt;blockquote&gt;
&lt;pre&gt;&lt;code&gt;Interrupt                        CPU cycles    Latency at 16 MHz
Open peripheral interrupt             49                 3.1 μs
&lt;/code&gt;&lt;/pre&gt;
&lt;/blockquote&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1 micro second interrupt using timer1? Softdevice is enabled.</title><link>https://devzone.nordicsemi.com/thread/27080?ContentTypeID=1</link><pubDate>Fri, 12 Jun 2015 08:02:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c1c811b7-4819-4a3d-ad7f-ce222a15284a</guid><dc:creator>JohnBrown</dc:creator><description>&lt;p&gt;I&amp;#39;m not sure that I understand what you&amp;#39;re trying to do with the TIMER1-&amp;gt;SHORTS in the IRQ.
But anyway, I would gues that the interrupt service routine takes longer than 4uS, so you&amp;#39;re only catching every other IRQ. Have you tried for an 8uS IRQ, for example, just to check that your understanding of the various values and setting is correct?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>