New Drivers with 3.12.20+ kernel and up to 64 MHz SPI clock

Topics that concern all LCD-PI shields. New drivers and images for Raspberry Pi will be released through this forum.

New Drivers with 3.12.20+ kernel and up to 64 MHz SPI clock

Postby strancara » Fri Jun 13, 2014 9:01 pm

Drivers for all LCD-PIs have been refreshed. New features:
-DMA support
-up to 64 MHz SPI clock (48 MHz default)

Install procedure:
1. download and flash a Raspbian image to a SD card
2. expand file system, do not select boot into graphical user interface in raspi-config
3. login as pi/raspberry and install kernel with drivers:
Code: Select all
wget http://www.hwlevel.com/hwlevel/Files/kernel_pi_3.12.20+.tar.gz
sudo tar -xzvf kernel_pi_3.12.20+.tar.gz -C /
#sudo nano /boot/config.txt
#scroll to the end of file and uncomment the line that is right for your module
#CTRL+x
sudo reboot

4. (optional) if driver module is preferred to having the driver compiled into kernel select kernel_pim.img whe editing the /boot/config.txt file. Then a driver module can be loaded with:
Code: Select all
modprobe ili9486 #IPS-PI40
modprobe ssd1289 #LCD-PI32
modprobe d51 #LCD-PI33
modprobe ssd1963 #LCD-PI43 and LCD-PI50

To auto load the module the /etc/modules file can be edited. Uncomment one of above modules there.
strancara
Site Admin
 
Posts: 32
Joined: Fri Mar 14, 2014 1:45 pm

Re: New Drivers with 3.12.20+ kernel

Postby strancara » Fri Jun 13, 2014 9:16 pm

All drivers have a sclk parameter which determines the SPI clock frequency. To set the frequency to 64 MHz for IPS-PI40 the syntax is:
Code: Select all
modprobe ili9486 sclk=64000000

Drivers for IPS-PI40, LCD-PI33, LCD-PI43 and LCD-PI50 also have a compress parameter. If compress is set to 1 the data transferred over SPI is compressed on the fly. Especially in GUIs this technique works very well. Some examples (that work on my RPi):
Code: Select all
modprobe ili9486 sclk=64000000
modprobe d51 sclk=32000000 compress=1
modprobe d51 sclk=64000000 compress=0
modprobe ssd1963 sclk=48000000 compress=1

Higher SPI clocks are on RPi's limit and whether they work or not might depend on power supply quality and other factors.

The ssd1963 driver for LCD-PI43 and LCD-PI50 also has a rotation parameter which can be 0, 90, 180 or 270. It rotates the screen to desired orientation.
strancara
Site Admin
 
Posts: 32
Joined: Fri Mar 14, 2014 1:45 pm

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby sunitram59 » Wed Jul 02, 2014 9:00 am

Hello,
Tx, new drivers installed and works like a sharm, but when i startx after 10min the screensaver make LCD32 complete black.
Tryed everything xset .... , even installed screensaver, red all topics but nothing helps.
Something else look strange, I had to add "Option "SwapAxes" "True" , was not so in the previous preinstalled version.

Found the solution:
edit /etc/X11/xinit/xserverrc and changing

exec /usr/bin/X -nolisten tcp "$@"
To:
exec /usr/bin/X -s 0 dpms -nolisten tcp "$@"
sunitram59
 
Posts: 1
Joined: Wed Jul 02, 2014 8:56 am

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby rysiek » Mon Jul 14, 2014 9:19 am

Where can I download driver source for this kernel? (I neet do compile my own kernel)

And is there a chance that they will be in "patch" format.
rysiek
 
Posts: 1
Joined: Mon Jul 14, 2014 8:03 am

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby golem_XIV » Tue Sep 16, 2014 6:14 pm

Hello,

Is it possible to get a source code of the drivers for IPS-PI40?
It seems that there is a newer kernel available for raspbian (3.12.26+), but I cannot see any driver's update.

regards
golem_XIV
 
Posts: 1
Joined: Tue Sep 16, 2014 5:54 pm

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby bug » Thu Sep 18, 2014 10:31 am

Please, I also need the source code of the drivers for IPS-PI40.
I would like to build the module for my standar kernel.

Thank you very much in advance.
bug
 
Posts: 1
Joined: Thu Sep 18, 2014 10:28 am

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby rbal » Sat Nov 08, 2014 4:27 pm

Hi

I have a Pi40 LCD installed on my raspberry pi (model B) with Raspbian (09-09-2014) and it works fine but i have a problem using it alongside the MCP23017 i2c microchip.

Before I installed the drivers for the PI40 the MCP23017 microchip works fine, when i type i2cdetect -y 1 on the terminal it shows the MCP23017 on port 0x20 and everything that is connected to the microchip work without a problem.
After I installed the drivers for the LCD the MCP23017 microchip still works but the values keep changing like the i2c bus is unstable.

If i disable the LCD module in /boot/config.txt the i2c works great again, so i think the drivers are interfering with the i2c bus or overwriting something.

If someone knows anything about this I will appreciate your help as I have being trying different version of Raspbian and re installing packages but no success.


Thank you
rbal
 
Posts: 2
Joined: Sat Nov 08, 2014 11:03 am

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby paulhan » Sat Nov 22, 2014 3:27 am

