<?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>ADC full-scale conversion in npm1300 Zephyr drivers</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/123522/adc-full-scale-conversion-in-npm1300-zephyr-drivers</link><description>During development we noticed that current measurements coming from npm1300 appear to be much higher than expected despite the results not matching what we were seeing on the nrf power profiler. For example: while powering our board with the nrf ppk2</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 08 Aug 2025 15:02:38 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/123522/adc-full-scale-conversion-in-npm1300-zephyr-drivers" /><item><title>RE: ADC full-scale conversion in npm1300 Zephyr drivers</title><link>https://devzone.nordicsemi.com/thread/545077?ContentTypeID=1</link><pubDate>Fri, 08 Aug 2025 15:02:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3461cc32-fc72-4780-b88a-fe7f2fbbf645</guid><dc:creator>ovaneg</dc:creator><description>&lt;p&gt;Hi Jared,&lt;br /&gt;&lt;br /&gt;Yes, we are using a custom board.&lt;br /&gt;I connected a battery and ran the ppk in ampere mode, which resulted in the same waveform as in source mode. Logging&amp;nbsp;the current measurements from the npm1300 to compare, I was still seeing anomylous measurements compared to what is being measured by the power profiler.&lt;br /&gt;&lt;br /&gt;However, I dont see us being able to resolve this issue without me being able to share details or schematics. Seeing as my original question regarding ADC full scale conversion has been answered, I will be closing this thread. If I continue to see differences between npm1300 and ppk2, I will open a seperate case as a private issue.&lt;br /&gt;&lt;br /&gt;Thank you for your support,&lt;br /&gt;&lt;br /&gt;Oscar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ADC full-scale conversion in npm1300 Zephyr drivers</title><link>https://devzone.nordicsemi.com/thread/545056?ContentTypeID=1</link><pubDate>Fri, 08 Aug 2025 12:28:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:81b00c7b-31ba-407c-92fd-6f44127f3ad8</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Can you try to set the PPK in ampere mode and connect it between the battery and the nPM1300. What current do you measure now?&lt;/p&gt;
&lt;p&gt;Also, is this on a custom board or are you are using the EK?&lt;/p&gt;
&lt;p&gt;regards&lt;br /&gt;Jared&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ADC full-scale conversion in npm1300 Zephyr drivers</title><link>https://devzone.nordicsemi.com/thread/544979?ContentTypeID=1</link><pubDate>Thu, 07 Aug 2025 16:18:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ff480ee6-1883-4a61-a0e2-c95d9e35c568</guid><dc:creator>ovaneg</dc:creator><description>&lt;p&gt;Hi Jared,&lt;br /&gt;&lt;br /&gt;Thank you for clarifying the ADC calculation.&lt;br /&gt;&lt;br /&gt;Our board uses npm1300 to supply system power from a battery and measure battery current draw to report to the MCU. To connect the power profiler&amp;nbsp;I replaced the battery with the ppk set up as a source meter, supplying power from the profiler instead.&lt;br /&gt;I cannot share schematics, but other than the npm1300 there is nothing connected to the battery other than one extremely low power IC.&lt;br /&gt;&lt;br /&gt;With this setup, I was periodically reading current from npm1300_charger (via Zephyr&amp;#39;s regulator api) and logging the output. While monitoring current draw from the ppk on nRF Power Profiler (sampling at 10 kHz) I was comparing these results to current measurements being read and logged in Zephyr at 1 Hz and 10Hz (I tried different frequencies). &lt;br /&gt;This set up gave the results I referenced in my initial post.&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;&lt;br /&gt;Oscar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: ADC full-scale conversion in npm1300 Zephyr drivers</title><link>https://devzone.nordicsemi.com/thread/544966?ContentTypeID=1</link><pubDate>Thu, 07 Aug 2025 14:27:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:939ed846-9e8d-4eb5-8da0-85d6d729dac1</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi there,&lt;/p&gt;
&lt;p&gt;Latest &lt;a href="https://docs.nordicsemi.com/bundle/ps_npm1300/page/chapters/core_components/saadc/doc/frontpage.html#ariaid-title10"&gt;documentation &lt;/a&gt;states:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;A value of&amp;nbsp;&lt;span&gt;01&lt;/span&gt;&amp;nbsp;means the battery is discharging. During a discharge, the full scale current (in Amps) is the battery discharge current limit (as configured in registers&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ps_npm1300/page/chapters/charger.html#register.BCHGISETDISCHARGEMSB"&gt;BCHGISETDISCHARGEMSB&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ps_npm1300/page/chapters/charger.html#register.BCHGISETDISCHARGELSB"&gt;BCHGISETDISCHARGELSB&lt;/a&gt;) &lt;strong&gt;multiplied by 1.12.&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;full_scale_ma&amp;nbsp;=&amp;nbsp;config-&amp;gt;dischg_limit_microamp&amp;nbsp;/&amp;nbsp;893;&lt;/p&gt;
&lt;p&gt;Which can be rewritten:&lt;/p&gt;
&lt;p&gt;&lt;span&gt;full_scale_ma&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;config&lt;/span&gt;&lt;span&gt;-&amp;gt;1000/893 ~ 1.12&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/zephyrproject-rtos/zephyr/blob/main/drivers/sensor/nordic/npm13xx_charger/npm13xx_charger.c#L214"&gt;The latest driver version is a bit more clear:&amp;nbsp;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;		full_scale_ua = -config-&amp;gt;dischg_limit_microamp *
				config-&amp;gt;full_scale_discharge_factors[0] /
				config-&amp;gt;full_scale_discharge_factors[1];&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Where the scaling factors are defined &lt;a href="https://github.com/zephyrproject-rtos/zephyr/blob/main/drivers/sensor/nordic/npm13xx_charger/npm13xx_charger.c#L151"&gt;here&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;		config-&amp;gt;full_scale_discharge_factors[0] /
				config-&amp;gt;full_scale_discharge_factors[1];&lt;/pre&gt; = 1.12.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So the driver should be correct here.&lt;/p&gt;
&lt;p&gt;I think the error is somewhere else in your system.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Can you explain how, or share schematics for your system?&lt;/p&gt;
&lt;p&gt;How is the npm and ppk connected?&lt;/p&gt;
&lt;p&gt;regards&lt;/p&gt;
&lt;p&gt;Jared&amp;nbsp;&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></channel></rss>