From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lj1-f173.google.com (mail-lj1-f173.google.com [209.85.208.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 51B7138F259 for ; Sat, 18 Apr 2026 14:47:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.173 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776523669; cv=none; b=li0ao2LdhyIi5dZ/mKF4seveZ1mVoWwmrlqymr6fdNlgLJqN+DF++RI1WP/HwIHU7B9Y6uZQXN5ulvFbcut3FRA2JqQZvBQDcOjZjkaBjyQuqg3NSVpMGpDZA1ylSrZITBMSQmsKMJ7FAP8qZZpmIWcp/wziuZFKEy6pjCQG5Yk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776523669; c=relaxed/simple; bh=Wxb9PwFATd17PDPb2rUk06CPpwp/tCyfuCX8k/OSLuo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=ElLg+nbU22AwRLxw25mUWi6jgnqQtgDa+ZuzOlM/tVqh3iCbgwfkzb8vcW+MOOm3NyGv5TpA0iGUQFfBMxSYx//4ZWJ2ef0C9ZA/S3AQiyLr4TX7WmlmB4jvHRd0pZ28uWbC4/Via+PSX+CJ4yNHeQ/fkM4epBzTa9ESMC1velA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=dUUw2TB5; arc=none smtp.client-ip=209.85.208.173 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dUUw2TB5" Received: by mail-lj1-f173.google.com with SMTP id 38308e7fff4ca-38e7b0903cdso15099501fa.3 for ; Sat, 18 Apr 2026 07:47:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1776523666; x=1777128466; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=MNGi9+tIDznq2/odkG3FnpQo5XY+nW6Im4pa9lH4ZmA=; b=dUUw2TB5DO60Dp+VSmLmon0yQjxrrUlpv8UXD2++STW6LR6xUqlTcv36HsIrd0G4Rz JdX7gdHoEESzmzh0k3wCJS04MV1oH/zelvLpVvXU0xzTlp+YcdY/0MGg5a6QC10DMorW 6FUq/6/B9BFf5wACoGZmh9g+XK6KMHyE/sARMV6tFM4uf+dq8ndEsoAnrlZwTbeTEaHx 0QYzKHPEDc46ngnoMwRKMjgelFIgV9IctnIr0+7MlPDId2wpRgqgVM0aVPqhuA35PqkF 1vFe1dHH8YDadB+7bgLLf7c1O4tYh1cDdON4Tjw+fFlYmR90FHzhA1XE4SO9gimhl+n5 sstg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776523666; x=1777128466; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=MNGi9+tIDznq2/odkG3FnpQo5XY+nW6Im4pa9lH4ZmA=; b=ftOZ2vX9ZtvUAq1AuxWPKgsKHa5UhkFOJ9VbJ6vX87PcTjp61frxXg2ITn5klRvbEd x6tOkehnOr4nimqmNrGSgh4A4fqDAJpSxh9xOS5IYh5NgUOnioYKdod0fv/6Ft5bl0Vh 87ew9GValMXCWqn7C1g9pGja0AaV0FNFEMqviXpqC8f39cy/D6VdencfSN0P/OQHbBNE VKdb5lIYO80xqViZmlFnzbfjdwMKBItt/SPqcWJ/8SmBvhgHkkfgxUVdTgZZhP9Ztk8D du2+CM1bNbJ0BCDLgnzVWFsHNRDEA1bwrMuuisaVWXPLY45+SMpMd3fu/Y6qCy3xp0xs +CHw== X-Forwarded-Encrypted: i=1; AFNElJ8gZ/TloFm78feItibIi6j5XwvNq33otbwpakDM97OgeYjfUAj+3a/f6TmOKK5AB+xImUorPWReVnXG@vger.kernel.org X-Gm-Message-State: AOJu0YyvwEW0L35OwP/KkPbR//tvUy+sho/LEjfMcXcCp7ODf401F/o8 3wlv45LDLwaD0x9I4VQ6N7ncseDN6KyqZAteRf7UuaXHCed9s75EtfdL X-Gm-Gg: AeBDiet1k6Tg2ISIBbSA561GzvOqo505rEvQIlhEYr+YPQHs/5A7WfAJXjJC0rgLJZL +qRufV9TMoCZAcJMcvm5gDlCrw0cCvF1jc5NFcRrKCRj366+tvmW8psHYZf4I7NuHE8VVXnjurX D3iYHsUKQK01QcWQuK+xGWT7V3NTyOebBVqTjbxpBh3HyYmgEomYvmk1MXPsxpn2IQnKhL4/bgo qoBpNgAmZPUxmTFRE/nea8t1GB/N+9fhU9Z/F8UZC+o3kkwSUU4UJWdO7dbEcJGBZsWP18suZXj exPyjHqqI1rjDSUOrB1hcFHBd4++un21SpyhLdWWZ/GpOCRQ2FPm9nWVBPO+evr0KVdTJI5j0+5 DMYco9lFg8QUEBLATE0kbiDhhms9R3UKkK408ZD7R81qCvFksA1vGArV5Iu8ZVi4Vp/LEYW+IOQ mP/u5UsuBx9aX6fLAyDcynjlxpo5yzhbccHA== X-Received: by 2002:a2e:a549:0:b0:38e:1ebe:95f6 with SMTP id 38308e7fff4ca-38ec7b2a3camr23980721fa.28.1776523666347; Sat, 18 Apr 2026 07:47:46 -0700 (PDT) Received: from xeon ([188.163.112.56]) by smtp.gmail.com with ESMTPSA id 38308e7fff4ca-38ecb4f51easm10901001fa.6.2026.04.18.07.47.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Apr 2026 07:47:45 -0700 (PDT) From: Svyatoslav Ryhel To: Jonathan Cameron , David Lechner , =?UTF-8?q?Nuno=20S=C3=A1?= , Andy Shevchenko , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Arnd Bergmann , Greg Kroah-Hartman , Svyatoslav Ryhel , Randy Dunlap Cc: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v1 1/5] dt-bindings: iio: light: Document Avago APDS9900/9901 ALS/Proximity sensor Date: Sat, 18 Apr 2026 17:47:12 +0300 Message-ID: <20260418144716.132936-2-clamor95@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com> References: <20260418144716.132936-1-clamor95@gmail.com> Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Document Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor. Signed-off-by: Svyatoslav Ryhel --- .../bindings/iio/light/avago,apds9900.yaml | 83 +++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml diff --git a/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml new file mode 100644 index 000000000000..f5fb79439e56 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml @@ -0,0 +1,83 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/light/avago,apds9900.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor + +maintainers: + - Svyatoslav Ryhel + +description: | + The APDS-9900/9901 provides digital ambient light sensing (ALS), + IR LED and a complete proximity detection system in a single + 8 pin package over I2C interface. + Datasheet at https://docs.broadcom.com/doc/AV02-2867EN + +properties: + compatible: + enum: + - avago,apds9900 + - avago,apds9901 + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + vdd-supply: true + + avago,pdrive-microamp: + description: + The LED drive current is controlled by a regulated current + sink on the LDR pin. This feature eliminates the need to use + a current limiting resistor to control LED current. The LED + drive current can be configured for 12.5 mA, 25 mA, 50 mA + or 100 mA. For higher LED drive requirements, an external + P type transistor can be used to control the LED current. + enum: [12500, 25000, 50000, 100000] + default: 100000 + + avago,ppcount: + $ref: /schemas/types.yaml#/definitions/uint32 + description: + The number of LED pulses can be programmed to a value of 1 to + 255 pulses as needed. Increasing the number of LED pulses at a + given current will increase the sensor sensitivity. Sensitivity + grows by the square root of the number of pulses. Each pulse + has a 16 mS period. + minimum: 1 + maximum: 255 + default: 1 + +additionalProperties: false + +required: + - compatible + - reg + - interrupts + +examples: + - | + #include + + i2c { + #address-cells = <1>; + #size-cells = <0>; + + light-sensor@39 { + compatible = "avago,apds9900"; + reg = <0x39>; + + interrupt-parent = <&gpio>; + interrupts = <82 IRQ_TYPE_EDGE_RISING>; + + vdd-supply = <&vdd_2v85_als>; + + avago,pdrive-microamp = <100000>; + avago,ppcount = <3>; + }; + }; +... -- 2.51.0