<?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>Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/90247/dali-bitbang-timer-deviates</link><description>Hi, 
 I am trying to build a Dali driver for the nRF52 with nRF Connect SDK. In the current approach, the Dali signal is send on the bus with a bit-banging approach using Zephyr&amp;#39;s GPIO library and an nRFx timer. To summarize Dali, the data is sent with</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 04 Apr 2023 09:28:22 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/90247/dali-bitbang-timer-deviates" /><item><title>RE: Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/thread/418999?ContentTypeID=1</link><pubDate>Tue, 04 Apr 2023 09:28:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c4519f45-fbb2-43ec-8e18-f86c7a2057fd</guid><dc:creator>Tomlee</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote userid="116211" url="~/f/nordic-q-a/90247/dali-bitbang-timer-deviates/378945"]To send two half-bits of the same value in a row, I used the timer cc event to disable the PPI channel&amp;nbsp;that connects the two&amp;nbsp;and re-enable it in the next event.[/quote]
&lt;p&gt;May I know how to do this?&amp;nbsp; could you show me your code&amp;nbsp; , please&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/thread/417840?ContentTypeID=1</link><pubDate>Tue, 28 Mar 2023 09:27:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9dc451c7-0c09-49dc-bfe2-e876720d6a17</guid><dc:creator>Tomlee</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;I also met this problem(the dali timming is interrupt when blue mesh is always publishing data),&amp;nbsp; &amp;nbsp;could you show me your souce code, please?&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;I just follow the ..\examples\peripheral\gpiote example,&amp;nbsp; &amp;nbsp;but I don&amp;#39;t know how to use gpiote task to change tx_pin value,&amp;nbsp; &amp;nbsp;for example ,&amp;nbsp; I want to send 0x23, then how to set in this example?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/thread/378961?ContentTypeID=1</link><pubDate>Wed, 27 Jul 2022 14:50:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:34b9a02a-c586-4394-b1a2-54ea8a29e7ba</guid><dc:creator>Kenneth</dc:creator><description>[quote user="tim-remoticom"]To send two half-bits of the same value in a row, I used the timer cc event to disable the PPI channel&amp;nbsp;that connects the two&amp;nbsp;and re-enable it in the next event.[/quote]
&lt;p&gt;Good idea, and good to hear it works!&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/thread/378945?ContentTypeID=1</link><pubDate>Wed, 27 Jul 2022 14:08:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b4ab0feb-9808-43c8-9439-7043b8e0243d</guid><dc:creator>tim-remoticom</dc:creator><description>&lt;p&gt;Hi Kenneth,&lt;br /&gt;Thanks for the quick response. I created a toggling GPIOTE task and connected it to a timer&amp;nbsp;cc event, and I got very accurate results (&amp;lt;100ns).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;To send two half-bits of the same value in a row, I used the timer cc event to disable the PPI channel&amp;nbsp;that connects the two&amp;nbsp;and re-enable it in the next event.&lt;/p&gt;
&lt;p&gt;Thanks again.&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Tim&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dali bitbang timer deviates</title><link>https://devzone.nordicsemi.com/thread/378107?ContentTypeID=1</link><pubDate>Thu, 21 Jul 2022 13:09:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5e6b55ed-3f1b-4f89-9c13-c28752021351</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I suspect some house keeping by the zephyr rtos that cause delay to the timer execution. Using nrfx directly I suspect will give the same result, though maybe a bit less both in terms of delay caused and the&amp;nbsp;occurance rate.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;But if you were to prepare next pin toggling by configuring a gpiote task and a timer CC[] event that would trigger the gpiote task, then I don&amp;#39;t really see any way that should fail, since you can then prepare (from your description) up to 400us before it needs to be triggered. The CC[] event that triggered the GPIOTE toggle can also be for the next&amp;nbsp;TIMER interrupt.&lt;/p&gt;
[quote user=""]Or would it be a good option to use SPI at 2400bps and leave all pins except for MOSI unconnected? For this the concern is that as part of the multi-master specification,&amp;nbsp;the device must read back the value it set on the bus to detect if there is a collision.[/quote]
&lt;p&gt;You can connect a small resistor (1khom) on the MOSI pin to the MISO pin, and the MISO pin is then connected directly to the peer. Then if you setup a SPI transfer with empty rx_buf, then you should get the same data in rx_buf as tx_buf if there are no collisions (though may consider running SPI on higher datarate to check for potentially collissions), ref setup:&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/pastedimage1658408382004v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;CLK must be defined to a pin even if not connected physically to anything.&lt;/p&gt;
&lt;p&gt;Hope that helps,&lt;br /&gt;Kenneth&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>