40 lines
1.3 KiB
Plaintext
40 lines
1.3 KiB
Plaintext
/*
|
|
* iec-overlay.dts - pin reservation + pull configuration for the IEC listener.
|
|
*
|
|
* GPIO 2 = ATN (input, pull-up: bus idle = 5 V = high)
|
|
* GPIO 17 = CLK (input, pull-up)
|
|
* GPIO 3 = RESET (input, pull-up)
|
|
* GPIO 18 = DATA (bidirectional; starts as input/Hi-Z, the module flips it)
|
|
*
|
|
* The module drives GPIO via direct registers, so this overlay's main job is to
|
|
* reserve the pins and set sane pull defaults. Build & install:
|
|
* dtc -@ -I dts -O dtb -o iec-overlay.dtbo iec-overlay.dts
|
|
* sudo cp iec-overlay.dtbo /boot/firmware/overlays/ # Bookworm path
|
|
* echo "dtoverlay=iec-overlay" | sudo tee -a /boot/firmware/config.txt
|
|
* # reboot, then: dtoverlay -l
|
|
*
|
|
* See _research/pi-kernel-module-rt-gpio-2026-06-18.md §4.1.
|
|
*/
|
|
/dts-v1/;
|
|
/plugin/;
|
|
|
|
/ {
|
|
compatible = "brcm,bcm2837";
|
|
|
|
fragment@0 {
|
|
target = <&gpio>;
|
|
__overlay__ {
|
|
iec_input_pins: iec_input_pins {
|
|
brcm,pins = <2 17 3>; /* ATN, CLK, RESET */
|
|
brcm,function = <0>; /* 0 = input */
|
|
brcm,pull = <2>; /* 2 = pull-up */
|
|
};
|
|
iec_data_pin: iec_data_pin {
|
|
brcm,pins = <18>; /* DATA */
|
|
brcm,function = <0>; /* start as input (Hi-Z) */
|
|
brcm,pull = <0>; /* 0 = none (shifter drives) */
|
|
};
|
|
};
|
|
};
|
|
};
|