kedei 3.5 inch tft lcd display spi with touch screen brands

While googling for any info about lcd controller I came across this page: http://heikki.virekunnas.fi/2015/raspberry-pi-tft/, author managed to get from manufacturer patch file for kernel sources and tested it with 4.1.y - on which lcd worked. But still LCD replace HDMI, but I want to use this screen as additional for user interaction, while the bigger on HDMI as presentation monitor.

Since, fbtft has been merged with rpi kernel, so the fb drivers (including ili9341.c) was moved to fbtft_device driver (so the author of page can"t compile latest kernel with driver+patch).

So something about hardware, which I reverse engineered by the "hard way" - "grab multimeter and run through all LCD FPC pins and shift register pins"

Now I noticed there is "9486L" which can suggest that LCD screen is controlled by ILI9486L, I found this LCD on taobao too but I can"t contact seller.

I"m pretty sure about D/C (Pin 37 on LCD) and Reset (Pin 19 on LCD) pins by looking into driver code, but I can"t identify other signals (WR/RD/CS/etc...)

[ 4.838806] input: MOSART Semi. Rapoo 2.4G Wireless Touch Desktop as /devices/platform/bcm2708_usb/usb1/1-1/1-1.3/1-1.3:1.0/0003:24AE:1000.0001/input/input1

[ 4.862704] hid-generic 0003:24AE:1000.0001: input,hidraw0: USB HID v1.10 Keyboard [MOSART Semi. Rapoo 2.4G Wireless Touch Desktop ] on usb-bcm2708_usb-1.3/input0

[ 4.902783] input: MOSART Semi. Rapoo 2.4G Wireless Touch Desktop as /devices/platform/bcm2708_usb/usb1/1-1/1-1.3/1-1.3:1.1/0003:24AE:1000.0002/input/input2

[ 4.926400] hid-generic 0003:24AE:1000.0002: input,hiddev0,hidraw1: USB HID v1.10 Mouse [MOSART Semi. Rapoo 2.4G Wireless Touch Desktop ] on usb-bcm2708_usb-1.3/input1

- Controller is not ILI9341/ILI9325 - those are for smaller displays (320x240, etc...), I guess this might be ILI9486/9488 because they are for 480x320 displays. But when I compared init with DS it does not fit right so LCD can have a clone of ILI9486/9488 ...

- Module use only SPI interface and two CE signals (CE0 for touch controller, CE1 for LCD shift registers - compared to others lcd modules, in KeDei module this is swapped),

kedei 3.5 inch tft lcd display spi with touch screen brands

I successfully installed KeDei 3.5 inch 480x320 TFT LCD on a Raspberry Pi Zero with Raspbian Buster. It works nicely as text console, especially when I use lens to magnify the view. :-)

However, I want to use it for another purpose: I would like to keep the regular screen & console output at HDMI port and use the LCD as a special-purpose peripheral.

Is there any tutorial how to set up this kind of device (TFT LCD with SPI interface) either as a serial port, or some other kind of device that would allow it to be used by a single application for special prupose, such as control panel for some communication equipment?

kedei 3.5 inch tft lcd display spi with touch screen brands

... height with supports. ...This bracket will accommodate the Kedei 3.5" HDMI LCD screen, using kapakahi"s screw posts. The button wells from kapakahi"s original Thing will also fit. ...

Remix Raspberry Pi Display Case http://www.thingiverse.com/thing:1229473 For the KeDei 3.5" SPI TFTLCD 480x320 version 1.1 2015/8/11 Print Settings Printer Brand: RepRap Printer: reprap prusa i3 marlin Rafts: Doesn"t Matter Supports: No Resolution:...

So I ordered the OSOYOO 3.5" TFT display from Amazon (also seen it for sale as a KeDei display which is what is actually printed on the OSOYOO I received from Amazon), and I wanted a simple case for it that would hold & display it nicely with all...

... stl orientation- screen.stl should be printed downwards. -So the supports go on top of the mounting screws. Screen has some freedom of movement on the back of the pi, just dab som hotglue to the edge of the kedei-pcb and have a good time! ...

I love the case made by 0110-M-P and I couldn"t find a good case for cheap 3.5 kedei LCD so I made a top for 0110-M-P base. I"m using this with my octoprint and touch UI.

