Skip to content

Commit 36591b7

Browse files
Mihai Sainclaudiubeznea
authored andcommitted
ARM: dts: microchip: sam9x75_curiosity: Add power monitor support
Add PAC1934 support in order to monitor the board power consumption. Device is connected on flexcom7 in twi mode. [root@SAM9X75 ~]$ awk -f pac1934.awk VDD3V3 current: 10.675 mA, voltage: 3295.41 mV VDDOUT4 current: 5.7625 mA, voltage: 1196.78 mV VDDCORE current: 115.442 mA, voltage: 1243.65 mV VDDIODDR current: 29.585 mA, voltage: 1345.21 mV Signed-off-by: Mihai Sain <[email protected]> Link: https://lore.kernel.org/r/[email protected] [claudiu.beznea: s/VDDOUT4/DCDC4 to comply with schematics] Signed-off-by: Claudiu Beznea <[email protected]>
1 parent 18dd125 commit 36591b7

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

arch/arm/boot/dts/microchip/at91-sam9x75_curiosity.dts

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,52 @@
198198
};
199199
};
200200

201+
&flx7 {
202+
atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_TWI>;
203+
status = "okay";
204+
};
205+
206+
&i2c7 {
207+
dmas = <0>, <0>;
208+
i2c-analog-filter;
209+
i2c-digital-filter;
210+
i2c-digital-filter-width-ns = <35>;
211+
pinctrl-names = "default";
212+
pinctrl-0 = <&pinctrl_flx7_default>;
213+
status = "okay";
214+
215+
power-monitor@10 {
216+
compatible = "microchip,pac1934";
217+
reg = <0x10>;
218+
#address-cells = <1>;
219+
#size-cells = <0>;
220+
221+
channel@1 {
222+
reg = <0x1>;
223+
shunt-resistor-micro-ohms = <10000>;
224+
label = "VDD3V3";
225+
};
226+
227+
channel@2 {
228+
reg = <0x2>;
229+
shunt-resistor-micro-ohms = <10000>;
230+
label = "DCDC4";
231+
};
232+
233+
channel@3 {
234+
reg = <0x3>;
235+
shunt-resistor-micro-ohms = <10000>;
236+
label = "VDDCORE";
237+
};
238+
239+
channel@4 {
240+
reg = <0x4>;
241+
shunt-resistor-micro-ohms = <10000>;
242+
label = "VDDIODDR";
243+
};
244+
};
245+
};
246+
201247
&i2s {
202248
pinctrl-names = "default";
203249
pinctrl-0 = <&pinctrl_i2s_default>;
@@ -231,6 +277,12 @@
231277
<AT91_PIOA 24 AT91_PERIPH_A AT91_PINCTRL_PULL_UP>,
232278
<AT91_PIOA 25 AT91_PERIPH_A AT91_PINCTRL_PULL_UP>;
233279
};
280+
281+
pinctrl_flx7_default: flx7-default {
282+
atmel,pins =
283+
<AT91_PIOC 0 AT91_PERIPH_C AT91_PINCTRL_PULL_UP>,
284+
<AT91_PIOC 1 AT91_PERIPH_C AT91_PINCTRL_PULL_UP>;
285+
};
234286
};
235287

236288
gpio-keys {

0 commit comments

Comments
 (0)