<?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>PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/123803/pwm-spike-on-starting-stopping-on-all-channels</link><description>Hello there, 
 
 we&amp;#39;re using multiple pwm-channels of one module of the nRF54L15 for different purposes (multiple motors, h-bridge control; depending on the project). 
 When the first channel is being turned on or the last channel is being turned off</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 10 Sep 2025 10:51:36 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/123803/pwm-spike-on-starting-stopping-on-all-channels" /><item><title>RE: PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/thread/548346?ContentTypeID=1</link><pubDate>Wed, 10 Sep 2025 10:51:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:77388817-d998-47eb-9cc3-436c5f8cb66b</guid><dc:creator>Sigurd</dc:creator><description>[quote user="max00"]thank you very much for the feedback - I just tested it myself and it looks great now![/quote]
&lt;p&gt;Great!&lt;/p&gt;
[quote user="max00"]Do you have any idea what change fixed this? Just out of curiosity![/quote]
&lt;p&gt;I believe it was fixed with this commit here:&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-zephyr/commit/c1d7194e05c3798e2acc6a461247eb20e5d27a0a"&gt;https://github.com/nrfconnect/sdk-zephyr/commit/c1d7194e05c3798e2acc6a461247eb20e5d27a0a&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/thread/548336?ContentTypeID=1</link><pubDate>Wed, 10 Sep 2025 09:44:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:68d06bd9-5155-41e5-8bcb-90f3cce0a202</guid><dc:creator>marcoster</dc:creator><description>&lt;p&gt;Hi Sigurd,&lt;/p&gt;
&lt;p&gt;thank you very much for the feedback - I just tested it myself and it looks great now!&lt;/p&gt;
&lt;p&gt;Do you have any idea what change fixed this? Just out of curiosity!&lt;/p&gt;
&lt;p&gt;Best regards&lt;br /&gt;Marco&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/thread/548329?ContentTypeID=1</link><pubDate>Wed, 10 Sep 2025 09:04:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2181b222-41f4-411f-b2b2-1f794cdf7041</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;span&gt;Marco,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Could you try with NCS v3.1.0, and see if the issue is solved there?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I&amp;#39;m seeing some strange spikes with&amp;nbsp;NCS 3.0.2, but not with&amp;nbsp;NCS 3.1.0&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;NCS 3.0.2&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/pastedimage1757494673684v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;NCS 3.1.0&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/pastedimage1757494718115v2.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Sigurd&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/thread/546037?ContentTypeID=1</link><pubDate>Tue, 19 Aug 2025 11:57:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6653bb8d-11df-455b-84b7-9bf65cb82546</guid><dc:creator>marcoster</dc:creator><description>&lt;p&gt;Hi there,&lt;br /&gt;another Update from my side - I have a minimal test-project to test this attached to this post.&lt;br /&gt;&lt;br /&gt;I also tested this on an nRF52840 and I can still see a small spike, although it does only get up to about 0.3V.&lt;br /&gt;&lt;br /&gt;Here a screenshot of the nRF52840 result from the testproject:&lt;br /&gt;&lt;img style="max-height:360px;max-width:480px;" alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/960x720/__key/communityserver-discussions-components-files/4/LeCroy6.png" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;And from the nRF54L15:&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:480px;" alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/960x480/__key/communityserver-discussions-components-files/4/LeCroy9.png" /&gt;&lt;/p&gt;
&lt;p&gt;Note that Channel 2 is set to 500mV/div to better see the spike especially on the nRF52840.&lt;/p&gt;
&lt;p&gt;I also just realized, that the dts-overlay on the nRF52840 probably doesn&amp;#39;t deactivate polarity-inversion - so this might be the reason for different default pin-level on Channel 1.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/pwm_5F00_spike_5F00_test.zip"&gt;devzone.nordicsemi.com/.../pwm_5F00_spike_5F00_test.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The code was tested on:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;nRF52840-DK (1.0.0)&lt;/li&gt;
&lt;li&gt;nRF54L15-DK (0.9.2)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Hope this helps to reproduce this!&lt;/p&gt;
&lt;p&gt;Best regards&lt;br /&gt;Marco&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: PWM Spike on starting/stopping on all channels</title><link>https://devzone.nordicsemi.com/thread/545999?ContentTypeID=1</link><pubDate>Tue, 19 Aug 2025 07:18:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4c024288-1625-495b-a164-49349ed0dee1</guid><dc:creator>marcoster</dc:creator><description>&lt;p&gt;Forgot this in the example-code:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static const struct gpio_dt_spec m_motor_common_lowside = GPIO_DT_SPEC_GET(DT_NODELABEL(motor_common_lowside), gpios);
static const struct gpio_dt_spec m_motor1_minus_lowside = GPIO_DT_SPEC_GET(DT_NODELABEL(motor1_minus_lowside), gpios);

static const struct pwm_dt_spec m_motor_common_highside = PWM_DT_SPEC_GET(DT_NODELABEL(motor_common_highside));
static const struct pwm_dt_spec m_motor1_minus_highside = PWM_DT_SPEC_GET(DT_NODELABEL(motor1_minus_highside));

struct hbridge_pair {
    const struct pwm_dt_spec  *active_pwm;
    const struct pwm_dt_spec  *inactive_pwm;
    const struct gpio_dt_spec *active_gpio;
    const struct gpio_dt_spec *inactive_gpio;
};

static const struct hbridge_pair m_bridge_pairs[NUM_MOTOR_DRIVE] = {
    [MOTOR_DRIVE_LEFT]  = { .active_pwm = &amp;amp;m_motor1_minus_highside, .active_gpio = &amp;amp;m_motor_common_lowside, .inactive_pwm = &amp;amp;m_motor_common_highside, .inactive_gpio = &amp;amp;m_motor1_minus_lowside },
    [MOTOR_DRIVE_RIGHT] = { .active_pwm = &amp;amp;m_motor_common_highside, .active_gpio = &amp;amp;m_motor1_minus_lowside, .inactive_pwm = &amp;amp;m_motor1_minus_highside, .inactive_gpio = &amp;amp;m_motor_common_lowside },
};

&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>