<?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>i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/106960/i2c-communication-not-working-in-ncs-but-working-on-nrf5-sdk</link><description>I have tried all the configs on device tree to make the sensor work reliably, but it fails. Like I have LSM6DSOX as IMU and it works for sometime and then On power on reset , device starts to show as not ready 
 
 device_is_ready ( lsm_i2c . bus ) this</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 03 Jan 2024 15:07:27 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/106960/i2c-communication-not-working-in-ncs-but-working-on-nrf5-sdk" /><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462554?ContentTypeID=1</link><pubDate>Wed, 03 Jan 2024 15:07:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:55a9d28a-a1a1-46e0-a416-4f05267d9b47</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;Good to hear that the problem was solved!&lt;/p&gt;
&lt;p&gt;I will close this case then. &lt;br /&gt;Good luck with your project onwards!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462503?ContentTypeID=1</link><pubDate>Wed, 03 Jan 2024 13:21:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:214ccb48-1197-43bd-8e62-880a42367793</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt; Using work thread solved my problem. &lt;br /&gt;Thanks for that&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462413?ContentTypeID=1</link><pubDate>Wed, 03 Jan 2024 08:13:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:31939c6b-d1fb-4d40-aeb9-940ff1f9580b</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Hi &lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have enabled log inside interrupt handler, and I get those log but when I include to read out the sensor ID inside the interrupt handler ( LSM i2c comm) then its stuck and start getting i2c failure and the remains in same state as pictured above and comes out on power on reset only.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462298?ContentTypeID=1</link><pubDate>Tue, 02 Jan 2024 13:23:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e4895ba2-f235-45a5-b73b-25787fabfce7</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;Do you receive the data in the interrupt?&lt;br /&gt;Doing time-consuming activities in interrupt context may cause errors. Try to create work thread or something which is triggered by the interrupt instead. Does that solve the error?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462164?ContentTypeID=1</link><pubDate>Mon, 01 Jan 2024 05:42:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:45ca8195-1343-47dc-959d-83b89a33f204</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;00&amp;gt; Interrupt observed 
00&amp;gt; [00:00:07.394,592] &amp;lt;err&amp;gt; i2c_nrfx_twi: i2c_nrfx_twi_transfer: Error on I2C line occurred for message 0
00&amp;gt; LSM int handler : 32
00&amp;gt; Interrupt observed 
00&amp;gt; [00:00:08.328,582] &amp;lt;err&amp;gt; i2c_nrfx_twi: i2c_nrfx_twi_transfer: Error on I2C line occurred for message 0
00&amp;gt; LSM int handler : 32
00&amp;gt; Interrupt observed 
00&amp;gt; [00:00:18.826,965] &amp;lt;err&amp;gt; i2c_nrfx_twi: i2c_nrfx_twi_transfer: Error on I2C line occurred for message 0
00&amp;gt; LSM int handler : 32
00&amp;gt; Interrupt observed 
00&amp;gt; [00:00:20.321,380] &amp;lt;err&amp;gt; i2c_nrfx_twi: i2c_nrfx_twi_transfer: Error on I2C line occurred for message 0
00&amp;gt; LSM int handler : 32
00&amp;gt; Interrupt observed 
00&amp;gt; [00:00:21.255,401] &amp;lt;err&amp;gt; i2c_nrfx_twi: i2c_nrfx_twi_transfer: Error on I2C line occurred for message 0
00&amp;gt; LSM int handler : 32&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462163?ContentTypeID=1</link><pubDate>Mon, 01 Jan 2024 05:31:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2102b839-43f5-4c91-909a-49c048583c8d</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Hi &lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have got into one more issue with my LSM, on LSM interrupt I am trying to read sensor ID (want to actually read accel raw data on interrupt) and it gets stuck and never recovers but the BLE functionality works.&lt;/p&gt;
&lt;p&gt;Not able to find any reason for this to happen. Please help in this&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/pastedimage1704087104821v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462142?ContentTypeID=1</link><pubDate>Sat, 30 Dec 2023 15:09:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:614c248a-e3a7-4606-a4f3-62904c408a9e</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt;&amp;nbsp;Hi&lt;/p&gt;
&lt;p&gt;I have solved the issue of LSM not detecting in my board with the config shared.&lt;/p&gt;
&lt;p&gt;Main issue was there were other communication protocols which were using the same pins as that of LSM which was causing the issue.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462078?ContentTypeID=1</link><pubDate>Fri, 29 Dec 2023 10:35:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:324e4021-3b12-4b09-ad68-69fb69a968f3</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Hi &lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I will come back with logic analyzer result for this.&lt;br /&gt;But can you also see this ticket of mine -&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/106994/buffer-overflow-while-using-config_newlib_libc-and-not-able-to-use-math-h-in-my-application"&gt;https://devzone.nordicsemi.com/f/nordic-q-a/106994/buffer-overflow-while-using-config_newlib_libc-and-not-able-to-use-math-h-in-my-application&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Its quite urgent. Please help&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462069?ContentTypeID=1</link><pubDate>Fri, 29 Dec 2023 09:53:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cf749b07-f132-43ab-b259-c816883b7211</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Hi &lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I have followed dev academy religiously in making this project including i2c.&lt;/p&gt;
&lt;p&gt;See if only one sensor out of 4 sensor not working is the problem, on same config others are working and this is not that`s the problem.&lt;/p&gt;
&lt;p&gt;I have disable rest of the communication to refrain from pin control conflicts -&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;
&amp;amp;spi0 {
	status = &amp;quot;disabled&amp;quot;;
};

&amp;amp;spi1 {
	status = &amp;quot;disabled&amp;quot;;
};

&amp;amp;uart0 {
	status = &amp;quot;disabled&amp;quot;;
};

&amp;amp;uart1 {
	status = &amp;quot;disabled&amp;quot;;
};
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;But still nothing.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/462050?ContentTypeID=1</link><pubDate>Fri, 29 Dec 2023 08:37:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9fd3e845-5c10-4ea0-8866-77fa08ea8641</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;By the way, have you seen our &lt;a href="https://academy.nordicsemi.com/courses/nrf-connect-sdk-fundamentals/lessons/lesson-6-serial-com-i2c/"&gt;I2C course&lt;/a&gt;?&lt;/p&gt;
[quote user="Gaurav2908"]But see if my hardware already has pull up resistor, so I should be using bias-disabled on pin ctrl config..right?[/quote]
&lt;p&gt;Our &lt;a href="https://github.com/nrfconnect/sdk-zephyr/blob/426213023e08965311421143ca3abe2ec25b39a4/boards/arm/nrf52840dk_nrf52840/nrf52840dk_nrf52840-pinctrl.dtsi#L47-L52"&gt;nRF52840DK pinctrl for i2c &lt;/a&gt;does not set any flags for i2c.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461989?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 14:24:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb634075-cef5-47df-9a7b-fdc3317c3e33</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;But see if my hardware already has pull up resistor, so I should be using bias-disabled on pin ctrl config..right?&lt;/p&gt;
&lt;p&gt;any other flag that can be missing?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461988?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 14:23:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ab2617e8-7e85-4546-bad3-f211cfca1b8c</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>[quote user="Gaurav2908"]But are you finding any fundamental issue with my DTS file with respect to the schematic shared?[/quote]
&lt;p&gt;From a look, it seems fine.&lt;br /&gt;But in my experience, it is very hard to spot errors through staring at code&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461985?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 14:20:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a1887d65-0ce1-4ed9-a95b-e8e0a299807c</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Sure &lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt; I try once more with stand alone LSM.&lt;/p&gt;
&lt;p&gt;But are you finding any fundamental issue with my DTS file with respect to the schematic shared?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461984?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 14:18:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f35feb66-3b00-4f61-998a-fcf621e693e0</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;Thanks for the overview, I think I understand the issue better now.&lt;/p&gt;
&lt;p&gt;I suggest that we try to make LSM6DSOX work alone first, and then move on from there.&lt;/p&gt;
&lt;p&gt;Set CONFIG_SENSOR_LOG_LEVEL_DBG and see if we get any useful information from that.&lt;/p&gt;
&lt;p&gt;Also, if you want, try to debug the file zephyr\drivers\sensor\lsm6dso\lsm6dso.c, and see if you can see what happens there.&lt;/p&gt;
&lt;p&gt;Do you have oscillosocope or logic analyzator traces from the I2C lines? Maybe that could give some hints.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461973?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 13:58:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eed678c7-ce46-49e4-bcfb-670029f1abcb</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Answering your query on this -&lt;/p&gt;
&lt;p&gt;1. STC(fuel guage) address:0x70 and MLX(temp sensor) address : 0x3A, works all the time&lt;/p&gt;
&lt;p&gt;2. Heart rate sensor (MAXM) address : 0x62 on i2c line 1 works sometimes, LSM only worked only one time so keeping it in 3 category&lt;/p&gt;
&lt;p&gt;3. LSM6DSOX (0x6A) never worked.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461971?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 13:55:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e45b0bfa-31a8-405f-becf-7e243c940494</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;Other two sensor on the same i2c line (i2c0) works properly without fail. But only LSM6DSOX one fails.&lt;/p&gt;
&lt;p&gt;I have disabled all the other communications which were using same pins of SDA and SCL (like SPI and UART) but still facing the same issue.&lt;/p&gt;
&lt;p&gt;Marking again : All the sensors on the hardware works perfectly on nrf5 based SDK, having issues after porting thats why doubting configuration files.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461969?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 13:54:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a1571ab1-1855-402f-a2ba-4976bac4a8bd</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;I think I am missing some of the overview.&lt;/p&gt;
&lt;p&gt;Can you list which sensors:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;work all the time&lt;/li&gt;
&lt;li&gt;work some of the time&lt;/li&gt;
&lt;li&gt;never works&lt;/li&gt;
&lt;/ol&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461967?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 13:52:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:48052130-fb63-4325-94a6-af3a679e0457</guid><dc:creator>Gaurav</dc:creator><description>&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/members/sigurd-hellesvik"&gt;Sigurd Hellesvik&lt;/a&gt; I have tested with stand alone too but there also it never worked.&lt;/p&gt;
&lt;p&gt;But the other sensor (STC - fuel gauge) that works without fail.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: i2c communication not working in ncs but working on nrf5 sdk</title><link>https://devzone.nordicsemi.com/thread/461947?ContentTypeID=1</link><pubDate>Thu, 28 Dec 2023 12:32:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb546cfc-aaa1-4fe1-a3f2-fd7b87955797</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You have 4 I2C devices connected to the nRF52840 right?&lt;/p&gt;
&lt;p&gt;Do you see this error only if all are configured? Do you see the error for any one I2C device if you only try to use one in one app, and then another app with only one sensor and so on?&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Sigurd Hellesvik&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>