5inch HDMI LCD (B) (Firmware Rev 2.1) User Manual

From Waveshare Wiki
Revision as of 07:17, 20 June 2016 by Wiki Editorial Team (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

5inch HDMI LCD (B) User Manual - Based on Firmware Rev 2.1.

Working with PC

This product supports Windows 10/8.1/8/7 operating systems.

Hardware connection

Please make sure the connections are done in a right sequence, or else the LCD may not work well.

  1. Connect the TOUCH & POWER interface of the LCD to one of the USB interfaces on your PC with a Type A to micro USB cable.
  2. Connect the HDMI interface of the LCD to the HDMI interface on your PC with a HDMI cable
When multiple displays are detected by your PC, the LCD can only be used to control the cursor on main display. So it is proposed to set the LCD as the main display.

Generally, you will see the screen displays the interface as the figure shows below. (Please reboot your PC if LCD displays nothing.)

5inch-HDMI-LCD-B-Rev2.1-00.jpg

Calibration in Windows

Open Control Panel -> Tablet PC Settings (may differ depending on Windows revision)

Win8 Tablet PC Setting.png

Working with Raspberry Pi

For the Windows OS on PC, the resolution of the LCD is automatically identified. Hence, you do not need to make the relative settings. When working with Raspberry Pi, you should set the resolution of the LCD by yourself, or else the LCD screen will not work. For more detail information, please read the following section.

At the beginning, you should download the latest image file, RASPBIAN or UBUNTU MATE, from the website: http://www.raspberrypi.org/downloads/.

  1. Download the packaged image file into your PC, and extract it, then you will get a file with the expansion name .img
  2. Connect a TF card to your PC, and format your TF card with the software SD Formatter. Notices: The capability of TF card in used here should be more than 4GB. In this operation, a TF card reader is also required, which has to be purchased separately.
  3. Start the software Win32DiskImager, and select image file downloaded in the first step, then, click the button Write to program the system image file.
  4. When the programming finished, open the config.txt file under the root directory in the TF card, and add the following lines at the end of the file. Then, save the modification and pop-out the TF card.
max_usb_current=1
hdmi_group=2
hdmi_mode=87
hdmi_cvt 800 480 60 6 0 0 0
hdmi_drive=1

Hardware connection

  1. Connect the HDMI interface of the LCD to the HDMI interface on your Raspberry Pi with a HDMI cable
  2. Connect the Touch interface of the LCD to one of the USB interfaces on your Pi with a Type A to micro USB cable.
  3. Insert a TF card into the TF card socket on the Raspberry Pi, and then power up the Pi. Waiting for a while, you may see the following interface.

5inch-HDMI-LCD-B-Rev2.1-01.jpg

Mark 1: the same line
Mark 2: connected to 5V 2.5A power supply

Calibration in Raspbian

This LCD can be calibrated using a program called xinput_calibrator and you should get and install the program manually with

sudo apt-get install -y xinput-calibrator

Enter the following commands for touch screen calibration:

sudo DISPLAY=:0.0 xinput_calibrator

or select Menu -> Preferences -> Calibrate Touchscreen.

After running these commands, there will be a prompt for four-point calibration shown in the LCD screen. Click the points one by one to finish the touch calibration. Then, the new calibration data will be displayed in the terminal, as shows below. Please get these data for future use.

Doing dynamic recalibration:
Setting new calibration data: 3919, 208, 236, 3913

Enter the following command to edit 99-calibration.conf:

sudo nano /etc/X11/xorg.conf.d/99-calibration.conf

Then, the old calibration data will be displayed in the terminal:

Section "InputClass"
Identifier	"calibration"
MatchProduct	"ADS7846 Touchscreen"
Option	"Calibration"	"160 3723 3896 181"
Option	"SwapAxes"	"1"
EndSection

Modify the calibration data to the new calibration data displayed in the step 2):

Section "InputClass"
Identifier	"calibration"
MatchProduct	"ADS7846 Touchscreen"
Option	"Calibration"	"3919 208 236 3913"
Option	"SwapAxes"	"1"
EndSection

Press the keys Ctrl+X, and select the option Y to save the modification.

