Enabling SPI in BBB, Debian Stretch

I’m trying to enable SPI on my BBB but constantly fail following the advises I find in the forums.

It seems like echoing anything into /sys/devices/platform/bone_capemgr/slots is obsolete. Instead I should set up in /boot/uEnv.txt, but how? What should I add in that file?

I’ve tried:
optargs=quiet drm.debug=7 capemgr.enable_partno=BB-SPI0-01

…but I still don’t get anything named spi* under /dev/ (yes, I’ve rebooted)

ls -l /dev/spi*
ls: cannot access ‘/dev/spi*’: No such file or directory

I would be happy with only one SPI, like SPI0 so I wouldn’t have to bother with disabling HDMI.

This is the state of my setup: sudo /opt/scripts/tools/version.sh
dogtag:[BeagleBoard.org Debian Image 2018-01-28]
bootloader:[eMMC-(default)]:[/dev/mmcblk1]:[U-Boot 2018.01-00002-g9aa111a004]
groups:[debian : debian adm kmem dialout cdrom floppy audio dip video plugdev users systemd-journal i2c bluetooth netdev cloud9ide gpio pwm eqep admin spi tisdk weston-launch xenomai]
dmesg | grep pinctrl-single
[ 1.380806] pinctrl-single 44e10800.pinmux: 142 pins at pa f9e10800 size 568

Anyone out there, who knows what to do?




Development goes so fast. Too bad the people who posted BBB infos don't
update their web pages.

Thank you Robert,

That did the trick.

However, it has the side-effect of turning my display all black.
I use a Newhaven display cape and according to its User Guide, there should be no conflict for these SPI-pins.

So I had a look at the assigned pins in /sys/kernel/debug/pinctrl/44e10800.pinmux/pingroups and see that following group is added (using diff):

group: pinmux_bb_spi0_pins
pin 84 (PIN84)
pin 85 (PIN85)
pin 86 (PIN86)
pin 87 (PIN87)

which seems in order, but following groups were removed:

< group: pinmux_bb_lcd_pwm_backlight_pins
< pin 18 (PIN18)

< group: pinmux_bb_lcd_lcd_pins
< pin 40 (PIN40)
< pin 41 (PIN41)
< pin 42 (PIN42)
< pin 43 (PIN43)
< pin 44 (PIN44)
< pin 45 (PIN45)
< pin 46 (PIN46)
< pin 47 (PIN47)
< pin 48 (PIN48)
< pin 49 (PIN49)
< pin 50 (PIN50)
< pin 51 (PIN51)
< pin 52 (PIN52)
< pin 53 (PIN53)
< pin 54 (PIN54)
< pin 55 (PIN55)
< pin 15 (PIN15)
< pin 14 (PIN14)
< pin 13 (PIN13)
< pin 12 (PIN12)
< pin 11 (PIN11)
< pin 10 (PIN10)
< pin 9 (PIN9)
< pin 8 (PIN8)
< pin 56 (PIN56)
< pin 57 (PIN57)
< pin 58 (PIN58)
< pin 59 (PIN59)
< pin 35 (PIN35)

< group: pinmux_edt_ft5x06_pins
< pin 105 (PIN105)

I don’t know about the last group (PIN105) but the other two groups most certainly affect the display function.

I haven’t seen the corresponding .dts-file for BB-SPIDEV0-00A0.dtbo, but I tried making my own that should not touch these pins: Still, the same result (same pin groups are removed).

There seems to be some mechanism that disables the display pins when adding an overlay to the uEnv.txt.

Robert, as an expert in BBB, do you have answer to this?

Best regards,
Jon Lundström.

Well, addr0 -> addr3 is for eeprom detected capes, so change:






Thanks again, Robert,

The display now works and I’ve been able to loop the SPI back to the BBB.

I’m grateful for your help,