While we are waiting for the Raspberry Pi Foundation to release its DSI display, some companies are faster.
One of these companies is 4D-Systems. 4D-systems are specialized in small displays modules, ranging from 1.38″ autonomous round display to BeagleBone 7″ touch. Some modules are designed for standalone use, while others are designed especially for Arduino, Beaglebone, or Raspberry Pi.
Today I’m reviewing the 4DPI-35 display module for Raspberry Pi.
The 4DPI-35 is a 3.5 inch RGB 480*320 SPI display with capacitive touchpanel designed for Raspberry Pi (A/B/A+/B+/2). It plugs directly on the GPIO header and has a 26pin GPIO expander. It also has 4 mounting holes on the sides, and there are 10 unused pads for 5 additional buttons (I don’t know yet if this part is functionnal).
|Full rear view of the module||Close-up of GPIO connector and 26 pins expander|
Display controller is a Xilinx XC9572XL and touch controller is a Texas Instruments TSC2046.
|Xilinx XC9572XL display controller||Texas Instruments TSC2046 touchscreen controller|
|Backlight mode selection jumper||Unused pads for 5 buttons|
Full details are in the display datasheet.
Installing the software driver
First, grab the Raspbian custom kernel package :
Then, install it :
sudo dpkg -i kernel4dpi_1.2-1_all.deb
Warnings about runlevels of the script can be ignored.
Now, power off the Raspberry Pi.
Connect the 4DPi-35 to the Raspberry Pi, and reapply power. The terminal should begin to show on the 4DPi-35, and will be ready to use once the Raspberry Pi has booted.
Calibrating the touchscreen
There are 2 sorts of calibrations which can be performed, depending on the requirements of the user.
The first process is for calibrating the touch sensor for everything other than the LXDE GUI itself. This is required for most applications.
The second is for calibrating the touch controller for the LXDE GUI, ie when you run startx.
Calibration for console :
- 1) Install the « event test » and « touchscreen library » packages to calibrate and debug the touch screen, using the following command :
sudo apt-get install evtest tslib libts-bin
- 2) Calibrate the screen manually using the tslib package, using the following command. You should only need to do this once.
sudo TSLIB_FBDEVICE=/dev/fb1 TSLIB_TSDEVICE=/dev/input/event0 ts_calibrate
- 3) Follow the directions displayed on the screen.
It is recommended to use a stylus to achieve the most accurate calibration. Do not use anything metal or sharp which could damage the touch screen.
- 4) To test if your calibration was satisfactory, you can run the following command to draw on the screen to show the accuracy of the touch.
sudo TSLIB_FBDEVICE=/dev/fb1 TSLIB_TSDEVICE=/dev/input/event0 ts_test
Calibration for LXDE GUI :
To calibrate the touch screen for the LDXE GUI, the xinput_calibrator is required.
Make sure LDXE is not running before you start, quit LDXE if it is and return to the terminal prompt.
- 1) Delete the old calibration file, in preparation for the new one. Do this BEFORE running startx and the calibrator.
sudo rm /etc/X11/xorg.conf.d/99-calibration.conf
- 2) This step is to be performed via a SSH session to your Raspberry PI. If you wish to do this directly with a keyboard on the Raspberry Pi instead, skip to the next step.
Enter the following two commands:
FRAMEBUFFER=/dev/fb1 startx & DISPLAY=:0.0 xinput_calibrator
- 3) This step is instead of step 2, if you are using a keyboard connected to your Pi. Start the LXDE GUI using the following command :
- 4) Execute the xinput_calibrator command from the terminal after the LXDE GUI has started.
It is also possible to use the « Calibrate Touchscreen » menu entry.
- 5) Follow the directions on the screen. Once complete you should get an output which contains information such as this:
Section « InputClass »
Identifier « calibration »
MatchProduct « ads7846 »
Option « Calibration » « 119 3736 3850 174 »
# Option « SwapAxes » « 1 »
- 6) If the /etc/X11/xorg.conf.d directory does not exist, it needs to be created manually.
- 7) Run the following command
sudo nano /etc/X11/xorg.conf.d/99-calibration.conf
Copy the information shown in step 5 into this file, save it and exit nano.
- 8) Restart your Raspberry Pi. You should now have a perfectly calibrated 4DPi-35.
Change the Display Orientation
To change the display orientation, simply edit the /boot/cmdline.txt file.
Find the parameter :
4dpi.rotate = 0
And change this to have the value of 0, 90, 180 or 270.
Save the file and restart your Raspberry Pi.
The touch screen with automatically remap the alignment thanks to the custom kernel.
4DPI-35 has some additional settings : backlight mode (PWM controlled or on/off), SPI compression, SPI clock frequency.
You could check the official datasheet, they are well explained.
The display quality is great overall. 480×320 resolution is great for embedded projects, but may be too small to use the Raspberry Pi as a full desktop computer.
Resolution is great for such a small display. Colors are sharp and brightness is very good, even in daylight.
Individual pixels are not visible except when zooming on the display.
Horizontal view angle is great, and almost doesn’t degrade.
Vertical view angle is not so good, and starts to degrade at 45°.
The 4DPI-35 is a great module for Raspberry Pi. Installation is really easy and build quality is great. While 480×320 resolution is low for a full desktop use, it is perfect for embedded projects or old games emulation. Mounting holes and brightness controls are also very handy.
The 4DPI-35 also exists in 3.2″ inch 320×240 format (4DPI-32).
It’s also worth noting 4D-Systems are also selling a wide range of intelligent displays, that can’t be used as a primary display for the Raspberry Pi, but should find a use in specific projects. I hope to review one of those in the future.
The 4DPI-35 is sold by 4D-systems directly (http://www.4dsystems.com.au/) or at Mouser Electronics (http://www.mouser.fr/4d-systems/) for 69$.
3 réflexions au sujet de « [Raspberry Pi] 4d-Systems 4DPI-35 display module »