<?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>NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/69215/nrf52840-spim3-sck-not-pluse</link><description>SCK:P014 
 MOSI:P016 
 MISO:P015 
 CS:P017(SOFT) 
 nrf_gpio_cfg(SCK, NRF_GPIO_PIN_DIR_OUTPUT, NRF_GPIO_PIN_INPUT_DISCONNECT, NRF_GPIO_PIN_NOPULL, NRF_GPIO_PIN_H0H1, NRF_GPIO_PIN_NOSENSE); nrf_gpio_cfg(MOSI, NRF_GPIO_PIN_DIR_OUTPUT, NRF_GPIO_PIN_INPUT_DISCONNECT</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 28 Jan 2021 16:25:53 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/69215/nrf52840-spim3-sck-not-pluse" /><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/291857?ContentTypeID=1</link><pubDate>Thu, 28 Jan 2021 16:25:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1af0f4f9-7b09-41b2-a4a8-e3f459057245</guid><dc:creator>Brian Shankland</dc:creator><description>&lt;p&gt;More information:&lt;/p&gt;
&lt;p&gt;I found that SPIM3 would work within the first 5 seconds from power-up which I assume is because lots of activity was happening and it had not entered any low-power mode.&lt;/p&gt;
&lt;p&gt;If I waited 15 seconds when the power had dropped to under 3uA the SPIM would run the transfers but no signals were on the IO lines. SPIM2 would work under similar timing conditions.&lt;/p&gt;
&lt;p&gt;I later thought about that I was using TWIM0 for a temperature&amp;nbsp;reading so changed the code to stop this, and suddenly SPIM3 would work.&lt;/p&gt;
&lt;p&gt;When I was reading temperatured the order of Init / Unint was:&lt;/p&gt;
&lt;p&gt;SPIM3 Init - TWIM0 Init - TWIM0 UnInit - SPIM3 Uninit&lt;/p&gt;
&lt;p&gt;I changed this so that SPIM3 would only Init after the temperature reading thus:&lt;/p&gt;
&lt;p&gt;&lt;span&gt;TWIM0 Init - TWIM0 UnInit - SPIM3 Init - SPIM3 Uninit&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;And now it works okay.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Looks like there may be some internals messing the SPIM3 Pin assignments during TWIM0 Init or Uninit - very strange but its what the current evidence&amp;nbsp;currently suggests.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/291843?ContentTypeID=1</link><pubDate>Thu, 28 Jan 2021 15:23:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f6fa81fd-0629-4baa-8c7d-4f2cb0edd2b3</guid><dc:creator>LBM@DEMCON</dc:creator><description>&lt;p&gt;I am having the exact same problem. Thank you very much for the suggestion of UART0 being related, that allowed me to solve the problem. After some digging, I now call nrf_drv_uart_init for UART0 with the default config, which magically makes SPIM3 work.&lt;/p&gt;
&lt;p&gt;Note that I also have a BL654 module lying around, which is based on the nRF52840. The BL654 does not have this issue. Either that, or it has to do with the nRF bootloader (I don&amp;#39;t have a bootloader on the BL654).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/291477?ContentTypeID=1</link><pubDate>Wed, 27 Jan 2021 11:35:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:99310445-0bf9-43d8-8bf3-e80ef63c4aea</guid><dc:creator>Brian Shankland</dc:creator><description>&lt;p&gt;I had noticed that many of the examples SDK_Configs did not have the SPIM3 supported but found one that did as a template. Could you share yours here for comparison.&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t think this is my problem since it works when other peripherals are connected, just not in low power&amp;nbsp; / sleep situations.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/291405?ContentTypeID=1</link><pubDate>Wed, 27 Jan 2021 03:17:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cead1a9e-dbed-4cfb-8304-faf7bb068a92</guid><dc:creator>Maksym Galemin</dc:creator><description>&lt;p&gt;Just an update, apparently my issue was related to a misconfiguration in my&amp;nbsp;sdk_config.h file. After checking my configuration against the one from the &amp;quot;examples\peripheral\nrfx_spim\pca10056\blank\config\sdk_config.h&amp;quot; file and removing some unnecessary stuff like SPI3 etc. it finally worked as expected.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/290781?ContentTypeID=1</link><pubDate>Fri, 22 Jan 2021 14:34:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:23530a9b-e1a0-4af8-a896-cb0e85832260</guid><dc:creator>Brian Shankland</dc:creator><description>&lt;p&gt;Yes can confirm wsl&amp;#39;s observation.&lt;/p&gt;
&lt;p&gt;When I change to using SPIM2 on 8MHz with no hardware handshaking I can read the registers from the device, but on switching back to SPIM3 it fails.&lt;/p&gt;
&lt;p&gt;We need to use SPIM3 for the faster baud rates and hardware chip selects so a resolution to this is now critical.&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t see anything relating to this in the errata document for this specific issue with SPIM3 but with the other internal problems it has, maybe it needs some other peripheral to be powered up for it to function?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/290754?ContentTypeID=1</link><pubDate>Fri, 22 Jan 2021 13:04:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:39a0f781-80da-46c3-885f-3feda9ce0041</guid><dc:creator>Brian Shankland</dc:creator><description>&lt;p&gt;Has there been any progress on this issue as I also think that our board is suffering the same problem.&lt;/p&gt;
&lt;p&gt;We had been using SPIM3 for the past 2 months, but once we disabled the Logger (to save power) it looks as if SPIM3 is no longer working.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Strangely if we have a ULINK2 debugger connected, even when not having any breakpoints the SPI works again so it appears to be something very strange within the CPU core itself.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/284912?ContentTypeID=1</link><pubDate>Tue, 15 Dec 2020 03:41:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0e45a49b-f368-427e-ba4c-190e2fbc5c2c</guid><dc:creator>Maksym Galemin</dc:creator><description>&lt;p&gt;I&amp;#39;ve got the same issue on my custom HW board. Tested on both SPI2 and SPI3 with exactly the same GPIO and SPI configuration (SCK=P0.19, MOSI=P0.06, MISO=P0.07, CS=P0.08) @ 1MHz with soft CS.&amp;nbsp;NRFX_SPIM2_ENABLED and&amp;nbsp;NRFX_SPIM3_ENABLED are both set to 1 in the sdk_config.h file. SCK and MOSI are both&amp;nbsp;H0H1.&lt;/p&gt;
&lt;p&gt;No issues with the SPI2 bus but after I switch to the SPI3&amp;nbsp;literally by just replacing&amp;nbsp;NRFX_SPIM_INSTANCE(2) with&amp;nbsp;NRFX_SPIM_INSTANCE(3) the uC stops&amp;nbsp;generating&amp;nbsp;signals on the SCK/MOSI lines.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://drive.google.com/file/d/1UlRwcukjfPkIs2q2DMSGK4YzVHIM3TC8/view?usp=sharing" rel="noopener noreferrer" target="_blank"&gt;Logic Analyser SPI2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://drive.google.com/file/d/1D3Jk-KPgiNlf3ABFNK-FkUgJTcyaMXpf/view?usp=sharing" rel="noopener noreferrer" target="_blank"&gt;Logic Analyser SPI3&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Strangely enough, if the CLI via UART0 is enabled the SPIM3 works fine.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/284222?ContentTypeID=1</link><pubDate>Thu, 10 Dec 2020 05:31:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6526e013-4186-46f0-a365-a38b80a142d3</guid><dc:creator>wsl</dc:creator><description>&lt;p&gt;Is custom,and&amp;nbsp;There is no clock generation on SCK。&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF52840 SPIM3 SCK not Pluse</title><link>https://devzone.nordicsemi.com/thread/283737?ContentTypeID=1</link><pubDate>Tue, 08 Dec 2020 09:40:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb1c0e91-852d-4162-a94b-2280d2b72153</guid><dc:creator>haakonsh</dc:creator><description>[quote user=""]The SCK pin cannot generate the correct pulse[/quote]
&lt;p&gt;Can you share a logic scope of the SPI transfer?&lt;br /&gt;&lt;br /&gt;Are you using a DK or a custom board?&lt;br /&gt;&lt;br /&gt;If a DK, what version do you have?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>