My touchscreen (KeDei (ebay)) was a bit higher to fit the original case so I made the display-slot slightly taller for the case and cap. ...Works with the following Raspberry Pi Models:

A Gameboy Zero Helper for the Kedei 3,5 " Display Space for micro usb break out, usb and volume wheel the top adds more useable space into your build print solid and drill the holes by your self

Screen used is KeDei 3.5 inch LCD TFT 320x480 touch screen (sample link https://www.aliexpress.com/item/New-Original-3-5-Inch-LCD-TFT-Touch-Screen-Display-for-Raspberry-Pi-2-Raspberry-Pi/32851565266.html). ... You will need: - The screen (KeDei 3.5 inch...

I have the KEDEI 3.5" 128M SPI TFT screen, and had to modify it slightly: "extending the connector with wires", which gives the opportunity to add some more things like better power connection or i2c RTC. I made the case for the screen to cover the...

... On an ugly reprap display I also deliberately omitted, since I use octoprint touch (with a osoyoo / kedei 3.5 "HDMI touch TFT https://amzn.to/2IivrUA). ...

kedei 3.5 inch tft lcd display spi with touch screen brands

I"ve gotten the level converters now, and experimented a little, with no results but a plain white screen. I copied the "init commands" code from the Linux source for ILI9341, which are the closest thing I could see in the patch made by KeDei for any init-code, plugged an arduino Uno in via a level converter from 5v down to 3v3, with SCK/MOSI/MISO from arduino pins 13/12/11, and pin 9 to toggle L_CS, keeping it HIGH but pulling it LOW for 1 to 5 milliseconds after each 4-byte SPI write.

Eventually I tried without the level converter too, since the 74HC595 datasheet said it could handle "up to Vcc" on the input pins, Vcc being max 6V. But that was after trying a lot of combinations in the code; all the variations of SPISettings in Arduino"s SPI library, for transferring four bytes one at a time (someone else who also looked at these displays found out that the registers always want four bytes - and that the first byte is always 0x0 !). Also doing as you suggested with an extra "DC command bit" so that the "bytes" were 9-bits wide, ending in a zero bit to indicate "command". No luck, ah well.. And I can"t even be sure that either the display is an ILI9341 just because the sales page said so (others had gotten similar displays with another drive chip), or that the code in the kernel source matches this KeDei-version of the display.

As an amusing side note: I did get a Mega screen that I mentioned elsewhere, that only output blue colour, but yellow/red when told to "invert screen". It turns out the display is probably okay, but the interface is only 8 bits wide while the chip is set to 16 bits, meaning the last half of the colour data never makes it to the controller! That seems like a likely explanation to me, given the dirt-cheap price.

kedei 3.5 inch tft lcd display spi with touch screen brands

This LCD Touchscreen HAT fits snuggly on top of the Raspberry Pi, practically form fitting on top of it so as not to compromise the overall dimensions of the credit card sized single board computer. The resistive touchscreen provides you with an easy way to display information coming off of the Raspberry Pi and the OS currently running on it.

The 4:3 aspect ratio backlit LCD equipped on this HAT possesses a resolution of 480 by 320 pixels with over 65 thousand colors and an SPI interface with a 16MHz driver speed. Simply plug the 13x2 GPIO header into your desired Raspberry Pi and you"ll be able to start using your new resistive touch screen!

kedei 3.5 inch tft lcd display spi with touch screen brands

I have a KeDei 3.5 ich SPI TFT LCD Display. I attached to Raspberry Pi with Android Things Image. When I boot the RPi, nothing is shown, only displays a black screen. The display is getting powered up, and I can differentiate between it"s on and off state. But when I try remote display (followed steps from this post), I can see the display properly.

mBaseDisplayInfo=DisplayInfo{"Built-in Screen", uniqueId "local:0", app 640 x 480, real 640 x 480, largest app 640 x 480, smallest app 640 x 480,mode 1, defaultMode 1, modes [{id=1, width=640, height=480,fps=60.000004}], colorMode 0, supportedColorModes [0], hdrCapabilities android.view.Display$HdrCapabilities@1d6308, rotation 0, density 240 (0.0 x 0.0) dpi, layerStack 0, appVsyncOff 1000000, presDeadline 16666666, type BUILT_IN, state ON, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS, removeMode 0}

I tried latest Raspbian Image and dev preview 0.4.1 as mentioned here. Tried with HDMI config given in the same link. Nothing works except the rpi_35_v6.3_ubuntu_mate_15_kedei image from KeDei vendor.

kedei 3.5 inch tft lcd display spi with touch screen brands

I have a KeDei 3.5 ich SPI TFT LCD Display. I attached to Raspberry Pi with Android Things Image. When I boot the RPi, nothing is shown, only displays a black screen. The display is getting powered up, and I can differentiate between it"s on and off state. But when I try remote display (followed steps from this post), I can see the display properly.

mBaseDisplayInfo=DisplayInfo{"Built-in Screen", uniqueId "local:0", app 640 x 480, real 640 x 480, largest app 640 x 480, smallest app 640 x 480,mode 1, defaultMode 1, modes [{id=1, width=640, height=480,fps=60.000004}], colorMode 0, supportedColorModes [0], hdrCapabilities android.view.Display$HdrCapabilities@1d6308, rotation 0, density 240 (0.0 x 0.0) dpi, layerStack 0, appVsyncOff 1000000, presDeadline 16666666, type BUILT_IN, state ON, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS, removeMode 0}

I tried latest Raspbian Image and dev preview 0.4.1 as mentioned here. Tried with HDMI config given in the same link. Nothing works except the rpi_35_v6.3_ubuntu_mate_15_kedei image from KeDei vendor.

kedei 3.5 inch tft lcd display spi with touch screen brands

After many days of trying different guides I have finally managed to configure Raspberry Pi 3 B+ with 3.5’’ LCD that I bought from AliExpress. This will be step by step guide. If I did it you will too. I am absolute novice at the Linux world.

When you’re done with this go to Settings, where you select Plugins. On the left side click on the Miscellanea tab and install Touch Display Plugin. This can take up to 10 minutes.

I hope this guide will save you some time. For me it worked. I used Volumio version 2.657 but just today as I write this guide version 2.668 was released. I have no idea if it works with that one.

kedei 3.5 inch tft lcd display spi with touch screen brands

The RPi LCD can be driven in two ways: Method 1. install driver to your Raspbian OS. Method 2. use the Ready-to-use image file of which LCD driver was pre-installed.

3) Connect the TF card to the Raspberry Pi, start the Raspberry Pi. The LCD will display after booting up, and then log in to the Raspberry Pi terminal,(You may need to connect a keyboard and HDMI LCD to Pi for driver installing, or log in remotely with SSH)

1. Executing apt-get upgrade will cause the LCD to fail to work properly. In this case, you need to edit the config.txt file in the SD card and delete this sentence: dtoverlay=ads7846.

This LCD can be calibrated through the xinput-calibrator program. Note: The Raspberry Pi must be connected to the network, or else the program won"t be successfully installed.

kedei 3.5 inch tft lcd display spi with touch screen brands

I orderer a 3.5″ SPI touchscreen with a Raspberry Pi 2 and a case, thinking it would be easy to set up, as it seemed to be like the one here. Unfortunately that was not the case.

With some googling I found out it was made by KeDei LCD and exactly this screen. Identifying strings on the screens were “Madei in KeDei of china”, “3.5 linch SPI TFTLCD”, “480*320 16bit/18bit” and “vision 1.0 2015/6/11”. I hope the guys who made this screen can write code better than english… Seems like it requires custom drivers by KeDei. Drivers could be downloaded from Baidu and they include the diff to compile your custom kernel. I haven’t compiled kernels before, so lets see if I could manage without doing that.

I downloaded drivers and installed them in a fresh installation of Raspbian. They worked, somewhat at least. I could see console in the screen and also LXDE started in it. However it seemed to override HDMI output completely, as it was /dev/fb0 and no other framebuffers were present. Touchscreen appeared in /dev/input/event0, but I couldn’t get it respond. Probably the touch sensor is defective, as the glass on the screen also had a crack. I did get a free resend however, so I’ll see whether it was defective hardware.

The drivers replaced current kernel with a custom 3.18.x version with drivers in it, so you can’t update kernel if using that method. Perhaps I should try to compile more recent kernel with drivers.

I installed Ubuntu on my Macbook Pro on an external hard drive (which is a whole another story, thanks to EFI), so I could follow instructions on Raspberry Pi pages. Compiling on RPi is quite slow (tried that overnight), so cross compiling is the way to go. Following the instructions worked pretty well, however I cloned tools to my home directory and added /home/heikki/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin to my path. After that everything worked as expected. After cloning and changing branch to rpi-4.1.y I patched semi-manually from the supplied diff from KeDei, however I have uploaded my updated diff to make it easier for you. There’s instructions on patching too, but long story short it’s “cat | patch -p1” in the base directory of the clone. The version I used was branch rpi-4.1.y, commit 785cea66a709eddb9858799192a7b7da566b44b0.

Update: I accidentally updated kernel with apt-get, so I tried to compile the kernel to the latest. However I noticed the patch missed a whole file, which belongs to drivers/video/fbdev/ and is attached here: ili9341.c.I still couldn’t get it right, so I just installed the previously compiled kernel.

You should now have two framebuffer devices, /dev/fb0 and /dev/fb1. I’m not quite sure how the fbtft library interferes with the patch, as it seems to be activated too, but it works so no problem. (Actually I first activated module fb_ili9341, so you can try that too, if it contributed to my success). You can change to console to fb1 by command “con2fbmap 1 1” and back with “con2fbmap 1 0“, or on boot by editing /boot/cmdline.txt: add “fbcon=map:1” to the line somewhere. You can also change the font with “fbcon=font:ProFont6x11“. More things like this here.

The framerate on this screen is really slow, something like 0.5 secs to refresh the screen, so no video playback on this screen. For simple GUIs probably quite sufficient. Haven’t tried whether backlight can be controlled, probably not, so always on.

I’ll test the touchscreen with custom kernel later when I get the new unit. The touchscreen driver seems to be added (/dev/input/event2 for me with Logitech keyboard/mouse connected), so it might work.

kedei 3.5 inch tft lcd display spi with touch screen brands

This is a modified version of the official PJRC ILI9341_t3 library (https://github.com/PaulStoffregen/ILI9341_t3) to work with KeDei Raspberry Pi displays.

And it is always a Work In Progress. Also using a lot of work from the the Raspberry Pi implementation: https://github.com/cnkz111/RaspberryPi_KeDei_35_lcd_v62

This library was created to allow extended use on the KeDei Raspberry Pi display and supports T3.5, t3.6 T4 and beyond. It also has support for other T3.x boards as well as TLC.

As we have found in several other places on the Web, this board is very much different than most of the other display boards, and it is still unclear what the underlying display controller actually is.

Your SPI communications on this board does not go directly to display but instead go to three shift registers. There are also two SPI Chip select pins, one labeled, which looks like it is for the Display and the other looks like it is for the touch controller. This is partially true.

That is if the Touch CS is low (asserted) and the other CS is high (not asserted) than the communications are processed by the XPT2046. And our updated example sketch touchpaint uses the standard teensy library https://github.com/PaulStoffregen/XPT2046_Touchscreen to process the presses.

However the SPI communications with the display are a lot different than any other I have seen. For example there are no reset pins, nor a Data/Command(DC) pin. Instead this information is encoded into the SPI data that you send to the display.

That is for each thing you want to send to the display, you typically send a 4 byte transfers. A few of these are to reset the display, some are commands and others are data. Example in a capture I did from starting up

We figured it out, as the RPI startup code, did several strange SPI transfers at the beginning, which appeared like they were directed to the XPT2046 Touch controller.

You will find that these devices (XPT2046) have a pin on them marked AUX, which on these display appear to be connected to a potential Resistor Divider made up of R1 and R2.

So if you send the byte E7 to the display with Touch CS asserted, it starts a AtoD conversion on that AUX pin, and transfer of two more zeros, will return you the AtoD value from AUX,

This library borrows some concepts and functionality from another ILI9341 library, https://github.com/KurtE/ILI9341_t3n. It also incorporates functionality from the TFT_ILI9341_ESP, https://github.com/Bodmer/TFT_ILI9341_ESP, for additional functions:

The teensy 3.6 and now 3.5 have a lot more memory than previous Teensy processors, so on these boards, I borrowed some ideas from the ILI9341_t3DMA library and added code to be able to use a logical Frame Buffer. To enable this I added a couple of API"s

In addition, this library now has some of the API"s and functionality that has been requested in a pull request. In particular it now supports, the ability to set a clipping rectangle as well as setting an origin that is used with the drawing primitives. These new API"s include: