Repository navigation
Add IMX519 driver and device tree overlay #4548
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
30c72bf
media: dt-bindings: media: i2c: Add IMX519 CMOS sensor binding
2534515
media: i2c: Add driver for IMX519 sensor
d7f51b1
media: i2c: imx519: Advertise embedded data node on media pad 1
ArduCAM 948fbce
configs: Add CONFIG_VIDEO_IMX519=m
beab022
overlays: Add imx519-overlay.dts
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
113 changes: 113 additions & 0 deletions
113
Documentation/devicetree/bindings/media/i2c/imx519.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,113 @@ | ||
| # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) | ||
| %YAML 1.2 | ||
| --- | ||
| $id: http://devicetree.org/schemas/media/i2c/imx519.yaml# | ||
| $schema: http://devicetree.org/meta-schemas/core.yaml# | ||
|
|
||
| title: Sony 1/2.5-Inch 16Mpixel CMOS Digital Image Sensor | ||
|
|
||
| maintainers: | ||
| - Lee Jackson <info@arducam.com> | ||
|
|
||
| description: |- | ||
| The Sony IMX519 is a 1/2.5-inch CMOS active pixel digital image sensor | ||
| with an active array size of 4656H x 3496V. It is programmable through | ||
| I2C interface. The I2C address is fixed to 0x1A as per sensor data sheet. | ||
| Image data is sent through MIPI CSI-2, which is configured as either 2 or | ||
| 4 data lanes. | ||
| properties: | ||
| compatible: | ||
| const: sony,imx519 | ||
|
|
||
| reg: | ||
| description: I2C device address | ||
| maxItems: 1 | ||
|
|
||
| clocks: | ||
| maxItems: 1 | ||
|
|
||
| VDIG-supply: | ||
| description: | ||
| Digital I/O voltage supply, 1.05 volts | ||
|
|
||
| VANA-supply: | ||
| description: | ||
| Analog voltage supply, 2.8 volts | ||
|
|
||
| VDDL-supply: | ||
| description: | ||
| Digital core voltage supply, 1.8 volts | ||
|
|
||
| reset-gpios: | ||
| description: |- | ||
| Reference to the GPIO connected to the xclr pin, if any. | ||
| Must be released (set high) after all supplies and INCK are applied. | ||
| # See ../video-interfaces.txt for more details | ||
| port: | ||
| type: object | ||
| properties: | ||
| endpoint: | ||
| type: object | ||
| properties: | ||
| data-lanes: | ||
| description: |- | ||
| The sensor supports either two-lane, or four-lane operation. | ||
| For two-lane operation the property must be set to <1 2>. | ||
| items: | ||
| - const: 1 | ||
| - const: 2 | ||
|
|
||
| clock-noncontinuous: | ||
| type: boolean | ||
| description: |- | ||
| MIPI CSI-2 clock is non-continuous if this property is present, | ||
| otherwise it's continuous. | ||
| link-frequencies: | ||
| allOf: | ||
| - $ref: /schemas/types.yaml#/definitions/uint64-array | ||
| description: | ||
| Allowed data bus frequencies. | ||
|
|
||
| required: | ||
| - link-frequencies | ||
|
|
||
| required: | ||
| - compatible | ||
| - reg | ||
| - clocks | ||
| - VANA-supply | ||
| - VDIG-supply | ||
| - VDDL-supply | ||
| - port | ||
|
|
||
| additionalProperties: false | ||
|
|
||
| examples: | ||
| - | | ||
| i2c0 { | ||
| #address-cells = <1>; | ||
| #size-cells = <0>; | ||
| imx519: sensor@1a { | ||
| compatible = "sony,imx519"; | ||
| reg = <0x1a>; | ||
| clocks = <&imx519_clk>; | ||
| VANA-supply = <&imx519_vana>; /* 2.8v */ | ||
| VDIG-supply = <&imx519_vdig>; /* 1.05v */ | ||
| VDDL-supply = <&imx519_vddl>; /* 1.8v */ | ||
| port { | ||
| imx519_0: endpoint { | ||
| remote-endpoint = <&csi1_ep>; | ||
| data-lanes = <1 2>; | ||
| clock-noncontinuous; | ||
| link-frequencies = /bits/ 64 <493500000>; | ||
| }; | ||
| }; | ||
| }; | ||
| }; | ||
| ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,115 @@ | ||
| // SPDX-License-Identifier: GPL-2.0-only | ||
| // Definitions for imx519 camera module on VC I2C bus | ||
| /dts-v1/; | ||
| /plugin/; | ||
|
|
||
| #include <dt-bindings/gpio/gpio.h> | ||
|
|
||
| /{ | ||
| compatible = "brcm,bcm2835"; | ||
|
|
||
| fragment@0 { | ||
| target = <&i2c_csi_dsi>; | ||
| __overlay__ { | ||
| #address-cells = <1>; | ||
| #size-cells = <0>; | ||
| status = "okay"; | ||
|
|
||
| imx519: imx519@1a { | ||
| compatible = "sony,imx519"; | ||
| reg = <0x1a>; | ||
| status = "okay"; | ||
|
|
||
| clocks = <&imx519_clk>; | ||
| clock-names = "xclk"; | ||
|
|
||
| VANA-supply = <&cam1_reg>; /* 2.8v */ | ||
| VDIG-supply = <&imx519_vdig>; /* 1.8v */ | ||
| VDDL-supply = <&imx519_vddl>; /* 1.2v */ | ||
|
|
||
| rotation = <0>; | ||
| orientation = <2>; | ||
|
|
||
| port { | ||
| imx519_0: endpoint { | ||
| remote-endpoint = <&csi1_ep>; | ||
| clock-lanes = <0>; | ||
| data-lanes = <1 2>; | ||
| clock-noncontinuous; | ||
| link-frequencies = | ||
| /bits/ 64 <493500000>; | ||
| }; | ||
| }; | ||
| }; | ||
| }; | ||
| }; | ||
|
|
||
| fragment@1 { | ||
| target = <&csi1>; | ||
| __overlay__ { | ||
| status = "okay"; | ||
|
|
||
| port{ | ||
| csi1_ep: endpoint{ | ||
| remote-endpoint = <&imx519_0>; | ||
| clock-lanes = <0>; | ||
| data-lanes = <1 2>; | ||
| clock-noncontinuous; | ||
| }; | ||
| }; | ||
| }; | ||
| }; | ||
|
|
||
| fragment@2 { | ||
| target = <&i2c0if>; | ||
| __overlay__ { | ||
| status = "okay"; | ||
| }; | ||
| }; | ||
|
|
||
| fragment@3 { | ||
| target-path="/"; | ||
| __overlay__ { | ||
| imx519_vdig: fixedregulator@1 { | ||
| compatible = "regulator-fixed"; | ||
| regulator-name = "imx519_vdig"; | ||
| regulator-min-microvolt = <1800000>; | ||
| regulator-max-microvolt = <1800000>; | ||
| }; | ||
| imx519_vddl: fixedregulator@2 { | ||
| compatible = "regulator-fixed"; | ||
| regulator-name = "imx519_vddl"; | ||
| regulator-min-microvolt = <1200000>; | ||
| regulator-max-microvolt = <1200000>; | ||
| }; | ||
|
|
||
| imx519_clk: camera-clk { | ||
| compatible = "fixed-clock"; | ||
| #clock-cells = <0>; | ||
| clock-frequency = <24000000>; | ||
| }; | ||
| }; | ||
| }; | ||
|
|
||
| fragment@4 { | ||
| target = <&i2c0mux>; | ||
| __overlay__ { | ||
| status = "okay"; | ||
| }; | ||
| }; | ||
|
|
||
| fragment@5 { | ||
| target = <&cam1_reg>; | ||
| __overlay__ { | ||
| status = "okay"; | ||
| regulator-name = "imx519_vana"; | ||
| regulator-min-microvolt = <2800000>; | ||
| regulator-max-microvolt = <2800000>; | ||
| }; | ||
| }; | ||
|
|
||
| __overrides__ { | ||
| rotation = <&imx519>,"rotation:0"; | ||
|
ArduCAM marked this conversation as resolved.
Resolved
|
||
| orientation = <&imx519>,"orientation:0"; | ||
| }; | ||
| }; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.