Excellent, thank you! I got my GPIO CS pins to work. For reference (in case 
anyone needs the same information), here's my dts file:



/dts-v1/;
/plugin/;

/ {
compatible = "ti,beaglebone", "ti,beaglebone-black";
/* identification */
part-number = "BB-SPICAPE-01";
version = "00A0";

fragment@0 {
target = <&ocp>;
__overlay__ {
P9_17_pinmux { status = "disabled"; }; 
P9_18_pinmux { status = "disabled"; }; 
P9_21_pinmux { status = "disabled"; }; 
P9_22_pinmux { status = "disabled"; }; 
P8_10_pinmux { status = "disabled"; }; 
};
};

fragment@1 {
target = <&am33xx_pinmux>;

__overlay__ {
#address-cells = <1>;
#size-cells = <1>;

bb_spi0_pins: pinmux_bb_spi0_pins {
pinctrl-single,pins = <
0x150 0x30 /* spi0_sclk.spi0_sclk, INPUT_PULLUP | MODE0 */
0x154 0x30 /* spi0_d0.spi0_d0, INPUT_PULLUP | MODE0 */
0x158 0x10 /* spi0_d1.spi0_d1, OUTPUT_PULLUP | MODE0 */
0x15c 0x10 /* spi0_cs0.spi0_cs0, OUTPUT_PULLUP | MODE0 */
0x098 0x17 /* P8 10 gpio2_4.spi0_cs1 OUTPUT_PULLUP | MODE7 */
>;
};
};
};

fragment@2 {
target = <&spi0>; /* spi0 is numbered correctly */

__overlay__ {
#address-cells = <1>;
#size-cells = <0>;

status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&bb_spi0_pins>;

cs-gpios = <0>, <&gpio2 4 0>;

spi0@0{
#address-cells = <1>;
#size-cells = <0>;
compatible = "linux,spidev";
reg = <0>;
spi-max-frequency = <16000000>;
};

spi0@1 {
#address-cells = <1>;
#size-cells = <0>;
compatible = "linux,spidev";
reg = <1>;
spi-max-frequency = <16000000>;
};
};
};

};



On Tuesday, December 4, 2018 at 2:12:17 PM UTC-8, RobertCNelson wrote:
>
> On Tue, Dec 4, 2018 at 4:03 PM <[email protected] <javascript:>> wrote: 
> > 
> > Here's the output: 
> > 
> > git:/opt/scripts/:[0726131c362e3adfcf359f3e1debf5ff156e5bec] 
> > eeprom:[A335BNLT000CyywwBBoxxxx] 
> > model:[TI_AM335x_BeagleBone_Black] 
> > dogtag:[Machinekit Debian Image 2018-09-16] 
> > bootloader:[eMMC-(default)]:[/dev/mmcblk1]:[U-Boot 
> 2018.09-00002-g0b54a51eee]:[location: dd MBR] 
> > kernel:[4.14.69-ti-rt-r75] 
> > uboot_overlay_options:[enable_uboot_overlays=1] 
> > 
> uboot_overlay_options:[uboot_overlay_addr4=/lib/firmware/BB-SPICAPE-01-00A0.dtbo]
>  
>
> > uboot_overlay_options:[disable_uboot_overlay_audio=1] 
> > 
> uboot_overlay_options:[uboot_overlay_pru=/lib/firmware/AM335X-PRU-UIO-00A0.dtbo]
>  
>
> > uboot_overlay_options:[enable_uboot_cape_universal=1] 
> > pkg check: to individually upgrade run: [sudo apt install --only-upgrade 
> <pkg>] 
> > pkg:[bb-cape-overlays]:[4.4.20181120.0-0rcnee0~stretch+20181120] 
> > pkg:[bb-wl18xx-firmware]:[1.20180517-0rcnee0~stretch+20180517] 
> > pkg:[kmod]:[23-2rcnee1~stretch+20171005] 
> > 
> pkg:[roboticscape]:[0.4.4-git20180608.0-0rcnee0~stretch+20180609]:[GOT_REPLACED_BY_NEXT]
>  
>
> > WARNING:pkg:[librobotcontrol]:[NOT_INSTALLED] 
> > pkg:[firmware-ti-connectivity]:[20170823-1rcnee1~stretch+20180328] 
> > groups:[machinekit : machinekit adm kmem dialout cdrom floppy audio dip 
> video plugdev users systemd-journal i2c bluetooth netdev gpio pwm eqep 
> admin spi tisdk weston-launch xenomai cloud9ide] 
> > cmdline:[console=ttyO0,115200n8 bone_capemgr.uboot_capemgr_enabled=1 
> root=/dev/mmcblk1p1 ro rootfstype=ext4 rootwait coherent_pool=1M 
> net.ifnames=0 quiet] 
> > dmesg | grep pinctrl-single 
> > [    1.424240] pinctrl-single 44e10800.pinmux: 142 pins at pa f9e10800 
> size 568 
> > [    1.565570] pinctrl-single 44e10800.pinmux: pin PIN84 already 
> requested by ocp:P9_22_pinmux; cannot claim for 48030000.spi 
> > [    1.576764] pinctrl-single 44e10800.pinmux: pin-84 (48030000.spi) 
> status -22 
> > [    1.583861] pinctrl-single 44e10800.pinmux: could not request pin 84 
> (PIN84) from group pinmux_bb_spi0_pins  on device pinctrl-single 
> > dmesg | grep gpio-of-helper 
> > [    1.445942] gpio-of-helper ocp:cape-universal: ready 
> > END 
>
> Ah i see what your doing now.. 
>
> Take a look at these 4 examples, your missing the "cape-universal" 
> disable pins in fragment0, but you see how to use the 3rd cs-gpio in 
> these exmples.. 
>
> P9_22_pinmux { status = "disabled"; }; /* RX3 */ 
>
>
> https://github.com/beagleboard/bb.org-overlays/blob/master/src/arm/BB-mBC1-ETH-CLICK.dts
>  
>
>
> https://github.com/beagleboard/bb.org-overlays/blob/master/src/arm/BB-mBC2-ETH-CLICK.dts
>  
>
>
> https://github.com/beagleboard/bb.org-overlays/blob/master/src/arm/BB-mBC3-ETH-CLICK.dts
>  
>
>
> https://github.com/beagleboard/bb.org-overlays/blob/master/src/arm/BB-mBC4-ETH-CLICK.dts
>  
>
> Regards, 
>
> -- 
> Robert Nelson 
> https://rcn-ee.com/ 
>

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/974ffa56-723b-4717-ba57-927c05ecfe52%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to