<?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>accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/102716/accel_polling-template-on-thingy91-does-not-find-accelerometers</link><description>I am using the accel_polling template code as a base to build some code that I need for evaluation on the Thingy91. 
 The code compiles and flashes to the Thingy91 but fails to find either of the accelerometers (ADXL362 or ADXL372). My intent is to use</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 15 Aug 2023 07:10:29 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/102716/accel_polling-template-on-thingy91-does-not-find-accelerometers" /><item><title>RE: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/441294?ContentTypeID=1</link><pubDate>Tue, 15 Aug 2023 07:10:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:db820530-7dc7-4809-beee-309345ff366b</guid><dc:creator>runsiv</dc:creator><description>&lt;p&gt;Haha glad it worked out for you. Documentation is good to have, but sometimes the jump between documentation and creating something can be a bit iffy, that why we have Devzone.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best of luck&lt;/p&gt;
&lt;p&gt;Runar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/441261?ContentTypeID=1</link><pubDate>Mon, 14 Aug 2023 21:46:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c7631f85-3995-44d1-8b50-1fe81b6c4f4e</guid><dc:creator>Brian Fuller</dc:creator><description>&lt;p&gt;Thank you Runar. Your solution works very well. I&amp;#39;ll also take your suggestion to go though the DevAcademy. At one time I worked for a software company as a developer and through my close association with the support staff I learned that many user problems could be solved via the rule of &amp;quot;RTFM&amp;quot; or &amp;quot;Read The Fu**ing Manual&amp;quot;.&amp;nbsp; I&amp;#39;ll read the manual. &lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Brian&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/440860?ContentTypeID=1</link><pubDate>Fri, 11 Aug 2023 05:49:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0e30636a-7533-4b0f-8317-a323baa3be76</guid><dc:creator>runsiv</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Since you are new to our devices I would recommend taking the time to go trough the fundamentals course on DevAcademy, at least I felt it very helpful when I started with Nordic devices. You can also have a read &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/build/dts/howtos.html#set-devicetree-overlays"&gt;here &lt;/a&gt;regarding overlay and device tree&lt;/p&gt;
&lt;p&gt;As for creating a overlay file. The easiest is to open the input files section when you have select nRF Connect extention in VScode&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/pastedimage1691732484283v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;And click on the create overlay and it will be created with the correct naming. So in my case it will get the name thingy91_nrf9160_ns.overlay&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You should be able to you copy past what I sent you and it should work.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Don&amp;#39;t worry about asking questions if there are things you don&amp;#39;t understand, that is why we have Devzone&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;Runar&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/440816?ContentTypeID=1</link><pubDate>Thu, 10 Aug 2023 18:30:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2e5492d5-6224-4027-b281-319198f6b5ad</guid><dc:creator>Brian Fuller</dc:creator><description>&lt;p&gt;Hello Runar,&lt;/p&gt;
&lt;p&gt;Thank you for your prompt response.&lt;/p&gt;
&lt;p&gt;My prj.conf file is shown here&lt;/p&gt;
&lt;p&gt;CONFIG_STDOUT_CONSOLE=y&lt;br /&gt;CONFIG_SENSOR=y&lt;br /&gt;CONFIG_CBPRINTF_FP_SUPPORT=y&lt;br /&gt;# The following are used with /usr/bin/JLinkRTTViewer &lt;br /&gt;CONFIG_LOG=y&lt;br /&gt;CONFIG_UART_CONSOLE=y&lt;br /&gt;CONFIG_RTT_CONSOLE=y&lt;br /&gt;CONFIG_USE_SEGGER_RTT=y&lt;br /&gt;CONFIG_UART_INTERRUPT_DRIVEN=y&lt;/p&gt;
&lt;p&gt;The following CONFIG_ values in your prj.conf&lt;/p&gt;
&lt;p&gt;CONFIG_SPI=y&lt;br /&gt;CONFIG_ADXL362=y&lt;br /&gt;CONFIG_ADXL372=y&lt;/p&gt;
&lt;p&gt;and were already set in my .config file.&lt;/p&gt;
&lt;p&gt;I also added the #include &amp;lt;zephyr/drivers/spi.h&amp;gt; statement to main.c.&lt;/p&gt;
&lt;p&gt;I do not have an overlay file in this project and because I am new to nRF programming I do not know how to set up an overlay file.&amp;nbsp; I looked in the dev academy for discussion of .overlay files which says what they are but does not provide a detailed description. It is possible that I did not read the correct sections however so please forgive me if I am wasting your time.&amp;nbsp; From what I did read however, I need to create a file called &amp;lt;boardname&amp;gt;.overlay and put it into the root directory of the app. &lt;/p&gt;
&lt;p&gt;In my case of using a Thingy91 would the file be named Thingy91.overlay, nRF9160.overlay, or something else?&lt;/p&gt;
&lt;p&gt;Also, can I copy the text from your overlay file that you provided above?&lt;/p&gt;
&lt;p&gt;Thank you again,&lt;/p&gt;
&lt;p&gt;Brian&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&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: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/440655?ContentTypeID=1</link><pubDate>Thu, 10 Aug 2023 08:23:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8ef45d8f-7417-4482-8f21-5b6a11b29a55</guid><dc:creator>runsiv</dc:creator><description>&lt;p&gt;The sample template is nearly done, however it does not include the overlay for the senors, nor did it include the changes needed to prj.conf to add the sensors.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I did not have a thing91 laying around, but I tested on a thing53. So this is adjusted for a thingy91 expect the code output.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:inherit;"&gt;In the overlay for the Thing91 (the adxl372 part is not tested)&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/ {
    aliases {
		accel0 = &amp;amp;adxl362;
        accel1 = &amp;amp;adxl372;
    };
};

