SPI with linux-3.18/3.19

7 3380
can anyone help out?
in lemaker tree for 3.4 there is a driver for spi-sun7i but in all newer linux version from mainline to sunxi there isnt. there are only spi-sun4i an spi-sun6i.
without a working driver for spi it is not possible to get fbtft working and some other things.
wiringbp looks also for spi-sun7i to load: gpio load spi
SPI support is included in mainline Kernel since version 3.15. The driver that is used should be spi-sun4i. If you look at the device tree file sun7i-a20.dtsi you will see that SPI regulators are registered as sun4i compatible. This is also the case for some other drivers (where A10 and A20 SoCs don't differ), that sun7i devices include sun4i drivers.

ok thanks then i have to rewrite gpio.c from wiringbp

Edited by a1d3s at Wed Jan 21, 2015 18:36

bpi@bpi-m1-jessie:~$ gpio load spi
gpio: Warning: File not present: /dev/spidev0.0
gpio: Warning: File not present: /dev/spidev0.1
  1. bpi@bpi-m1-jessie:~$ ls /dev/spidev*
  2. ls: cannot access /dev/spidev*: No such file or directory
Copy the Code
  1. /etc/modules: kernel modules to load at boot time.
  2. #
  3. # This file contains the names of kernel modules that should be loaded
  4. # at boot time, one per line. Lines beginning with "#" are ignored.
  5. spi
  6. spidev
  7. spi-sun4i
Copy the Code
  1. Module                  Size  Used by
  2. brcmfmac              203168  0
  3. brcmutil                4831  1 brcmfmac
  4. flexfb                 12273  0
  5. fbtft                  26106  1 flexfb
  6. syscopyarea             2865  1 fbtft
  7. sysfillrect             3239  1 fbtft
  8. sysimgblt               2029  1 fbtft
  9. fb_sys_fops             1037  1 fbtft
  10. spi_sun4i               3602  0
  11. spidev                  5131  0
Copy the Code
something went wrong grml

played around with boot.scr but no changes.

You could ask for help at the sunxi mailinglist or IRC channel. There are a few people who are familiar with the spi code. I quickly searched the mailinglist, but dind't come up with anythin useful in particular, except the information, that spi-sun4i is indeed the correct driver for SPI in A20 based devices like hte Banana Pi. Maybe the DT definitions for Banana Pi are incomplete in this regard, but that's just a wild guess.

OK i will ask later in IRC

hm i found that i have to include these lines for fbtft in bananapro.dts and change &gpio to &pio and the number to something like <&pio 8 16 0> but dont get any screen .
i got an waveshare/spotpear 3,5" tft
in document to this display hey wrote it is needed a c lib but these are only for bcm25* and wiringpi

You have to log in before you can reply Login | Sign Up

Points Rules