Hi, I'm not having any luck getting this up and running with the 4" screen. I started with a brand new Raspbian image, then loaded the drivers and altered the config.txt file. I've tried it the standard way and using modprobe.

Using modprobe does nothing, and when I type startx this is what I get

X.Org X Server 1.12.4
Release Date: 2012-08-27
X Protocol Version 11, Revision 0
Build Operating System: Linux 3.2.0-2-mx5 armv7l Debian
Current Operating System: Linux raspberrypi 3.12.20+ #108 PREEMPT Sat Sep 6 09:24:45 CEST 2014 armv6l
Kernel command line: dma.dmachans=0x7f35 bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416 bcm2708.boardrev=0xe bcm2708.serial=0x921cf1c9 smsc95xx.macaddr=B8:27:EB:1C:F1:C9 sdhci-bcm2708.emmc_clock_freq=250000000 vc_mem.mem_base=0x1ec00000 vc_mem.mem_size=0x20000000 dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait fbcon=map:10
Build Date: 18 December 2013 05:20:52PM
xorg-server 2:1.12.4-6+deb7u2 (Julien Cristau <jcristau@debian.org>)
Current version of pixman: 0.33.1
Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.1.log", Time: Sat Nov 22 03:22:47 2014
(==) Using system config directory "/usr/share/X11/xorg.conf.d"
FATAL: Module g2d_23 not found.


This is the output of the Xorg log file.
[ 362.000] (II) AIGLX: Screen 0 is not DRI2 capable
[ 362.004] (II) AIGLX: Screen 0 is not DRI capable
[ 362.007] (EE) AIGLX error: dlopen of /usr/lib/arm-linux-gnueabihf/dri/swrast_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/swrast_dri.so: cannot open shared object file: No such file or directory)
[ 362.007] (EE) GLX: could not load software renderer
[ 362.007] (II) GLX: no usable GL providers found for screen 0
[ 362.327] (II) config/udev: Adding input device ADS7846 Touchscreen (/dev/input/event0)
[ 362.327] (**) ADS7846 Touchscreen: Applying InputClass "evdev touchscreen catchall"
[ 362.328] (II) LoadModule: "evdev"
[ 362.329] (II) Loading /usr/lib/xorg/modules/input/evdev_drv.so
[ 362.330] (II) Module evdev: vendor="X.Org Foundation"
[ 362.331] compiled for 1.12.1, module version = 2.7.0
[ 362.331] Module class: X.Org XInput Driver
[ 362.331] ABI class: X.Org XInput driver, version 16.0
[ 362.331] (II) Using input driver 'evdev' for 'ADS7846 Touchscreen'
[ 362.332] (**) ADS7846 Touchscreen: always reports core events
[ 362.332] (**) evdev: ADS7846 Touchscreen: Device: "/dev/input/event0"
[ 362.332] (--) evdev: ADS7846 Touchscreen: Vendor 0 Product 0
[ 362.332] (--) evdev: ADS7846 Touchscreen: Found absolute axes
[ 362.333] (--) evdev: ADS7846 Touchscreen: Found x and y absolute axes
[ 362.333] (--) evdev: ADS7846 Touchscreen: Found absolute touchscreen
[ 362.333] (II) evdev: ADS7846 Touchscreen: Configuring as touchscreen
[ 362.333] (**) evdev: ADS7846 Touchscreen: YAxisMapping: buttons 4 and 5
[ 362.334] (**) evdev: ADS7846 Touchscreen: EmulateWheelButton: 4, EmulateWheelInertia: 10, EmulateWheelTimeout: 200
[ 362.334] (**) Option "config_info" "udev:/sys/devices/platform/bcm2708_spi.0/spi_master/spi0/spi0.1/input/input0/event0"
[ 362.334] (II) XINPUT: Adding extended input device "ADS7846 Touchscreen" (type: TOUCHSCREEN, id 6)
[ 362.335] (II) evdev: ADS7846 Touchscreen: initialized for absolute axes.
[ 362.336] (**) ADS7846 Touchscreen: (accel) keeping acceleration scheme 1
[ 362.337] (**) ADS7846 Touchscreen: (accel) acceleration profile 0
[ 362.337] (**) ADS7846 Touchscreen: (accel) acceleration factor: 2.000
[ 362.337] (**) ADS7846 Touchscreen: (accel) acceleration threshold: 4
[ 362.340] (II) config/udev: Adding input device ADS7846 Touchscreen (/dev/input/mouse0)
[ 362.341] (II) No input driver specified, ignoring this device.
[ 362.341] (II) This device may have been added with another device file.
[ 362.385] (EE) FBTURBO(0): FBIOBLANK: Operation not permitted
[ 875.350] (II) evdev: ADS7846 Touchscreen: Close
[ 875.351] (II) UnloadModule: "evdev"
[ 875.367] Server terminated successfully (0). Closing log file.
paulhan
 
Posts: 1
Joined: Tue Nov 11, 2014 7:28 pm

Re: New Drivers with 3.12.20+ kernel and up to 64 MHz SPI cl

Postby strancara » Wed Nov 26, 2014 9:19 am

try (by default GUI runs on fb0 = HDMI):

FRAMEBUFFER=/dev/fb1 startx
strancara
Site Admin
 
Posts: 32
Joined: Fri Mar 14, 2014 1:45 pm


Return to LCD-PI Common Topics

Who is online

Users browsing this forum: No registered users and 7 guests

cron