&amp;amp;spi3 {
	compatible = &amp;quot;nordic,nrf-spim&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	cs-gpios = &amp;lt;&amp;amp;gpio0 8 GPIO_ACTIVE_LOW&amp;gt;, &amp;lt;&amp;amp;gpio0 7 GPIO_ACTIVE_LOW&amp;gt;;

	pinctrl-0 = &amp;lt;&amp;amp;spi3_default&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;spi3_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;
	adxl362: adxl362@0 {
		compatible = &amp;quot;adi,adxl362&amp;quot;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		reg = &amp;lt;0&amp;gt;;
		int1-gpios = &amp;lt;&amp;amp;gpio0 9 0&amp;gt;;
	};

	adxl372: adxl372@1 {
		compatible = &amp;quot;adi,adxl372&amp;quot;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		reg = &amp;lt;1&amp;gt;;
		int1-gpios = &amp;lt;&amp;amp;gpio0 6 0&amp;gt;;
	};
};&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;In prj.conf&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;CONFIG_STDOUT_CONSOLE=y
CONFIG_SENSOR=y
CONFIG_CBPRINTF_FP_SUPPORT=y
CONFIG_SPI=y
CONFIG_ADXL362=y
CONFIG_ADXL372=y&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;In the top of main.c&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#include &amp;lt;zephyr/drivers/spi.h&amp;gt;
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;From the device&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;[10:21:54:694] spi-dev-adxl362@0 [m/s^2]:    (   -0.421685,    -0.598205,    -7.845320)␍␊
[10:21:55:695] spi-dev-adxl362@0 [m/s^2]:    (   -0.392266,    -0.441299,    -7.972806)␍␊
[10:21:56:695] spi-dev-adxl362@0 [m/s^2]:    (   -0.509945,    -0.235359,    -7.796286)␍␊
[10:21:57:696] spi-dev-adxl362@0 [m/s^2]:    (   -0.598205,    -0.372652,    -8.188552)␍␊
[10:21:58:696] spi-dev-adxl362@0 [m/s^2]:    (   -0.617818,    -0.284392,    -8.012033)␍␊
[10:21:59:697] spi-dev-adxl362@0 [m/s^2]:    (   -0.392266,    -0.166713,    -7.894353)␍␊
[10:22:00:697] spi-dev-adxl362@0 [m/s^2]:    (   -0.431492,    -0.529559,    -7.923773)␍␊
[10:22:01:698] spi-dev-adxl362@0 [m/s^2]:    (   -0.539365,    -0.392266,    -8.041453)␍␊
[10:22:02:698] spi-dev-adxl362@0 [m/s^2]:    (   -0.480525,    -0.313812,    -8.208166)␍␊
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;Runar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: accel_polling template on Thingy91 does not find accelerometers</title><link>https://devzone.nordicsemi.com/thread/440636?ContentTypeID=1</link><pubDate>Thu, 10 Aug 2023 07:42:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:992c4ab9-491d-4785-8d7d-5925304b441c</guid><dc:creator>runsiv</dc:creator><description>&lt;p&gt;Hi Brian, I will look into your case&lt;/p&gt;
&lt;p&gt;Could you post your prj.conf and any overlay file for the thing91?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have not used the sample sensor example before, so I will set it up myself and see if I can get it working&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;Runar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>