max77693.txt 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193
  1. Maxim MAX77693 multi-function device
  2. MAX77693 is a Multifunction device with the following submodules:
  3. - PMIC,
  4. - CHARGER,
  5. - LED,
  6. - MUIC,
  7. - HAPTIC
  8. It is interfaced to host controller using i2c.
  9. This document describes the bindings for the mfd device.
  10. Required properties:
  11. - compatible : Must be "maxim,max77693".
  12. - reg : Specifies the i2c slave address of PMIC block.
  13. - interrupts : This i2c device has an IRQ line connected to the main SoC.
  14. Optional properties:
  15. - regulators : The regulators of max77693 have to be instantiated under subnode
  16. named "regulators" using the following format.
  17. regulators {
  18. regulator-compatible = ESAFEOUT1/ESAFEOUT2/CHARGER
  19. standard regulator constraints[*].
  20. };
  21. [*] refer Documentation/devicetree/bindings/regulator/regulator.txt
  22. - haptic : The MAX77693 haptic device utilises a PWM controlled motor to provide
  23. users with tactile feedback. PWM period and duty-cycle are varied in
  24. order to provide the appropriate level of feedback.
  25. Required properties:
  26. - compatible : Must be "maxim,max77693-haptic"
  27. - haptic-supply : power supply for the haptic motor
  28. [*] refer Documentation/devicetree/bindings/regulator/regulator.txt
  29. - pwms : phandle to the physical PWM(Pulse Width Modulation) device.
  30. PWM properties should be named "pwms". And number of cell is different
  31. for each pwm device.
  32. To get more information, please refer to documentation.
  33. [*] refer Documentation/devicetree/bindings/pwm/pwm.txt
  34. - charger : Node configuring the charger driver.
  35. If present, required properties:
  36. - compatible : Must be "maxim,max77693-charger".
  37. Optional properties (if not set, defaults will be used):
  38. - maxim,constant-microvolt : Battery constant voltage in uV. The charger
  39. will operate in fast charge constant current mode till battery voltage
  40. reaches this level. Then the charger will switch to fast charge constant
  41. voltage mode. Also vsys (system voltage) will be set to this value when
  42. DC power is supplied but charger is not enabled.
  43. Valid values: 3650000 - 4400000, step by 25000 (rounded down)
  44. Default: 4200000
  45. - maxim,min-system-microvolt : Minimal system voltage in uV.
  46. Valid values: 3000000 - 3700000, step by 100000 (rounded down)
  47. Default: 3600000
  48. - maxim,thermal-regulation-celsius : Temperature in Celsius for entering
  49. high temperature charging mode. If die temperature exceeds this value
  50. the charging current will be reduced by 105 mA/Celsius.
  51. Valid values: 70, 85, 100, 115
  52. Default: 100
  53. - maxim,battery-overcurrent-microamp : Overcurrent protection threshold
  54. in uA (current from battery to system).
  55. Valid values: 2000000 - 3500000, step by 250000 (rounded down)
  56. Default: 3500000
  57. - maxim,charge-input-threshold-microvolt : Threshold voltage in uV for
  58. triggering input voltage regulation loop. If input voltage decreases
  59. below this value, the input current will be reduced to reach the
  60. threshold voltage.
  61. Valid values: 4300000, 4700000, 4800000, 4900000
  62. Default: 4300000
  63. - led : the LED submodule device node
  64. There are two LED outputs available - FLED1 and FLED2. Each of them can
  65. control a separate LED or they can be connected together to double
  66. the maximum current for a single connected LED. One LED is represented
  67. by one child node.
  68. Required properties:
  69. - compatible : Must be "maxim,max77693-led".
  70. Optional properties:
  71. - maxim,boost-mode :
  72. In boost mode the device can produce up to 1.2A of total current
  73. on both outputs. The maximum current on each output is reduced
  74. to 625mA then. If not enabled explicitly, boost setting defaults to
  75. LEDS_BOOST_FIXED in case both current sources are used.
  76. Possible values:
  77. LEDS_BOOST_OFF (0) - no boost,
  78. LEDS_BOOST_ADAPTIVE (1) - adaptive mode,
  79. LEDS_BOOST_FIXED (2) - fixed mode.
  80. - maxim,boost-mvout : Output voltage of the boost module in millivolts.
  81. Valid values: 3300 - 5500, step by 25 (rounded down)
  82. Default: 3300
  83. - maxim,mvsys-min : Low input voltage level in millivolts. Flash is not fired
  84. if chip estimates that system voltage could drop below this level due
  85. to flash power consumption.
  86. Valid values: 2400 - 3400, step by 33 (rounded down)
  87. Default: 2400
  88. Required properties for the LED child node:
  89. - led-sources : see Documentation/devicetree/bindings/leds/common.txt;
  90. device current output identifiers: 0 - FLED1, 1 - FLED2
  91. - led-max-microamp : see Documentation/devicetree/bindings/leds/common.txt
  92. Valid values for a LED connected to one FLED output:
  93. 15625 - 250000, step by 15625 (rounded down)
  94. Valid values for a LED connected to both FLED outputs:
  95. 15625 - 500000, step by 15625 (rounded down)
  96. - flash-max-microamp : see Documentation/devicetree/bindings/leds/common.txt
  97. Valid values for a single LED connected to one FLED output
  98. (boost mode must be turned off):
  99. 15625 - 1000000, step by 15625 (rounded down)
  100. Valid values for a single LED connected to both FLED outputs:
  101. 15625 - 1250000, step by 15625 (rounded down)
  102. Valid values for two LEDs case:
  103. 15625 - 625000, step by 15625 (rounded down)
  104. - flash-max-timeout-us : see Documentation/devicetree/bindings/leds/common.txt
  105. Valid values: 62500 - 1000000, step by 62500 (rounded down)
  106. Optional properties for the LED child node:
  107. - label : see Documentation/devicetree/bindings/leds/common.txt
  108. Optional nodes:
  109. - max77693-muic :
  110. Node used only by extcon consumers.
  111. Required properties:
  112. - compatible : "maxim,max77693-muic"
  113. Example:
  114. #include <dt-bindings/leds/common.h>
  115. max77693@66 {
  116. compatible = "maxim,max77693";
  117. reg = <0x66>;
  118. interrupt-parent = <&gpx1>;
  119. interrupts = <5 2>;
  120. regulators {
  121. esafeout@1 {
  122. regulator-compatible = "ESAFEOUT1";
  123. regulator-name = "ESAFEOUT1";
  124. regulator-boot-on;
  125. };
  126. esafeout@2 {
  127. regulator-compatible = "ESAFEOUT2";
  128. regulator-name = "ESAFEOUT2";
  129. };
  130. charger@0 {
  131. regulator-compatible = "CHARGER";
  132. regulator-name = "CHARGER";
  133. regulator-min-microamp = <60000>;
  134. regulator-max-microamp = <2580000>;
  135. regulator-boot-on;
  136. };
  137. };
  138. haptic {
  139. compatible = "maxim,max77693-haptic";
  140. haptic-supply = <&haptic_supply>;
  141. pwms = <&pwm 0 40000 0>;
  142. pwm-names = "haptic";
  143. };
  144. charger {
  145. compatible = "maxim,max77693-charger";
  146. maxim,constant-microvolt = <4200000>;
  147. maxim,min-system-microvolt = <3600000>;
  148. maxim,thermal-regulation-celsius = <75>;
  149. maxim,battery-overcurrent-microamp = <3000000>;
  150. maxim,charge-input-threshold-microvolt = <4300000>;
  151. led {
  152. compatible = "maxim,max77693-led";
  153. maxim,boost-mode = <LEDS_BOOST_FIXED>;
  154. maxim,boost-mvout = <5000>;
  155. maxim,mvsys-min = <2400>;
  156. camera_flash: flash-led {
  157. label = "max77693-flash";
  158. led-sources = <0>, <1>;
  159. led-max-microamp = <500000>;
  160. flash-max-microamp = <1250000>;
  161. flash-max-timeout-us = <1000000>;
  162. };
  163. };
  164. };