User Guide for 4D SYSTEMS models including: gen4-4DPI-43T CT-CLB, gen4-4DPI-50T CT-CLB, gen4-4DPI-70T CT-CLB, gen4-4DPI Series, Intelligent Display Modules for Raspberry Pi, gen4-4DPI-43T CT-CLB Intelligent Display Modules for Raspberry Pi
Pi Zero W Manual Filetype Pdf - Getting Started with the Raspberry Pi Zero Wireless
GEN4-4DPI-70CT-CLB - 7.0" Primary Display for the Raspberry Pi with Capacitive Touch
File Info : application/pdf, 9 Pages, 1.26MB
DocumentDocumentUSER GUIDE gen4-4DPI SERIES gen4-4DPI-43T/CT-CLB gen4-4DPI-50T/CT-CLB gen4-4DPI-70T/CT-CLB Intelligent Display Modules for Raspberry Pi gen4-4DPI Series SCREEN SIZE inches 4.3* 5.0* 7.0* mm 109.22 127.00 177.80 *Also available in Cover Lens Bezel (CLB) version. RESOLUTION 480 x 272 800 x 480 Non-Touch TOUCH TYPE Resistive Capacitive FOR RASPBERRY PI VARIANTS: Resistive Touch (T) Capacitive Touch with Cover Lens Bezel (CT-CLB) This user guide will help you started using the gen4-4DPI-XXT/CT-CLB modules. It also includes a list of essential project examples and application notes. What's In The Box gen4-4DPi- XXT/CT-CLB gen4-4DPi Adaptor 30-way Flat Flex Cable (FFC) Supporting documents, datasheet, CAD step models and application notes are available at www.4dsystems.com.au Contents Introduction 4 System Requirements 5 1 Hardware 5 Requirements 6 How To Use The GEN4-4DPI-XXT/CT-CLB 7 Download and Installation 7 Calibrating the Resistive Touch 8 Getting Started With A Simple Project 11 Reference Documents 14 GLOSSARY 16 Introduction This User Guide is an introduction to becoming familiar with the gen4-4DPiXXT/CT-CLB and the software IDE associated with it. This manual should be treated only as a useful starting point and not as a comprehensive reference document. In this User Guide, we will briefly focus on the following topics: · Hardware and Software Requirements · How to use the gen4-4DPi-XXT/CT-CLB · Getting Started with Simple Projects · Featured Projects · Reference Documents The gen4-4DPi-XXT and gen4-4DPi-XXCT-CLB are part of the gen4 series of display modules designed and manufactured by 4D Systems for Raspberry Pi boards. These modules feature a 4.3", 5.0" and 7.0" colour LCD display powered through a Raspberry Pi board and come in resistive and capacitive touch variants - gen4-4DPi-XXT and gen4-4DPi-XXCT-CLB, respectively. System Requirements The following sub-sections discuss the hardware and software requirements for this manual. 1 Hardware 1.1 Raspberry Pi Board One of the most important requirements is the Raspberry Pi which will be used as the CPU for the 4DPi display. 1.2 gen4-4DPi-XXT/CT-CLB The gen4-4DPi-XXT/CT-CLB and its accessories are included in the box, delivered to you after your purchase from our website or through one of our distributors. Please refer to the section "What's in the box" for images of the display module and its accessories. 1.3 gen4-4DPi Adaptor The adaptor is placed on top of the Raspberry Pi. You can refer to the image on the description to see the proper orientation. 1.4 30-way Flat Flex Cable (FFC) The Flat Flex cable is attached to the adaptor to connect it to the gen4-4DPi-XXT/CT-CLB. 1.5 5V DC Supply To know the specifications needed for the power supply, please refer to the gen4-4DPi Datasheet. gen4-4DPI SERIES -- USER GUIDE gen4-4DPI SERIES -- USER GUIDE www.4dsystems.com.au www.4dsystems.com.au 4 5 www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE Requirements The gen4-4DPi is designed to work with the Raspbian Operating System running on the Raspberry Pi, as that is the official Raspberry Pi operating system. HARDWARE SOFTWARE gen4-4DPi Display gen4-4DPi Adaptor 30-way Flat Flex Cable (FFC) Latest Raspbian Image Raspberry Pi board Compatible with Raspberry Pi A+, B+, Pi2, Pi3, Pi3 B+, Pi4, Pi Zero and Pi Zero W 5V DC Supply Suitable for the BeagleBone Black (using DC Jack), recommended 2A @5V Stylus Recommended for accurate touch, however is not required 4DPi Kernel Package NOTE: The Raspbian OS image is available at the official Raspberry Pi website. 6 How To Use The GEN4-4DPI-XXT/CT-CLB Download and Installation 1. Download the latest Raspberry Pi https://www.raspberrypi.com/software/ 2. Load the Raspberry Pi image into the SD card 3. After loading the image file, insert the SD card into the Raspberry Pi and apply power. NOTE: Do not cnnect the gen4-4DPI-XXT/CT-CLB yet! 4. Either log into the Raspberry Pi from your keyboard/monitor using the standard `pi' and `raspberry' credentials, else SSH into your Raspberry PI and log in via your SSH session. 5. Update and upgrade your Raspberry Pi to ensure you are running the latest version of the kernel and firmware. sudo apt-get update sudo apt-get upgrade NOTE: An upgrade should only be done after making sure that the latest kernel is supported by the latest kernel pack from 4D. Otherwise, installing the 4D kernel pack will downgrade the kernel. Reboot the Raspberry Pi sudo reboot 6. After the reboot, log into your Raspberry Pi again, you will need to download and install the kernel which supports the gen4-4DPi displays. 7. To download and install the kernel image from the 4D Systems Server, please refer to the gen4-4DPi Datasheet 8. After successfully installing the image file, shutdown the Raspberry Pi safety and remove the power after it has completed its shutdown. 7 www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE sudo poweroff or sudo shutdown now 9. Connect the gen4-4DPi display to the Raspberry Pi as shown in the image below and reapply the power. Calibrating the Resistive Touch Each gen4-4DPi which is shipped from the 4D Systems factory is slightly different, in the sense that each of the touch screens has a slightly different calibration. In order to get the best from your gen4-4DPi, you will need to calibrate the display so it is as accurate as possible. To calibrate the touch screen, the xinput_calibrator is required and the following steps should be carried out. Make sure the Desktop is not running before you start, quit desktop if it is and return to the terminal prompt. Please note that only resistive touch display modules could be calibrated. 1. Install xinput_calibrator (if not installed by default) by running this from terminal: sudo apt-get install xinput-calibrator 2. Install the event device input driver: sudo apt-get install xserver-xorg-input-evdev 3. Rename 10-evdev.conf file to 45-evdev.conf sudo mv /usr/share/X11/xorg.conf.d/10-evdev.conf /usr/share /X11/xorg.conf.d/45-evdev.conf 8 4. Check if evdev.conf has a higher number than libinput.conf ls /usr/share/X11/xorg.conf.d/ The user should get something like this 10-quirks.conf 40-libinput.conf 45-evdev.conf 99 fbturbo.conf 5. Perform a reboot sudo reboot now 6. Reconnect to SSH and run xinput calibrator. DISPLAY=:0.0 xinput_calibrator Perform the calibration and copy results. The results should be something similar to this Section "InputClass" Identifier "calibration" MatchProduct "AR1020 Touchscreen" Option "Calibration" "98 4001 175 3840" Option "SwapAxes" "0" EndSection 7. You may test the changes after xinput calibrator ends. To make the changes permanent, paste the results to calibration.conf file. sudo nano /etc/X11/xorg.conf.d/99-calibration.conf 8. Save the file and perform a reboot sudo reboot now 9 www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE Change the Display Orientation The Screen Orientation of the display can be changed. To implement this, there are two things that need to be changed: 1. To change the display orientation, simply edit the cmdline.txt file sudo nano /boot/cmdline.txt 2. Add the parameter below at the second position in the parameter list: 4dpi.rotate = 90 And change this to have the value of 0, 90, 180 or 170. It should look something like: dwc_otg.lpm_enable=0 4dpi.rotate=90 console=serial0,115200 Save the file and restart your Raspberry Pi. The touch screen will automatically remap the alignment thanks to the custom kernel. Backlight Control The backlight brightness can be controlled from the terminal, or from a bash script. The following command can be used to set the backlight from 0 to 100% sudo sh -c `echo 31 > /sys/class/backlight/4dhats/brightness' The above will set the backlight to 100%. Simply change the `echo 31' to be anything from 0 to 31. Getting Started With A Simple Project After connecting the display and flash the image, you can now start doing projects. This project simply shows a message box on the gen4-4DPi that says "HELLO WORLD". PART 1: Scripting Step 1: Update the Python version This project uses Python 3.5.3. To know the version of your python3, you can use $ python3 version You can update your python3 version by using the command $ sudo apt-get update $ sudo apt-get install python3 Step 2: Install PyQt PyQt is one of the most popular Python bindings. This project uses the PyQt binding for displaying the output. To install PyQt, run the following command: $ sudo apt-get install python3-pyqt4 Step 3: Connect to SSH You can operate your BeagleBone device from a remote terminal using many means. This example shows how to do it using SSH. 1. Login using your SSH. This appnote uses MobaXterm tool to connect through SSH. gen4-4DPI SERIES -- USER GUIDE gen4-4DPI SERIES -- USER GUIDE www.4dsystems.com.au www.4dsystems.com.au 10 11 www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE 2. Go to Desktop and create a new file "HelloWorld.py". 3. Open using Sublime Text or any other editor you have installed in you computer. 4. Paste the script below and Save: import sys from PyQt4 import QtGui def window(): app = QtGui.QApplication(sys.argv) widget = QtGui.QWidget() label = QtGui.QLabel(widget) label.setText("Hello World!") widget.setWindowTitle("PyQt") widget.show() sys.exit(app.exec_()) if name == ` main `: window() 12 PART 2: Running the Project Option 1: Run the Python Script Using the Raspberry Pi Terminal To run the python script using the gen4-4DPi Display, navigate to where the python script is saved then run the command: $ python3 HelloWorld.py Option 2: Run the Python Script Using SSH Navigate to the script's directory (in this case, Desktop). This is optional but you can test your script in your remote terminal by running, $ python3 HelloWorld.py To run the script from a remote terminal and display it on the gen4-4DPi, $ DISPLAY=:0.0 python3 HelloWorld.py The gen4-4DPi should now look like this: 13 www.4dsystems.com.au gen4-4DPI SERIES -- USER GUIDE Reference Documents The "HelloWorld" project is one of the most common and basic projects to be made in almost every language and that includes Python. The following is a list of the sites and documents that may help the user to further enhance GUI programming and to know more about the gen4-4DPi: gen4-4DPi Datasheet This document contains the essential information related to the gen4-4DPi. Raspberry Pi Website A good place to start for information and support regarding the Raspberry Pi and various distributions available. Raspberry Pi Latest Images This website details the latest firmware images for the Raspberry Pi. NOTES gen4-4DPI SERIES -- USER GUIDE gen4-4DPI SERIES -- USER GUIDE www.4dsystems.com.au www.4dsystems.com.au NOTE: For support regarding the gen4-4DPi hardware please go to www.4dsystems.com.au and either contact Support directly via a Ticket, or use the 4D Systems Forum. 14 15 GLOSSARY 1. Backlight A form of illumination used in LCD display modules. 2. Calibrate Touch A process performed to improve the accuracy of the translated touch location provided by the touch screen controller. 3. Firmware A permanent software programmed into a read-only memory. 4. Image File A serialized copy of the entire state of a computer system stored in some non-volatile form. 5. Kernel Manages the operations of the computer and the hardware. 6. PyQt PyQt is one of the most popular Python bindings for the Qt cross-platform C++ framework. 7. Python A high-level programming language designed to be easy to read and simple to implement. 8. Raspbian The official operating system used by Raspberry Pi. 9. Reboot An instance of shutting down and restarting a device. 10. Resistive Touch Display A touch-sensitive display composed of two flexible sheets coated with a resistive material and separated by an air gap or microdots. 11. SSH Secure Shell or Secure Socket Shell, is a network protocol that gives users, particularly system administrators, a secure way to access a computer over an unsecured network. gen4-4DPI SERIES -- USER GUIDE www.4dsystems.com.au Visit our website at: www.4dsystems.com.au Technical Support: www.4dsystems.com.au/support Sales Support: sales@4dsystems.com.au Copyright © 4D Systems, 2022, All Rights Reserved. All trademarks belong to their respective owners and are recognised and acknowledged. 16