Documentation / devicetree / bindings / sound / maxim,max98925.yaml


Based on kernel version 6.11. Page generated on 2024-09-24 08:21 EST.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/maxim,max98925.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Maxim Integrated MAX98925/MAX98926/MAX98927 speaker amplifier

maintainers:
  - Ryan Lee <ryans.lee@maximintegrated.com>

properties:
  compatible:
    enum:
      - maxim,max98925
      - maxim,max98926
      - maxim,max98927

  reg:
    maxItems: 1

  reset-gpios:
    maxItems: 1
 
  '#sound-dai-cells':
    const: 0

  vmon-slot-no:
    $ref: /schemas/types.yaml#/definitions/uint32
    minimum: 0
    maximum: 30
    default: 0
    description:
      Slot number used to send voltage information or in inteleave mode this
      will be used as interleave slot.

  imon-slot-no:
    $ref: /schemas/types.yaml#/definitions/uint32
    minimum: 0
    maximum: 30
    default: 0
    description:
      Slot number used to send current information.

  maxim,interleave-mode:
    type: boolean
    description:
      When using two MAX9892X in a system it is possible to create ADC data
      that will overflow the frame size. When enabled, the Digital Audio
      Interleave mode provides a means to output VMON and IMON data from two
      devices on a single DOUT line when running smaller frames sizes such as
      32 BCLKS per LRCLK or 48 BCLKS per LRCLK.

required:
  - compatible
  - reg

allOf:
  - $ref: dai-common.yaml#
  - if:
      properties:
        compatible:
          contains:
            enum:
              - maxim,max98927
    then:
      properties:
        vmon-slot-no:
          minimum: 0
          maximum: 15

        imon-slot-no:
          minimum: 0
          maximum: 15

additionalProperties: false

examples:
  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;
 
        #include <dt-bindings/gpio/gpio.h>
        audio-codec@3a {
            compatible = "maxim,max98927";
            reg = <0x3a>;
            #sound-dai-cells = <0>;
 
            pinctrl-0 = <&speaker_default>;
            pinctrl-names = "default";
 
            reset-gpios = <&tlmm 69 GPIO_ACTIVE_LOW>;
 
            vmon-slot-no = <1>;
            imon-slot-no = <0>;
        };
    };