The modification will be valid after rebooting the system. Enter the following command for system reboot:

sudo reboot
  • Note: The calibration steps above doesn't work in the image 2017-03-02-raspbian-jessie, in such cases, you have to run the following commands and retry the calibration steps above.
sudo apt-get install xserver-xorg-input-evdev
sudo cp -rf /usr/share/X11/xorg.conf.d/10-evdev.conf /usr/share/X11/xorg.conf.d/45-evdev.conf
sudo reboot

Display Orientation

The touch panel won't be adjusted if you change the display orientation by simply appending display_rotate line to the config.txt file.

These kernels allow you to set the touch-panel orientation for a certain display (Not all of the Waveshare LCDs can be set). You can check if your LCD supports the feature.

Plug the screen to your Raspberry Pi, power up and execute:

dmesg | grep WaveShare

If a WaveShare device is successfully grepped like:

WS170120-HDMI-LCD-FAQ01.png

Then you can replace the kernels (please backup first) to adjust the touch-panel orientation:

Working with BeagleBone Black

If the LCD is used as a normal display only, you just need to program the latest Angstrom image to the BeagleBone Black without making any settings. Then, BeagleBone will read the display parameters of the 5inch HDMI LCD, and set the resolution to 800*480 automatically. When the LCD works as a touch display, you need to program the Angstrom image (view the contents of the CD). Here are the steps for programming the image file:

  1. Download the packaged image file into your PC, and extract it, then you will get a file with the expansion name .img
  2. Connect a TF card to your PC, and format your TF card with the software SD Formatter. Notices: The capability of TF card in used here should be more than 4GB. In this operation, a TF card reader is also required, which has to be purchased separately.
  3. Start the software Win32DiskImager, and select image file downloaded in the first step, then, click the button Write to program the system image file.
  4. When the image file has been written into the TF card, you can insert the card to the BeagleBone Black. Powering up the BeagleBone Black, it will enter the OS installed in the TF card. After a while, you will see the graphic interface.

Notes: If the eMMC of the BeagleBone Black has been installed an OS, you should boot up the BeagleBone Black from Micro SD card. Press the Boot Button, and power up the BeagleBone Black. Don’t releases the Boot Button until the USER LEDS start blinking.

Hardware connection

  1. Connect the LCD to the HDMI interface of the BeagleBone with a HDMI to micro HDMI cable (purchased separately).
  2. Connect the Touch interface of the LCD to the host USB interface on BeagleBone with a type A to micro USB cable. (BeagleBone provides a host USB interface and a slave USB interface. This LCD should be connected to the host USB interface.)
  3. Connect the Power Only interface of the LCD to a 5V 2.5A power adapter with a Type A to micro USB cable

Working with Banana Pi

Since the Banana Pi can read out the resolution parameters of the LCD on its start-up, you should connect the Banana Pi to the LCD before powering up the Pi. When the Pi has been entered desktop, the LCD can be removed and then connected again as required.

Working under the Raspbian OS on the Banana Pi

Program the Raspbian image for Banana (view the contents of the CD). This image file supports BananaPi Pro and BananaPi.

  1. Download the packaged image file into your PC, and extract it, then you will get a file with the expansion name .img
  2. Connect a TF card to your PC, and format your TF card with the software SD Formatter. Notices: The capability of TF card in used here should be more than 4GB. In this operation, a TF card reader is also required, which has to be purchased separately.
  3. Start the software Win32DiskImager, and select image file downloaded in the first step, then, click the button Write to program the system image file.

Hardware connection

  1. Connect the LCD to the HDMI interface with a HDMI cable
  2. Connect the Touch interface of the LCD to one of the USB interface on the Banana Pi with a type A to micro USB cable
  3. Connect the Power Only interface of the LCD to the 5V 2.5A power adapter with a type A to micro USB cable

Loading the WiFi driver for BananaPi Pro

Comparing with Banana Pi, BananaPi Pro has an additional on-board WiFi model. When you use BananaPi Pro, you can use SSH method to connect it. Here is the command for loading the WiFi driver:

sudo modprobe ap6210