37. STM32CubeIDE ILI9341 TFT Display with STM32F103C8T6

แชร์
ฝัง
  • เผยแพร่เมื่อ 25 ก.ย. 2024

ความคิดเห็น • 77

  • @wilanne
    @wilanne ปีที่แล้ว +1

    Work flawlessly on a STM32F103RB !

  • @Delgi_500
    @Delgi_500 ปีที่แล้ว +1

    Great, that helped a lot! Thx m8 ! After adapting Ports / SPI to my HW config it worked instantly like a charm🤩
    ('F401 black pill clone + 2.8" TFT with touch controller)
    Allow me some technical remarks (not critisism at all, but maybe helpful):
    a) Most chinese display of this type have a 3.3V LDO Onboard, so I would suggest to connect the VCC Pin to 5V.
    With this aproach the power burden on the MCU board LDO is significantly reduced ("load sharing" on 5V line).
    (But always check datasheet and jumpers first!)
    b) The ILI9341 datasheet states a "SCL" (aka SPI SCK) clock period of min. 100ns -> 10MHz max. so i recommend
    to check the SPI Baudrate result and adjust the prescaler value accordingly. Even if it may work at higher clock
    rates it may become instable (over temperature typically).
    Keep up your great work!
    Greetings from actually quite snowy☃ germany...

  • @Rolandas3K
    @Rolandas3K ปีที่แล้ว

    Thank you very much! Tried and it worked. I have redone it for SPI2 as planning to keep PortA for other purposes. now i will try to learn making menus and use touch buttons.

  • @Alexcymantrene
    @Alexcymantrene 13 วันที่ผ่านมา

    Dear friend! Thank you for the wonderful video! Could you use the example of this display to show how to work with an sd card?

  • @andresfelipe6085
    @andresfelipe6085 2 ปีที่แล้ว +1

    It works really well for my STM411. Thanks you, I love the STM32 ucontroller so you a new subscribe :D

  • @H.Ebrahimi
    @H.Ebrahimi หลายเดือนก่อน

    Hey, i followed your instructions but i can only change the background color with ILI9341_FillScreen function, other functions do not work for me :( , can you help please? im using 2.8 tft spi 240*320 v1.2 lcd with bluepill

  • @aliroshan659
    @aliroshan659 2 ปีที่แล้ว +1

    Hello, thank you for this project
    I made a font using the GLCD font creator software, but it is not displayed correctly because of the "offset of character". How can I extract this number for my font? How did you calculate the offset value for your font?

    • @robc3863
      @robc3863 ปีที่แล้ว

      Did you fix it in the end?

  • @robc3863
    @robc3863 ปีที่แล้ว

    To get my MCU working at maximum CPU speed I had to enable FIFO on the DMA parameters. Without it I had to reduce the HCLK and FCLK by 2, from 168 MHz to 72 MHz else the LCD bitmap and data was being corrupted at times, rectangles not filling the whole area mainly. Reading the datasheet I see that only with FIFO does the data get packed and unpacked to "maximise" bandwidth, but why is FIFO enabled so necessary to make this work reliably?

  • @lukasladler3212
    @lukasladler3212 2 ปีที่แล้ว +1

    You really helped and the Library works great. You left some Instructions on how to make new fonts using GLCD font creator. But at point 9 where you instructed to change the offset, width, height, bpl. Height and width are clear (They are given in the title). But where do i get the Offset and BPL values from?? And what even do these. I need some help here ty!

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +1

      Library creator's GitHub Repo is at github.com/eziya/STM32_HAL_ILI9341
      He says about fonts
      I wanted to make it support diverse fonts so I adopted character functions from SPI_TFT_ILI9341 library.
      As it supports C font array created by GLCD Font Creator by MikroElektronika.
      www.mikroe.com/glcd-font-creator
      Please refer to the following link to get more details about fonts.
      os.mbed.com/users/dreschpe/code/SPI_TFT_ILI9341/

  • @ArdiansyahPutra-n5u
    @ArdiansyahPutra-n5u 8 หลายเดือนก่อน

    hello, can this library also be used on 3.5 TFT LCD SHIELD ILI9486 connected to stm32f1(bluefill)?

  • @meilleur102
    @meilleur102 ปีที่แล้ว

    Will this work with a ILI9488? I don't really want to use the Touche so only the Display on my side

  • @contomo5710
    @contomo5710 ปีที่แล้ว

    i tried to edit the libary with init code for the ST7796S, however i cant get the display to init properly. any idea how i can port a libary to stm32cube ide?

  • @parsafaraj8580
    @parsafaraj8580 2 ปีที่แล้ว

    Hello, i have 2 questions. At first how can i clear the LCD ? I didnt find the clear command , and the second one is :can i put the logo of this lcd or not ? Thank you very much .

  • @carlosbarberis49
    @carlosbarberis49 2 ปีที่แล้ว +1

    Thank you, this is very informative, well done and works quite well. However, I noticed that although there is four fonts included in your source code all these fonts are very narrow and I wanted to use a wider bold and larger fonts but I tried to import other fonts from the Adafruit GFX font library but they did not work. Your font set for each font starts with the first four bytes with byte values as follows: Offset, Width, Height and BPL (which I have no idea as to what this one is) Do you have any recommendations as to how to use bigger or different fonts with this code? Are these fonts in your source code considered to be scalable fonts?...Thank you

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +2

      Thanks. I did not create this library. I found it in public github repository.
      The author explains how to create new fonts at github.com/eziya/STM32_HAL_ILI9341
      I am sorry to say that I haven't tried it myself to create a new font yet. Please try the above link for new fonts.

  • @rajeshn2600
    @rajeshn2600 2 ปีที่แล้ว

    I tried doing the same thing, but when I am loading the code, the color is getting filled only at the left edge and not on the complete screen. I am using 3.2" TFT, so do I need to make any other changes?

  • @franciscogouveia1516
    @franciscogouveia1516 4 หลายเดือนก่อน

    I'm starting with the STM32..
    Excellent tutorial.
    I followed this video and programmed the Blue Pill well. Everything fine with STMCube IDE as expected and the TFT performed well too. I tried again with a Black Pill I have (STM32F401CCU6) but the debug hammer gave me 6 errors like: 'MX_SPI1_init' used but never defined.
    Can you comment about sommething I must do different with black Pill?
    Thank you.

    • @NizarMohideen
      @NizarMohideen  4 หลายเดือนก่อน

      Only need to change
      #include "stm32f4xx_hal.h"
      in ILI9341_GFX.h and ILI9341_STM32_Driver.h
      Thanks

    • @franciscogouveia1516
      @franciscogouveia1516 4 หลายเดือนก่อน

      No errors now.
      Thanks a lot

  • @Electronics_Dreams
    @Electronics_Dreams 2 ปีที่แล้ว

    I love Your videos. Saludos desde Argentina sigue así

  • @ferdinvivian9336
    @ferdinvivian9336 ปีที่แล้ว

    Sir can i display a Graph, Like square wave PWM pulse with X&Y AXIS, iF Possible plz tell me how to do

  • @andrearuo843
    @andrearuo843 2 ปีที่แล้ว

    Hi, I've tried to use your code but the display remains white.... I'm using Nucleo-L476RG and ILI9341. Have you any ideas about the problem? Thanks!

  • @zaffarsiddiq
    @zaffarsiddiq ปีที่แล้ว

    Can you confirm if this will work with the ILI9488 display please?

  • @robc3863
    @robc3863 ปีที่แล้ว

    Very useful demo, thanks! Sadly I cannot get it to work with a 407VG Discovery board, I´ve checked trough everything several time, using SPI2, changed the clock speeds to match, checked with a scope on the board, so the signals look good, there is some noise on the reset line, I´ll add a capacitor to VCC 5v input on the LCD. The v1.0 red lcd has 5-3v regulators, so I think 5v in will help with the noise. Fingers crossed!

    • @robc3863
      @robc3863 ปีที่แล้ว

      Yeah!! As soon as I added a 470uF capacitor to the VCC-GND 1-2 pins on the LCD, it started to work! Note: The Chinese schematic also says: Power supply selection:
      When the external VCC input is 5V, J1 is disconnected
      When the external VCC input is 3.3V, J1 is shorted

    • @NizarMohideen
      @NizarMohideen  ปีที่แล้ว

      Thanks

  • @rajeshn2600
    @rajeshn2600 2 ปีที่แล้ว

    Can we use the same method to interface a bigger size TFT display (one that supports SPI), say 4", without any changes?

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +1

      I have only tested this library with ILI9341

  • @lukasladler3212
    @lukasladler3212 2 ปีที่แล้ว +1

    Thank you so much!!! You helped me a great deal!!!

  • @jugnu361
    @jugnu361 ปีที่แล้ว +2

    Thanks 🙏🙏🙏

  • @이정훈-m7x7s
    @이정훈-m7x7s 2 ปีที่แล้ว

    Hello
    Thanks to this, ILI9341 TFT LCD could be developed well.
    thank you.
    But I have one question. I want to increase the size of the fonts there to a larger font. Is there a way?

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +1

      The library creators web links are
      blog.naver.com/eziya76/221579262995
      github.com/eziya/STM32_HAL_ILI9341
      He shows how to make new fonts in those two website. Thanks

  •  2 ปีที่แล้ว +1

    I had some problem with these code, everything is ok but if the main() has the funtion "ILI9341_FillScreen" and then it doesn't work, i do with stm32f103c8 also, Thank you
    .

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +2

      Can you try
      ILI9341_FillScreen(WHITE);

    •  2 ปีที่แล้ว +1

      @@NizarMohideen Of course i do with ILI9341_FillScreen(WHITE); My mean if i have this funtion in my main code, it doesnt work, if the main code doesn't have this funtion, it work well, thanks.

  •  2 ปีที่แล้ว

    Can the library display an analog clock?

  • @chrissakriv7523
    @chrissakriv7523 ปีที่แล้ว

    Tutorial for touch?

  • @bikerder
    @bikerder 2 ปีที่แล้ว +1

    Many thanks. Great help.

  • @ashutoshgoswami3063
    @ashutoshgoswami3063 5 หลายเดือนก่อน

    Sir please make a video to show how to print images on ILI9341

  • @amelhorparte9353
    @amelhorparte9353 2 ปีที่แล้ว

    Good video, very didactic. I tested with exactly same board (STM32F103C8T6) and it worked perfectly, but if I turn the board OFF and ON again, I don't have any image on the display (but the blink LED still working). If I program the board again the display works, but I can not restart it. Is there something related with RAM memory or display? Any idea? Thanks!

    • @amelhorparte9353
      @amelhorparte9353 2 ปีที่แล้ว

      I figured out. It needs a delay before ILI9341_Init(); because the microcontroller is faster than the display.

  • @pablocarvellivargas245
    @pablocarvellivargas245 ปีที่แล้ว

    Hi Nizar, excellent tutorial! I've been looking for a way to communicate with you because I have a problem: In the file ILI9341_STM_Driver.c in the function DrawColorBrust(); There is a BrustBuffer[BufferSize] declaration that gives me problems, since it requires the number of elements to be a constant value, I think it could be due to the version of my compiler, but I see that it doesn't give you any problems. I have solved it halfway, always setting the BURTS_MAZ_SIZE value but this breaks the rest of the functionality, any ideas?

    • @pablocarvellivargas245
      @pablocarvellivargas245 ปีที่แล้ว

      Well, I already found my answer. With versions prior to C99 it is not possible to declare an array with a value that is not a constant, so I have tried to "solve" the problem with the not very recommended way of using dynamic memory with malloc(), but even so, it still fails when painting the backgrounds of the characters. What surprises me the most is that in theory the IAR is using C11. If I manage to fix it, I will update it here.

  • @rajeshn2600
    @rajeshn2600 2 ปีที่แล้ว

    Can I interface this ILI9341 TFT Display with my STM32F401 Nucleo-64 development board using the same drivers and code? What would be the interface protocol, parallel or SPI? Also, can we write & display this "HELLO WORLD" text in bold and bigger font?

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +1

      You can select SPI1 and three GPIO_Output pins for CS, DC and RST pins
      Change ILI9341_STM32_Driver.h file according to the pin section as shown below
      /* PIN Configuration */
      #define HSPI_INSTANCE &hspi1
      #define LCD_CS_PORT GPIOB
      #define LCD_CS_PIN GPIO_PIN_10
      #define LCD_DC_PORT GPIOB
      #define LCD_DC_PIN GPIO_PIN_0
      #define LCD_RST_PORT GPIOB
      #define LCD_RST_PIN GPIO_PIN_1
      Configuration → Parameter Settings of SPI, change prescalar (for Baud rate) to 4
      If it doesn’t work, Change prescalar (for Baud rate) to a different number
      Available Fonts are FONT1, FONT2, FONT3 and FONT4

  • @wegi9621
    @wegi9621 ปีที่แล้ว

    Working great! Thanks man.

  • @tjeerdvandijk1332
    @tjeerdvandijk1332 2 ปีที่แล้ว

    Confirmed to work on stm32F4 using Adafruit 2.8" TFT Touch Shield w/cap touch. need to change to F4 hal and port the pins it

  • @GouriRaghavaVaranasi
    @GouriRaghavaVaranasi 2 ปีที่แล้ว

    can we show graphics or picturein the display using this library?

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +1

      The library creator named eziya in github used to display picture as well.
      He displayed a while color tiger image called snow_tiger.h
      It is available in github.com/eziya/STM32_HAL_ILI9341
      I don’t know how to create another picture in this format. Thanks

    • @GouriRaghavaVaranasi
      @GouriRaghavaVaranasi 2 ปีที่แล้ว

      @@NizarMohideen tq I will check

  • @AndresGarcia-hw6xf
    @AndresGarcia-hw6xf ปีที่แล้ว

    No me funciono 0.0 queda el display en un gris

  • @vansynghi_cdnpy
    @vansynghi_cdnpy 11 หลายเดือนก่อน

    Thank you.

  • @muzammilanwar7767
    @muzammilanwar7767 ปีที่แล้ว

    please make video on handheld game console using stm32

  • @hariprakashr9692
    @hariprakashr9692 ปีที่แล้ว

    Can these code to be used in black pill stm32f401ccub

  • @mkr32
    @mkr32 ปีที่แล้ว

    thank you

  • @maksympavlenko5305
    @maksympavlenko5305 ปีที่แล้ว

    Thanks you it works. I tried using it on Arduino UNO with 5v > 3.3V converter but i get only white display. I thougth display is broken. But i still don't know why it doesn't work on Arduino

  • @mkr32
    @mkr32 ปีที่แล้ว

    your code not working fonts error and many errors

  • @wegi9621
    @wegi9621 ปีที่แล้ว

    👋💪👍

  • @skvalavideo
    @skvalavideo 2 ปีที่แล้ว

    I have to connect ili9486 plz help me .

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว

      I am sorry. I don't have ili9486

  • @joshuachettiar86
    @joshuachettiar86 2 ปีที่แล้ว

    Can I use this on F401CC?

    • @NizarMohideen
      @NizarMohideen  2 ปีที่แล้ว +2

      I haven’t tested it with F401CC but I think you can use it with F401CC. The library creator named eziya in github used it with F407VG, I simply changed #include "stm32f4xx_hal.h" in header files to #include "stm32f1xx_hal.h" for F103C8 and it worked.
      Try by changing it back to #include "stm32f4xx_hal.h" in ILI9341_GFX.h and ILI9341_STM32_Driver.h and see. Thank you

    • @joshuachettiar86
      @joshuachettiar86 2 ปีที่แล้ว +1

      @@NizarMohideen alright I will give it a go

  • @pranava4245
    @pranava4245 26 วันที่ผ่านมา

    i have a white screen no hello world nothing

    • @pranava4245
      @pranava4245 26 วันที่ผ่านมา

      can you help please

    • @pranava4245
      @pranava4245 25 วันที่ผ่านมา

      display is working with arduino uno r4

  • @mkr32
    @mkr32 ปีที่แล้ว

    two errors
    Description Resource Path Location Type
    implicit declaration of function 'sprintf' [-Wimplicit-function-declaration] main.c /STM32F103C8T6TFT/Core/Src line 118 C/C++ Problem
    incompatible implicit declaration of built-in function 'sprintf' [-Wbuiltin-declaration-mismatch] main.c /STM32F103C8T6TFT/Core/Src line 118 C/C++ Problem

  • @GiangTruong-gm9se
    @GiangTruong-gm9se ปีที่แล้ว

    hi can you give me full code for stm32f1 use ili9341