Interface TFT display with STM32 in parallel mode || CubeIDE || CubeMX || HAL

  Рет қаралды 80,792

ControllersTech

ControllersTech

Күн бұрын

Purchase the Products shown in this video from :: controllerstech.store
________________________________________________________________________________________
How to interface TFT display in parallel mode with STM32 using STM32CubeIDE.
I am using HX8347 240x320 TFT display.
To download the files and code, goto controllerstech.com/interface...
To find the ID of your display goto github.com/prenticedavid/MCUF...
NOTE:- This is a PORT from mcufriend's tft display can be found at github.com/prenticedavid/MCUF...
Check out more VIDEOS on MODULES/SENSORS with STM32 • STM32 and SENSORS/MODULES
________________________________________________________________________________________
****** SUPPORT US BY DONATING*****
paypal.me/controllertech
******Join the Membership******
/ @controllerstech
Join the Discord Server / discord
Join the Telegram Group t.me/controllerstechdiscuss
Follow me on Instagram / controllerstech
For more info, visit www.controllerstech.com

Пікірлер: 145
@MrSkunku
@MrSkunku 4 жыл бұрын
This is great!! I was looking for such a library from such a long time!! Thanx a lot
@bobdole27
@bobdole27 3 жыл бұрын
Thanks, im trying to do same thing but without HAL ( i just don't like using it). Its a very good tutorial
@Th3_Gael
@Th3_Gael 4 жыл бұрын
You are a legend. Thankyou very much
@gustavoserafim7714
@gustavoserafim7714 4 жыл бұрын
Thx man, did it in an ILI9486 using a nucleo f401re and worked well.
@Shubhamjain94
@Shubhamjain94 4 жыл бұрын
What value did you select for "define SUPPORT"?
@MoveenRanush
@MoveenRanush 3 жыл бұрын
@@Shubhamjain94 use 0x9486 as the device ID, still it will work with some errors in word wrapping.
@alarmkoguvenlik
@alarmkoguvenlik 4 жыл бұрын
Thank you.
@wegi9621
@wegi9621 2 жыл бұрын
I think the translation of the databyte could be a done by 256 bytes lookup table which could be final translation everyone possible byte to output data. This same for data input.
@RobertJr-ps1ln
@RobertJr-ps1ln 8 ай бұрын
On displays with resolution more then 256pixels , declaration of cursor_x or (and) cursor_y must be changed to uint16_t instead uint8_t , otherwise when printing on cursor position above 255 text will be unexpected wrapped.
@rubikon7648
@rubikon7648 3 жыл бұрын
Thanks a lot
@jeffryquino9582
@jeffryquino9582 3 жыл бұрын
Nice job. I have a screen similar to that, I would like to know if that same lcd can be used with the spi interface, since the parallel one looks a bit slow
@ControllersTech
@ControllersTech 3 жыл бұрын
Not this one. But there are displays similar to this which can be used..
@chloemcholoe3280
@chloemcholoe3280 4 жыл бұрын
That's a pretty theme. what OS are you running?
@ControllersTech
@ControllersTech 4 жыл бұрын
I guess i was using deepin that time..
@napbelsilva4868
@napbelsilva4868 3 жыл бұрын
Muy buen video, puedes realizar un video para el manejo de pantalla ili9341. Gracias
@ashishkushwaha3812
@ashishkushwaha3812 2 жыл бұрын
Another great work Thanks for that. Is it possible to use the screen with 90 degree rotation? Kind of landscape mode.
@ControllersTech
@ControllersTech 2 жыл бұрын
Yes it does. There is a function "set rotation"
@Huguinskiable
@Huguinskiable 3 жыл бұрын
Hi! Thanks for the code :D. Are you planning to extend the library to use the Touch capabilities of some displays? Also, do you have an example for a bitmap code? I tried uploading some bitmaps from a previous project, but they don't seem to be working :/
@ControllersTech
@ControllersTech 3 жыл бұрын
Nope.. not planning anything on the tft. It's too much work for nothing.
@Huguinskiable
@Huguinskiable 3 жыл бұрын
@@ControllersTech and which display technology would you recommend to use in projects then? :o
@ControllersTech
@ControllersTech 3 жыл бұрын
Use some hmi display. I personally use nextion display. Costs a bit high but worth it
@rajeshkumbhakar271
@rajeshkumbhakar271 3 жыл бұрын
@@ControllersTech which one exactly?
@twizz223
@twizz223 Ай бұрын
What is your supply connection? 3v3 or 5volts? I use the same display but have only white screen after sending some DrawPixel cmd.. then connected it to the scope and noticed that commands ( D/C marked as Rs ) has wrong volltage level instead of being low when sending command has some strange voltage 1.5v but when i disconnected that pin from the display the state is correct. The ground is common so in my point the roblem lays on the voltage levels. I connected 5v and 3.3 to correponding pins on display but i have doubts if that 3.3v is reference for logic interface. Now i will test it with 3v3 voltage provided to 5v pin but need to wait for that ( iam away from home now ) anyway your video proved that this Arduino shild can be connected to stm cmos voltages..
@maulanawahyudi7127
@maulanawahyudi7127 3 жыл бұрын
Thanks a lot sir, but why my text running so slowly ? i use printnewtstr and fillRect functions, like blinking . And Why we need timer 1 ?
@antihyped726
@antihyped726 3 жыл бұрын
I think write_8 and read_8 macro waste too many clock and defeat the purpose of parallel interface itself to achieve faster data throughput.
@MrSasha3050
@MrSasha3050 4 жыл бұрын
Make your intro smooth 😌
@mohidkhantariq9933
@mohidkhantariq9933 Жыл бұрын
When I use expressions to find ID value, it says Target not available. Any fixes?
@sachinacharya1032
@sachinacharya1032 Жыл бұрын
Hai i am using 3.2 tft display ili9325 and xpt 2046 will this driver work for that?
@nguendong4472
@nguendong4472 4 жыл бұрын
How to use FSMC and DMA for lcd?
@brianalvarado3580
@brianalvarado3580 4 жыл бұрын
I'm using the STM32 NUCLEO-L476RG. The readID() function isn't reading the ID of my display. Its is a Newhaven TFT (128x160) with a ILI9163 driver. Any clues as to why I'm not able to read the ID?
@ControllersTech
@ControllersTech 4 жыл бұрын
If you have an arduino, i suggest use that to try mcufriend library in that. If it doesn't work with that, it won't work here also..
@warchiefgaming4690
@warchiefgaming4690 2 жыл бұрын
Does it works with xpt2046?
@henriquerosan574
@henriquerosan574 3 жыл бұрын
I'm getting a error during my debug, the debugger shows me that the width is wrong
@nawfalmotii7918
@nawfalmotii7918 4 жыл бұрын
I'm trying to adapt the code for the SSD1963, but with no success so far....it says on the "user_setting.h" that the SSD1963 only works with 16bits bus....any helps?
@ControllersTech
@ControllersTech 4 жыл бұрын
i don't have the display so can't confirm about this.
@ozcansorgun8597
@ozcansorgun8597 4 жыл бұрын
Can you make an application on touch by drawing a rectangle like button?
@ControllersTech
@ControllersTech 4 жыл бұрын
Maybe soon...
@creativemario3039
@creativemario3039 2 жыл бұрын
How do you make your voice
@chungtran5000
@chungtran5000 2 жыл бұрын
i am using cube MX with keilc v5 and i have 30 error. they are expected a ";" how can i fix it? thank you
@ControllersTech
@ControllersTech 2 жыл бұрын
Use cubeide
@joshuachettiar86
@joshuachettiar86 2 жыл бұрын
Is it possible to save the display screen on an SD card as an image? If yes then how can we do it
@ControllersTech
@ControllersTech 2 жыл бұрын
You mean like a screenshot. Well i don't know for sure but you can weite the data simultaneously on screen and sd card. Otherwise if you have a controller with enough memory to store the entire frame buffer, you can just copy that frame buffer to a file in sd card.
@uchodzcazarobkowy850
@uchodzcazarobkowy850 3 жыл бұрын
It does not work for me.
@peterp1607
@peterp1607 Жыл бұрын
Hello, This tutorial working for ILI9341 for Nucleo H743ZI,but only for printing figures. Unfortunatley it not working for printing text, could you help, maby you have link to newest tft.c file with setting for ILI9341 ?
@XxGittechxX
@XxGittechxX 8 ай бұрын
Hi, I had the same problem with H745ZI-Q, and I figured out, that it's problem caused by "pgm_read_xxxx()" macros. I changed for example: "uint8_t *bitmap = (uint8_t *)pgm_read_pointer(&gfxFont->bitmap);" to "uint8_t *bitmap = (uint8_t *)gfxFont->bitmap;". i did it only in functions "write" and "drawChar" in tft.c. Now it works well for me.
@231ara
@231ara 2 жыл бұрын
I am using Nucleo-F446RE board so it already have the Arduino comparable connector and also I am using IL9341 LCD driver. I edited the code using Cube ide. Done the pin clearing and data writing as per your suggestion.Code compile without any error but it is only showing white screen.Could you please help me on this.
@ControllersTech
@ControllersTech 2 жыл бұрын
Join the telegram channel. I have pinned a post there. It have the tft code with lvgl for 446re
@231ara
@231ara 2 жыл бұрын
@@ControllersTech It is working.Thank you very much
@asmaeaazouzou7671
@asmaeaazouzou7671 2 жыл бұрын
@@231ara I have the same problem.. i am using tft ILI9341 with nucleo F767ZI. i have no error but only white screen. do u have any suggestions please ?
@miladkohansal7288
@miladkohansal7288 3 жыл бұрын
Hi Thank you for your useful training The program works properly, only the texts are mirrored !!! Help if possible stm32f103c8t Ili9325
@usrrsr
@usrrsr 3 жыл бұрын
Add touchgfx to this board
@byatse3013
@byatse3013 2 жыл бұрын
hello do you have tutorial TFT ILI9325 parallel mode for in Keil stm32F103C8
@Intellechawwal
@Intellechawwal 2 жыл бұрын
There's a problem. CubeIDE counts the definition of delay() function in user_settings as a redefinition. Idk why.
@ControllersTech
@ControllersTech 2 жыл бұрын
Plz read other comments
@morosz1159
@morosz1159 2 ай бұрын
where you able to figure this out? I know its been two years lol
@Intellechawwal
@Intellechawwal 2 ай бұрын
@@morosz1159 Yes. I don't remember how I figured it out though. Moved to Nextion and DWIN screens anyway coz they're so much easier to use and have powerful onboard processors.
@ControllersTech
@ControllersTech 2 ай бұрын
Just define that function in some *.c file (like main.c or tft.c) and use the keyword "extern" here in the usersetting.h file (extern void delay (bla bla)).
@p.kaikieu4796
@p.kaikieu4796 3 ай бұрын
sorry but, the library is the same if i use "driver ILI9225" for LCD?
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
does it work for you please ?
@p.kaikieu4796
@p.kaikieu4796 Ай бұрын
@@mohamedmenacer2468 sorry, but i use st7735 instead :( ...
@p.kaikieu4796
@p.kaikieu4796 Ай бұрын
some other youtuber make video with st7735 ic drive , so i used that
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
Okey, Thank you for replying 🙏🏻
@kishanmahajan426
@kishanmahajan426 4 жыл бұрын
I am getting make file error. It is showing multiple declarations for "void delay()" in user_setting.h
@lucasvolkmer2091
@lucasvolkmer2091 4 жыл бұрын
mee too, i have copied and pasted the .h and .c files multiple times but it did not work
@benedekapor9247
@benedekapor9247 3 жыл бұрын
__ tft.c contains the header -> #include "user_setting.h" //multiple declaration
@ControllersTech
@ControllersTech 3 жыл бұрын
Use cubeide
@nicolasmiller4659
@nicolasmiller4659 3 жыл бұрын
Same happens to me and i am using the cubeide, maybe it's missing something in the code?
@benedekapor9247
@benedekapor9247 3 жыл бұрын
@@nicolasmiller4659 @Nicolas Miller In main.c delete #include "user_settings.h" header //multiple declaration _cubemx - truestudio
@princemathew9321
@princemathew9321 4 жыл бұрын
I had tried this code on stm32f103rb nucleo board with necessary changes.but the code doesnt worked on it.can you please suggest me the required changes and considerations to run this code on my board. Also,i have a doubt in the case of read pin configuration,whether it need to configure as input or output pin
@ControllersTech
@ControllersTech 4 жыл бұрын
You can first try to use the f103c8 code directly without changing anything. Use the same pins as i have used in the code. Connect the tft on the breadboard. Once it works out, than you can try to go for the pins according to your board..
@princemathew9321
@princemathew9321 4 жыл бұрын
@@ControllersTech i have tried it.but it didnt work can u please give me the clarification regarding the read pin,whether it need to configure as input or output pin..since in some other codes, it had configured as output pin.
@ControllersTech
@ControllersTech 4 жыл бұрын
What read pin ? If you are talking about the data pins, than they will be configured as output or input based on the situation. The code will automatically do that. You can set it to whatever you want in the cubemx
@Intellechawwal
@Intellechawwal 2 жыл бұрын
Were you able to make it work? I'm stuck on the same board.
@CarlosFCosta-qw8uf
@CarlosFCosta-qw8uf 3 жыл бұрын
Hello sir. I am using ILI9341 (8 bits LCD shield) with STM32F103C8T6 and ILI9341 (16 bits LCD shield) using STM32F407ZGT6 board. In both boards I managed to install your driver using STM32CubeIDE and STM32CubeMX. Now what I want to do is to install the touch screen interface. Where I can find the drivers (XPT 2046) using HAL library for these boards (BluePills and BLACK-F407ZG)? I appreciated very much your work with this interface. Many Thanks.
@ControllersTech
@ControllersTech 3 жыл бұрын
I ported that code from the mcufriend's. I think you should look into that. I can't help much about this as i have dropped my plan for these LCDs. I will be using nextion HMI display now onwards for any application that requires it.
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
please im using ILI9225 and it doesn't work .. ILI9225 doesn't have a lot of pins just CS DC and RESET .. help
@shrinidhimokhashi9802
@shrinidhimokhashi9802 4 жыл бұрын
Hello sir, I am using ILI9225 with STM32F446RE will the same code work ?? If not what changes has to be made
@ControllersTech
@ControllersTech 4 жыл бұрын
Look in the #define support part. If it's there then it should work
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
@@ControllersTech yess it's there but what about all others pins ? for my ILI9225 i have only CS DC RST SDI and CLK
@ControllersTech
@ControllersTech Ай бұрын
This library is for parallel displays. Yours is SPI based.
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
Yes you’re right .. i tried all your videos to configure my ILI9225 with LVGL and doesn’t work for me :( i tried a lot and my last advancement is that i make it work but drawing things using lcgl with Draw pixel function.. which mean my display is really really slow and i can’t make it work using draw bitmap :( i also send you an email and messages in discord .. please help if you can
@mohamedmenacer2468
@mohamedmenacer2468 Ай бұрын
@@ControllersTech ..
@chungtran5000
@chungtran5000 2 жыл бұрын
now i am using TFT 3.5 inches arduino Shield, So can i use your library for its, thank you.
@ControllersTech
@ControllersTech 2 жыл бұрын
Depends on the driver of the display.. See the supported drivers in the code
@chungtran5000
@chungtran5000 2 жыл бұрын
@@ControllersTech thank you
@chungtran5000
@chungtran5000 2 жыл бұрын
@@ControllersTech I used arduino to scan its ID, it is 0x9486.
@skvalavideo
@skvalavideo 2 жыл бұрын
@@ControllersTech I also used Same Arduino Uno shield 3.5 tft display driver ic 9486 but it's read wrong I'd 38022 . What can I do plz help me.
@MrSkunku
@MrSkunku 4 жыл бұрын
Can you please make a video to interface ov7670 camera module with stm32f103c8t6 ?
@ControllersTech
@ControllersTech 4 жыл бұрын
Buddy, I don't have the module at the moment. When I do, I'll definitely do it.
@MrSkunku
@MrSkunku 4 жыл бұрын
Cool no problem,I will wait for it
@MrSkunku
@MrSkunku 4 жыл бұрын
my TFT controller is ILI9341, what changes should i make to your code?
@ControllersTech
@ControllersTech 4 жыл бұрын
You have to make a lot of changes. Watch the video carefully. Everything is explained
@ignacioarias1671
@ignacioarias1671 4 жыл бұрын
@@MrSkunku Hi! Did you make it work?
@FunSpark-Horizon
@FunSpark-Horizon 3 жыл бұрын
I tried to build the project with keil but i am having a lot of errors. Does anyone know why?
@maulanawahyudi7127
@maulanawahyudi7127 3 жыл бұрын
same
@FunSpark-Horizon
@FunSpark-Horizon 3 жыл бұрын
@@maulanawahyudi7127 it seems that the project only works with cubeIDE
@maulanawahyudi7127
@maulanawahyudi7127 3 жыл бұрын
@@FunSpark-Horizon Have you tried it sir?
@FunSpark-Horizon
@FunSpark-Horizon 3 жыл бұрын
@@maulanawahyudi7127 Yes I did. It works with cubeIDE
@maulanawahyudi7127
@maulanawahyudi7127 3 жыл бұрын
@@FunSpark-Horizon that's work sir, but how i can clear the text ?
@debugginglife5698
@debugginglife5698 3 жыл бұрын
There are error in tft.c file. I'm trying to learn how to write code for stm32f4 -> LCD can you please send me a link from where should i start.
@ControllersTech
@ControllersTech 3 жыл бұрын
Use cubeide..
@debugginglife5698
@debugginglife5698 3 жыл бұрын
@@ControllersTech I'm using cube id. but there are error in tft.c file
@ControllersTech
@ControllersTech 3 жыл бұрын
What errors ?
@debugginglife5698
@debugginglife5698 3 жыл бұрын
@@ControllersTech "Expected declaration or statement at the end of the input" at multiple functions
@SuperBiggestking
@SuperBiggestking 3 жыл бұрын
Will this work for the stm32h747?
@ControllersTech
@ControllersTech 3 жыл бұрын
Don't you already have a display attached on the board ?
@SuperBiggestking
@SuperBiggestking 3 жыл бұрын
@@ControllersTech I do. I was more interested in how to use my boards. I have the fdis4cam. Can you do a tutorial on dcmi to ltcd ?
@ControllersTech
@ControllersTech 3 жыл бұрын
Your display is different. This won't work.. Use the LTDC to interface the display. I can't do dcmi, since my board don't have the connection..
@joshuachettiar86
@joshuachettiar86 3 жыл бұрын
it says multiple defination of delay
@tomdehaan3349
@tomdehaan3349 2 жыл бұрын
have you found the solution for this?
@joshuachettiar86
@joshuachettiar86 2 жыл бұрын
@@tomdehaan3349 go to the site in the discription and you will find a comment regarding this
@MahmoodElnasser
@MahmoodElnasser 2 жыл бұрын
.h files are for user definitions and function prototypes etc... Move this code from user_setting.h and place it over or under main function. void delay (uint32_t time) { __HAL_TIM_SET_COUNTER(&htim1, 0); while ((__HAL_TIM_GET_COUNTER(&htim1))
@electrocsj3461
@electrocsj3461 3 жыл бұрын
Why is very slow?
@RachmadSsiAdi
@RachmadSsiAdi 3 жыл бұрын
It is posible to change the tft pin? I'd try to change PA5 to PB7 pin because i need 3 more ADC pin. After change device pinout and write in user_setting.h, that give me error hard fault interrupt. May everybody in here ever tried to change tft pin? Please leave comment, thanks lot
@ControllersTech
@ControllersTech 3 жыл бұрын
The process to change the pins is explained in the video. It's very complex, so watch carefully.
@RachmadSsiAdi
@RachmadSsiAdi 2 жыл бұрын
I miss that important step. So the solution if we want to change that pin. First to do is change microcontroller pin in stm32 pin planner. Second change clear pin configuration 7:17. Last is change data pin read configuration 11:42.
@joshuachettiar86
@joshuachettiar86 2 жыл бұрын
how can we add touch to this?
@ControllersTech
@ControllersTech 2 жыл бұрын
You can.. i didn't tried..
@joshuachettiar86
@joshuachettiar86 2 жыл бұрын
@@ControllersTech do i need to read the port or i need to read control pins, any idea?
@ControllersTech
@ControllersTech 2 жыл бұрын
Depends on how it's connected. I guess reading pins is more convenient
@johnkt1628
@johnkt1628 Жыл бұрын
WHY IS YOUR BACKGROUND BLACK?
@gauravkhanekar3924
@gauravkhanekar3924 Жыл бұрын
buddy it is them.
@heinzwanger7449
@heinzwanger7449 Жыл бұрын
Nothin annoying. The background music ist very low and the voice is very comprensible. I cannot recognize any robot voice.
@onurolce
@onurolce 4 жыл бұрын
Very confusing read and write macros !
@ControllersTech
@ControllersTech 4 жыл бұрын
Yes they are
@onurolce
@onurolce 4 жыл бұрын
@@ControllersTech Could you make it easier ? For example is it possible to put lables on Pins on Cube Graphical setup ?
@ControllersTech
@ControllersTech 4 жыл бұрын
I port this code from mcufriend library. Made some changes to make it as simple as i can. But i couldn't find a workaround for read or write. Just watch the video carefully at that point, it's not that difficult to get. You can make it simple by connecting pins according to their respective positions for eg LCD_D0 to PA_0 and LCD_D7 to PA_7
@onurolce
@onurolce 4 жыл бұрын
@@ControllersTech Ok thank you for reply. I'm coming from Arduino 8 bit programming. So STM32's BSRR register a bit confusing. Actually maybe it's more easy to use BRR register for reset a bit on port. I guess I need to leave Arduino IDE and focus on STM32 Cube IDE :)
@ikeabuchi1
@ikeabuchi1 3 жыл бұрын
sorry couldnt watch.. intro yikes lol
@eitantal726
@eitantal726 Жыл бұрын
Disliked for the annoying music and the robot voice
@byatse3013
@byatse3013 Жыл бұрын
hello hello help me i want to use in Keil this code tft ili9325 parallel 8bit how migration to Keil or how to write in Keil please help me
@skvalavideo
@skvalavideo 2 жыл бұрын
I use your all code for ili9486 uno shield 3.5 TFT and connection same as yours but it read wrong I'd it read 38022 and not work plz help me
@ControllersTech
@ControllersTech 2 жыл бұрын
38022 is decimal = 0x9486 in hex
@skvalavideo
@skvalavideo 2 жыл бұрын
Ok but nothing is on display only white screen
@skvalavideo
@skvalavideo 2 жыл бұрын
@@ControllersTech plz help me sir nothing is on display only white screen is coming,, I uncomment the define support 9342 and change screen size in user setting, what other thing I can do?
@elmirakassymova380
@elmirakassymova380 2 жыл бұрын
@@skvalavideo Hello, I will test the same display tomorrow. And I think that I have a clue. try to uncomment SUPPORT_B509_7793.
@anthonyalfredocastanedapon4284
@anthonyalfredocastanedapon4284 2 жыл бұрын
@@elmirakassymova380 i did it and no results...did u solve it?
Introduction to Free RTOS in STM32 || CubeIDE || Tasks || priorities
16:26
Жайдарман | Туған күн 2024 | Алматы
2:22:55
Jaidarman OFFICIAL / JCI
Рет қаралды 1,4 МЛН
STM32 + LCD TFT = Display Any Data
17:28
Nick Electronics
Рет қаралды 10 М.
ST7735 1.8" TFT Display and STM32 || HAL
8:38
ControllersTech
Рет қаралды 38 М.
Biggest TFT 7" for Arduino or ESP32 - Parallel Communication
10:16
Electronoobs
Рет қаралды 49 М.
Graphics with STM32 - 3 Display Interfaces
20:19
STMicroelectronics
Рет қаралды 43 М.
Arduino Touchscreen Display - Using a Resistive Touchscreen
38:51
DroneBot Workshop
Рет қаралды 401 М.
How to set up TouchGFX with SPI Displays || ILI9341
20:33
ControllersTech
Рет қаралды 48 М.
Собери ПК и Получи 10,000₽
1:00
build monsters
Рет қаралды 1,7 МЛН
Will the battery emit smoke if it rotates rapidly?
0:11
Meaningful Cartoons 183
Рет қаралды 36 МЛН
iPhone 12 socket cleaning #fixit
0:30
Tamar DB (mt)
Рет қаралды 55 МЛН
Samsung S24 Ultra professional shooting kit #shorts
0:12
Photographer Army
Рет қаралды 35 МЛН