summaryrefslogtreecommitdiff
path: root/src/arm/BB-UART1-RTSCTS-00A0.dts
blob: 9ad56e0a7c209d7c2af5e30550d047311e2c177b (plain)
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
/*
 * Copyright 2018
 * Yantrr Electronic Systems Pvt. Ltd. - http://www.yantrr.com/
 *
 * BeagleBone cape RS485 / RS422 using UART1-RTSCTS connector pins P9.19 P9.20
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or 
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
*/

/dts-v1/;
/plugin/;

/{
	/*
	 * Helper to show loaded overlays under: /proc/device-tree/chosen/overlays/
	 */
	fragment@0 {
		target-path="/";
		__overlay__ {

			chosen {
				overlays {
					BB-UART1-RTSCTS-00A0 = __TIMESTAMP__;
				};
			};
		};
	};

	/*
	 * Free up the pins used by the cape from the pinmux helpers.
	 */
	fragment@1 {
		target = <&ocp>;
		__overlay__ {
			P9_19_pinmux { status = "disabled"; };	/* P9_19: mode 0 (uart1_rtsn) */
			P9_20_pinmux { status = "disabled"; };	/* P9_20: mode 0 (uart1_ctsn) */
		};
	};

	fragment@2 {
		target = <&am33xx_pinmux>;
		__overlay__ {
			u1_rtscts_pins: pinmux_u1_rtscts_pins {
				pinctrl-single,pins = <
					0x17c 0x08	/* P9_19: mode 0 (uart1_rtsn) */
					0x178 0x30	/* P9_20: mode 0 (uart1_ctsn) */
				>;
			};
		};
	};

	fragment@3 {
		target = <&ocp>; /* On-Chip Peripherals */
		__overlay__ {
			uart1-rtscts-pinmux {
				compatible = "bone-pinmux-helper"; /* Use the pinmux helper */
				status="okay";
				/* Define custom names for indexes in pinctrl array: */
				pinctrl-names = "default";
				/* Set the elements of the pinctrl array to the pinmux overlays
				defined above: */
				pinctrl-0 = <&u1_rtscts_pins>;
			};
		};
	};
};