st,sta350.txt 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. STA350 audio CODEC
  2. The driver for this device only supports I2C.
  3. Required properties:
  4. - compatible: "st,sta350"
  5. - reg: the I2C address of the device for I2C
  6. - reset-gpios: a GPIO spec for the reset pin. If specified, it will be
  7. deasserted before communication to the codec starts.
  8. - power-down-gpios: a GPIO spec for the power down pin. If specified,
  9. it will be deasserted before communication to the codec
  10. starts.
  11. - vdd-dig-supply: regulator spec, providing 3.3V
  12. - vdd-pll-supply: regulator spec, providing 3.3V
  13. - vcc-supply: regulator spec, providing 5V - 26V
  14. Optional properties:
  15. - st,output-conf: number, Selects the output configuration:
  16. 0: 2-channel (full-bridge) power, 2-channel data-out
  17. 1: 2 (half-bridge). 1 (full-bridge) on-board power
  18. 2: 2 Channel (Full-Bridge) Power, 1 Channel FFX
  19. 3: 1 Channel Mono-Parallel
  20. If parameter is missing, mode 0 will be enabled.
  21. This property has to be specified as '/bits/ 8' value.
  22. - st,ch1-output-mapping: Channel 1 output mapping
  23. - st,ch2-output-mapping: Channel 2 output mapping
  24. - st,ch3-output-mapping: Channel 3 output mapping
  25. 0: Channel 1
  26. 1: Channel 2
  27. 2: Channel 3
  28. If parameter is missing, channel 1 is chosen.
  29. This properties have to be specified as '/bits/ 8' values.
  30. - st,thermal-warning-recover:
  31. If present, thermal warning recovery is enabled.
  32. - st,thermal-warning-adjustment:
  33. If present, thermal warning adjustment is enabled.
  34. - st,fault-detect-recovery:
  35. If present, then fault recovery will be enabled.
  36. - st,ffx-power-output-mode: string
  37. The FFX power output mode selects how the FFX output timing is
  38. configured. Must be one of these values:
  39. - "drop-compensation"
  40. - "tapered-compensation"
  41. - "full-power-mode"
  42. - "variable-drop-compensation" (default)
  43. - st,drop-compensation-ns: number
  44. Only required for "st,ffx-power-output-mode" ==
  45. "variable-drop-compensation".
  46. Specifies the drop compensation in nanoseconds.
  47. The value must be in the range of 0..300, and only
  48. multiples of 20 are allowed. Default is 140ns.
  49. - st,overcurrent-warning-adjustment:
  50. If present, overcurrent warning adjustment is enabled.
  51. - st,max-power-use-mpcc:
  52. If present, then MPCC bits are used for MPC coefficients,
  53. otherwise standard MPC coefficients are used.
  54. - st,max-power-corr:
  55. If present, power bridge correction for THD reduction near maximum
  56. power output is enabled.
  57. - st,am-reduction-mode:
  58. If present, FFX mode runs in AM reduction mode, otherwise normal
  59. FFX mode is used.
  60. - st,odd-pwm-speed-mode:
  61. If present, PWM speed mode run on odd speed mode (341.3 kHz) on all
  62. channels. If not present, normal PWM spped mode (384 kHz) will be used.
  63. - st,distortion-compensation:
  64. If present, distortion compensation variable uses DCC coefficient.
  65. If not present, preset DC coefficient is used.
  66. - st,invalid-input-detect-mute:
  67. If present, automatic invalid input detect mute is enabled.
  68. - st,activate-mute-output:
  69. If present, a mute output will be activated in ase the volume will
  70. reach a value lower than -76 dBFS.
  71. - st,bridge-immediate-off:
  72. If present, the bridge will be switched off immediately after the
  73. power-down-gpio goes low. Otherwise, the bridge will wait for 13
  74. million clock cycles to pass before shutting down.
  75. - st,noise-shape-dc-cut:
  76. If present, the noise-shaping technique on the DC cutoff filter are
  77. enabled.
  78. - st,powerdown-master-volume:
  79. If present, the power-down pin and I2C power-down functions will
  80. act on the master volume. Otherwise, the functions will act on the
  81. mute commands.
  82. - st,powerdown-delay-divider:
  83. If present, the bridge power-down time will be divided by the provided
  84. value. If not specified, a divider of 1 will be used. Allowed values
  85. are 1, 2, 4, 8, 16, 32, 64 and 128.
  86. This property has to be specified as '/bits/ 8' value.
  87. Example:
  88. codec: sta350@38 {
  89. compatible = "st,sta350";
  90. reg = <0x1c>;
  91. reset-gpios = <&gpio1 19 0>;
  92. power-down-gpios = <&gpio1 16 0>;
  93. st,output-conf = /bits/ 8 <0x3>; // set output to 2-channel
  94. // (full-bridge) power,
  95. // 2-channel data-out
  96. st,ch1-output-mapping = /bits/ 8 <0>; // set channel 1 output ch 1
  97. st,ch2-output-mapping = /bits/ 8 <0>; // set channel 2 output ch 1
  98. st,ch3-output-mapping = /bits/ 8 <0>; // set channel 3 output ch 1
  99. st,max-power-correction; // enables power bridge
  100. // correction for THD reduction
  101. // near maximum power output
  102. st,invalid-input-detect-mute; // mute if no valid digital
  103. // audio signal is provided.
  104. };