<?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>This code is not supposed to be compiled when neither POWER nor CLOCK is enabled</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/100072/this-code-is-not-supposed-to-be-compiled-when-neither-power-nor-clock-is-enabled</link><description>I am building my C++ application on top of the existing sample code but upon doing so, I am running into 
 &amp;quot;This code is not supposed to be compiled when neither POWER nor CLOCK is enabled&amp;quot; The application involves setting up TWI. 
 There&amp;#39;s probably a</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 26 May 2023 06:51:44 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/100072/this-code-is-not-supposed-to-be-compiled-when-neither-power-nor-clock-is-enabled" /><item><title>RE: This code is not supposed to be compiled when neither POWER nor CLOCK is enabled</title><link>https://devzone.nordicsemi.com/thread/427658?ContentTypeID=1</link><pubDate>Fri, 26 May 2023 06:51:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cca7369c-8bd0-4bfc-83fc-ebf32130d4f2</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;Glad to hear that you found a solution to your issue.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not sure I follow what sort of background you&amp;#39;re requesting? nrfx_power_clock_irq_init(); is only called in &lt;strong&gt;nrfx_clock.c&lt;/strong&gt; and &lt;strong&gt;nrfx_power.c&lt;/strong&gt; in the nRF5 SDK, so if your project uses either of these drivers it&amp;#39;s also expected that you enable the drivers in the sdk_config.h file.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: This code is not supposed to be compiled when neither POWER nor CLOCK is enabled</title><link>https://devzone.nordicsemi.com/thread/427299?ContentTypeID=1</link><pubDate>Wed, 24 May 2023 15:54:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d5b6d3ab-d78d-4478-9214-385a40c57949</guid><dc:creator>morpho</dc:creator><description>&lt;p&gt;Setting&amp;nbsp;&lt;span&gt;NRFX_CLOCK_ENABLED worked.&amp;nbsp;I see this macro is used in&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;nrfx_power_clock_irq_init()&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;
&lt;pre&gt;Can you provide some background? Who&amp;#39;s setting this? Shouldn&amp;#39;t this be left at the user&amp;#39;s discretion?&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: This code is not supposed to be compiled when neither POWER nor CLOCK is enabled</title><link>https://devzone.nordicsemi.com/thread/427215?ContentTypeID=1</link><pubDate>Wed, 24 May 2023 11:58:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:66a64ac8-a4a6-45ff-9007-bbafa1b2e28e</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;This error message most likely comes from the&lt;strong&gt; nrfx_power_clock.h&lt;/strong&gt; file and is due to both NRFX_POWER_ENABLED and NRFX_CLOCK_ENABLED being set to 0 in your sdk_config.h file. Can you try setting either or both to 1 in your sdk_config.h header file?&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>