Skip to content

Commit ea23f08

Browse files
njhollinghurstpelwell
authored andcommitted
overlays: Add vec-gpio-pi5-overlay
Add an overlay to allow composite video to be output on GPIOs 4-11 on Raspberry Pi 5, 500, 500+ or CM5 only, with an optional 108 MHz clock on GPIO 0 and duplicate MSB on GPIO 27. Requires composite video to be enabled and DPI to be disabled. Signed-off-by: Nick Hollinghurst <[email protected]>
1 parent df1d52b commit ea23f08

File tree

4 files changed

+67
-1
lines changed

4 files changed

+67
-1
lines changed

arch/arm/boot/dts/overlays/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
345345
vc4-kms-v3d-pi4.dtbo \
346346
vc4-kms-v3d-pi5.dtbo \
347347
vc4-kms-vga666.dtbo \
348+
vec-gpio-pi5.dtbo \
348349
vga666.dtbo \
349350
vl805.dtbo \
350351
w1-gpio.dtbo \

arch/arm/boot/dts/overlays/README

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5832,14 +5832,23 @@ Info: See vc4-kms-v3d-pi4 (this is the Pi 5 version)
58325832

58335833

58345834
Name: vc4-kms-vga666
5835-
Info: Enable the VGA666 (resistor ladder ADC) for the vc4-kms-v3d driver.
5835+
Info: Enable the VGA666 (resistor ladder DAC) for the vc4-kms-v3d driver.
58365836
Requires vc4-kms-v3d to be loaded.
58375837
Load: dtoverlay=vc4-kms-vga666,<param>
58385838
Params: ddc Enables GPIOs 0&1 as the I2C to read the EDID
58395839
from the display. NB These are NOT 5V tolerant
58405840
GPIOs, therefore level shifters are required.
58415841

58425842

5843+
Name: vec-gpio-pi5
5844+
Info: Overlay to output composite video as an 8-bit digital code over GPIO
5845+
pins 4-11, for Raspberry Pi 5 series only. Requires composite video
5846+
to be enabled; incompatible with any use of DPI or VGA666.
5847+
Load: dtoverlay=vec-gpio-pi5,<param>
5848+
Params: clk Enable GPIO 0 (clock, 108 MHz)
5849+
gpio27 Enable GPIO 27 (duplicate MSB)
5850+
5851+
58435852
Name: vga666
58445853
Info: Overlay for the Fen Logic VGA666 board
58455854
This uses GPIOs 2-21 (so no I2C), and activates the output 2-3 seconds

arch/arm/boot/dts/overlays/overlay_map.dts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,14 @@
518518
bcm2712;
519519
};
520520

521+
vec-gpio {
522+
bcm2712 = "vec-gpio-pi5";
523+
};
524+
525+
vec-gpio-pi5 {
526+
bcm2712;
527+
};
528+
521529
vl805 {
522530
bcm2711;
523531
};
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
/*
2+
* vec-gpio-pi5-overlay.dts
3+
*/
4+
5+
/dts-v1/;
6+
/plugin/;
7+
8+
/{
9+
compatible = "brcm,bcm2712";
10+
11+
fragment@0 {
12+
target = <&rp1_vec>;
13+
rp1vec_overlay: __overlay__ {
14+
pinctrl-names = "default";
15+
pinctrl-0 = <&rp1vec_ch0pins>, <&rp1vec_ch0pins>;
16+
};
17+
};
18+
19+
fragment@1 {
20+
target = <&gpio>;
21+
__overlay__ {
22+
rp1vec_ch0pins: rp1vec_ch0pins {
23+
function = "dpi";
24+
pins = "gpio4", "gpio5", "gpio6", "gpio7",
25+
"gpio8", "gpio9", "gpio10", "gpio11";
26+
bias-disable;
27+
drive-strength = <12>;
28+
};
29+
rp1vec_pin27: rp1vec_pin27 {
30+
function = "dpi";
31+
pins = "gpio27";
32+
bias-disable;
33+
drive-strength = <12>;
34+
};
35+
rp1vec_clkpin: rp1vec_clkpin {
36+
function = "dpi";
37+
pins = "gpio0";
38+
bias-disable;
39+
drive-strength = <12>;
40+
};
41+
};
42+
};
43+
44+
__overrides__ {
45+
gpio27 = <&rp1vec_overlay>, "pinctrl-0:4=", <&rp1vec_pin27>;
46+
clk = <&rp1vec_overlay>, "pinctrl-0:8=", <&rp1vec_clkpin>;
47+
};
48+
};

0 commit comments

Comments
 (0)