<?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>Mesh 5.0.0 high frequency timer inaccurate</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/80585/mesh-5-0-0-high-frequency-timer-inaccurate</link><description>Hello, 
 I&amp;#39;m running the nRF Mesh SDK 5.0.0 with the light CTL LC server example. I have also developed an implementation of a DALI master. DALI is a manchester encoded signal which runs at 1200baud. This means that the signal has a period of 416us. A</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 14 Oct 2021 12:58:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/80585/mesh-5-0-0-high-frequency-timer-inaccurate" /><item><title>RE: Mesh 5.0.0 high frequency timer inaccurate</title><link>https://devzone.nordicsemi.com/thread/334167?ContentTypeID=1</link><pubDate>Thu, 14 Oct 2021 12:58:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:90b48a20-e36d-4082-af13-79552516b49e</guid><dc:creator>ovrebekk</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It sounds odd that you would get interrupts for as much as 20ms. Do you know if there is flash activity in your application?&lt;/p&gt;
&lt;p&gt;Normally the only thing that would cause such long interrupts is a flash page erase.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;A long time ago we had a project internally to create an additional UART interface for situations where you didn&amp;#39;t have a dedicated UART peripheral available.&amp;nbsp;&lt;br /&gt;This example used the ADC to handle the UART RX line, by sampling the RX line at a fixed interval set by the UART baudrate (the ADC sampling rate was set around 3x the baudrate).&amp;nbsp;&lt;br /&gt;You might be able to use the same code to to receive your DALI signal, even if you have to make some changes to the code to handle the manchester decoding, and any differences in byte lengths etc that you have on the DALI bus compared to a normal UART (with 1 start and 1 stop bit).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;This example was shared in &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/40385/nrf52832-bit-band-uart-problem-19200-baudrate"&gt;this case&lt;/a&gt;, if you want to take a look at it.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;A simpler solution would be to&amp;nbsp;configure a timer in free running mode, and use two GPIOTE channels to automatically store the timer value in dedicated CC registers each time a high or low flank is detected (by connecting the GPIOTE events to capture tasks over PPI). This will not work if you are interrupted for as long as 20ms unfortunately...&lt;/p&gt;
&lt;p&gt;Best regards&lt;br /&gt;Torbjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>