61. STM32CubeIDE LCD 1602 Display. I2C 16x2 with STM32F446RE

  Рет қаралды 29,986

MicroPeta by Nizar Mohideen

MicroPeta by Nizar Mohideen

Күн бұрын

Пікірлер: 92
@NizarMohideen
@NizarMohideen 6 ай бұрын
If Blank screen, please check for 5 Volt for VCC supply, potentiometer adjustment or i2c address modification on the solder pads etc. If itoa function gives you an error, use sprintf instead of itoa as shown below sprintf(snum,"%d", x); You need to include stdio.h for this function as shown below /* USER CODE BEGIN Includes */ #include "stdio.h" /* USER CODE END Includes */
@damiansklencik6830
@damiansklencik6830 2 жыл бұрын
This guy is a star !!! 100% top stuff .... easy, simple, quick and easily usable with other STM32 models.... saved me lots of work.... other videos was making dramas and wasting lots of time and still didn't get it work but this worked in minutes on first attempt....... VERY COOL STUFF
@TheWinnieston
@TheWinnieston 11 күн бұрын
Hey man! You really saved my ass! I've seen your tutorials on the web but never knew it was you! Just so you guys know: the DelayUS function seems to either be *not working*, *requiring a timer*, or *hardware specific*. I am NOT using an F4, I'm using an F7, so maybe its that. Unfortunately, I do not have enough time to sort that out right now, but I may in the future. Just to know, a quick fix is to replace the DelayUS with a HAL_Delay(5) or something like that.
@EDDY26222
@EDDY26222 6 ай бұрын
this man is single handedly saving my academic life haha thank you, means alot.
@hamidrezaabolpourmoshiz575
@hamidrezaabolpourmoshiz575 2 жыл бұрын
Very fast, easy and professional. you are the best.
@darwintrujillo9425
@darwintrujillo9425 2 жыл бұрын
Excellent video, thanks for all Mr. Nizar.
@NizarMohideen
@NizarMohideen 2 жыл бұрын
Glad you liked it!
@garetts8156
@garetts8156 2 жыл бұрын
Depending on the connector (A0 - A2) on the i2c board your address might be from 20 to 27. So you can search for info or try all addresses. On my board jumper A0 was connected, so address was 26. Otherwise everything works, thanks for tutorial.
@NizarMohideen
@NizarMohideen 2 жыл бұрын
Thanks for the info!
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
I'd like more info on this cause mine is not working and I'm quite sure it is that address issue. Neither A0, A1 or A2 are jumpered on my board. You said "search for info" .... where do we do that ? I have some sort of rotary switch. How does all this addressing work ? Thanks.
@garetts8156
@garetts8156 2 жыл бұрын
According to that table your address is 0x27
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
@@garetts8156 Sorry, where is this table ?
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
@@garetts8156 I didn't see a table. In any event, I got this off of Google "If your LCD has a Texas Instruments’ PCF8574 chip, its default I2C address is 0x27Hex. If your LCD has NXP Semiconductors’ PCF8574 chip, its default I2C address is 0x3FHex.". Sure enough, mine is a NXP chip. Other than address, not sure what other code changes need to happen.
@edwintjoa6099
@edwintjoa6099 3 жыл бұрын
Thanks for the video and explanation. I tried to follow micropeta page code but unable to get my LCD to work. The code uploaded but nothing is displayed on my LCD. Are there other configuration needed beside the I2C1 init. Here my i2c setting, not sure if the address 0x27 is correct. hi2c1.Instance = I2C1; hi2c1.Init.ClockSpeed = 100000; hi2c1.Init.DutyCycle = I2C_DUTYCYCLE_2; hi2c1.Init.OwnAddress1 = 78; hi2c1.Init.AddressingMode = I2C_ADDRESSINGMODE_7BIT; hi2c1.Init.DualAddressMode = I2C_DUALADDRESS_DISABLE; hi2c1.Init.OwnAddress2 = 0; hi2c1.Init.GeneralCallMode = I2C_GENERALCALL_DISABLE; hi2c1.Init.NoStretchMode = I2C_NOSTRETCH_DISABLE; if (HAL_I2C_Init(&hi2c1) != HAL_OK) { Error_Handler(); }
@NizarMohideen
@NizarMohideen 3 жыл бұрын
There are no other configuration besides I have shown on video and docs. After selecting I2C, Set PB8 to I2C1_SCL Set PB9 to I2C1_SDA If the jumper behind the LCD not modified, the address is 0x27. The address for cubeide is (0x27
@edwintjoa6099
@edwintjoa6099 3 жыл бұрын
@@NizarMohideen I have finally got a new LCD with PF8574 backpack and it works like a charm. Thanks.
@NizarMohideen
@NizarMohideen 3 жыл бұрын
Thanks.
@incxxxx
@incxxxx 7 ай бұрын
Does not work for stm32F103C6T6, except clearing screen no other sign. Though I changed for appriopriate HAL library, and trying change address. Have you any suggestion?
@NizarMohideen
@NizarMohideen 7 ай бұрын
It worked with stm32f103c8t6. kzbin.info/www/bejne/ol6th6Gif66Dl9E as far as stm32f103c6t6, if there are no errors regarding memory shortage and code uploading goes well, then it should work check for 5Volt supply, potentiometer adjustment or i2c address modification on the solder pads etc..
@incxxxx
@incxxxx 7 ай бұрын
@@NizarMohideen Thanks.
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
What about external pull ups on the I2C lines ?
@NizarMohideen
@NizarMohideen 2 жыл бұрын
If you use long wires between MCU and display, then pull ups necessary. If short wires, then it is optional. Thanks
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
@@NizarMohideen Not sure what qualifies as long but I'll try a couple of 10K's on those lines.
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
Well my lcd at least lit up after i changed to another one and put pull ups on it. The display backlight toggled every few seconds which I assumed might have been the program running but my display is saturated off a 5v supply and now I'm wondering if this blue rotary switch is in fact the contrast pot ??
@jc4359
@jc4359 Жыл бұрын
4.7K for frequency under 100Kbps 2.2K for ~100Kbps 1K for more than 100Kbps From my Microprocessors class today, discussing the same kind of i2c utilization with a different development board; these values above should be standard, to the Vcc rail.
@fernandoesperanza2932
@fernandoesperanza2932 2 жыл бұрын
Very good congratullations
@amirphilip2234
@amirphilip2234 10 ай бұрын
Yes the code is uploaded successfully but there is no output on the screen. My screen is blue not green as in the video.
@sebass4379
@sebass4379 7 ай бұрын
I'm having the same problem. Did you end up finding a fix?
@amirphilip2234
@amirphilip2234 7 ай бұрын
​@@sebass4379 Yes I did,try adjust the contrast on the I2C module and it should work
@fatfat5198
@fatfat5198 4 ай бұрын
hi , i have a project that produces electricty with copper wire and magnets, the circuit is finished im using bridge to capacitor on breadboard also resistor to the led it lights.so i wanna measure the voltage that produced and display it on 12c 16x2 lcd using stm32401f , can u give some advice about walktrought ?
@NizarMohideen
@NizarMohideen 4 ай бұрын
Make sure to measure less than 3.3V DC ADC video is kzbin.info/www/bejne/gqDXZnagrbKgqc0 Thanks
@fatfat5198
@fatfat5198 3 ай бұрын
@@NizarMohideen i want to measure the voltage that come throught capacitor on the breadboard, i sellected pa0 for adc, connected with the pozitive leg of capacitor and ground to the negative leg.also how can i find the proper code to measure the voltage at specific point like capacitor as i said and display it on lcd.
@zero2717
@zero2717 4 ай бұрын
Pretty good if you have the same LCD. I can't seem to find the address to my LCD, RX2004A, 4x20.
@NizarMohideen
@NizarMohideen 4 ай бұрын
Try. DEVICE_ADDR (0x3F
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
Can't get mine to work. It's an NXP chip as opposed to TI and apparently needs a different address which I supplied. Still doesn't work. does that rotary switch have any bearing on the address ? I have nothing jumpered. Founds this online "The I2C address of your LCD depends on the manufacturer, as mentioned earlier. If your LCD has a Texas Instruments’ PCF8574 chip, its default I2C address is 0x27Hex. If your LCD has NXP Semiconductors’ PCF8574 chip, its default I2C address is 0x3FHex." I've tried both addresses but neither worked.
@NizarMohideen
@NizarMohideen 2 жыл бұрын
Line no 58 of liquidcrystal_i2c.h, change to #define DEVICE_ADDR (0x27
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
@@NizarMohideen Yes I did that per my other posting but it still doesn't work. Will try some pull ups next. I'd still like to know what the rotary switch is all about. I would think it must have something to do with addressing ???
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
Oddly enough this came to life when I changed back to the alleged TI address 0x27 even though I had a NXP chip.. I also simultaneously added 10 k pull ups. Don't which or if both measures brought it to life. Awesome tutorial !! I look forward to watching your other tutorials.
@NizarMohideen
@NizarMohideen 2 жыл бұрын
Thanks
@SmeeUncleJoe
@SmeeUncleJoe 2 жыл бұрын
Very nice presentation. Subscribed for sure !! Write a book.
@martindestefano4625
@martindestefano4625 2 жыл бұрын
Hi! I have a problem with the writing, my LCD turn on and turn off the background light but doesn't write anything. My board is the F401RE. Do you know what is the problem? Is the address? Thank you!
@thoup
@thoup 2 жыл бұрын
There's a blue thing on the back of the LCD display. You have to tighten it with a screwdriver
@hazemsaad7477
@hazemsaad7477 2 жыл бұрын
I FIGURED IT OUT! Just tighten the screw at the back of the display.
@soufelectronicsandengineer7472
@soufelectronicsandengineer7472 2 жыл бұрын
Hello... Thank you so much for this interesting video.. I have nucleo L476, i tried lcd shield using Arduino IDE, i have no result... The LCD didn't work , while it worked well with my Arduino uno
@NizarMohideen
@NizarMohideen 2 жыл бұрын
I understood you tried nucleo L476 lcd shield using Arduino IDE. I suggest to try with STM32CubeIDE. Installation of STM32CubeIDE is in video no 50 in my KZbin channel
@savinogiovannimuscio2953
@savinogiovannimuscio2953 7 ай бұрын
Hi every ones. My 16x02 LCD is working fine in arduino, my STM32 U575ZI-Q is working fine on the other project, the CIP on I2C is PCF8574T and by using all the combination described in all comment below, still I see only the backlight on the 1st line of the LCD on the LCD. Help please
@NizarMohideen
@NizarMohideen 7 ай бұрын
Line no 58 of liquidcrystal_i2c.h, change to #define DEVICE_ADDR (0x27
@savinogiovannimuscio2953
@savinogiovannimuscio2953 7 ай бұрын
@@NizarMohideen He, as i wrote at firt, I tried all combination, also considering the 4E defoult address. Nothing to do, i see no sentence on my scree
@savinogiovannimuscio2953
@savinogiovannimuscio2953 7 ай бұрын
the status of the A0 A1 and A2 on the chip of the IC on the screen are not jumpered, but it is not working, i dont know what esle i can do
@NizarMohideen
@NizarMohideen 7 ай бұрын
Did you adjust the potentiometer on the backside
@savinogiovannimuscio2953
@savinogiovannimuscio2953 7 ай бұрын
@@NizarMohideen good evening. For sure i did. In Arduino all working. Only on STM32 i am facing so much. I try all possible things.
@mehmetakilkeles4259
@mehmetakilkeles4259 Жыл бұрын
HOW CAN I SEE THE "DISTANCE" VALUE ON THE LCD SCREEN WITH HCSR04?
@landeriza5733
@landeriza5733 Жыл бұрын
Very good video!! Just a doubt, which is the LCD display you used? Could upload the link to buy it? Thanks a lot.
@youtuberzp6665
@youtuberzp6665 2 жыл бұрын
Hi sir How can I print Integer in my lcd? what to use instead of HD44780_PrintStr?
@chandibenthara8539
@chandibenthara8539 7 ай бұрын
Thanks, i tried with STM32L432Kc and its work. i need to read the data (from usart2), how can i modify the code, please
@NizarMohideen
@NizarMohideen 7 ай бұрын
Sure. you can use usart2 Thanks
@bandulamanchanayaka4971
@bandulamanchanayaka4971 7 ай бұрын
if any examples can I found
@EasyEduHacks
@EasyEduHacks 2 жыл бұрын
everything is working but the backlight is not turning on can you help us out with this problem?
@DILEEP1819
@DILEEP1819 Жыл бұрын
Sir for me it's only turn off n turn on is happening, it's not writting anything?
@METHEE.C
@METHEE.C Жыл бұрын
can't display float?
@damiansklencik6830
@damiansklencik6830 2 жыл бұрын
it works well but I am trying to use it with 20X4 lcd and I am struggling to...... can you help ???
@montassarfatnassi5555
@montassarfatnassi5555 2 жыл бұрын
Will the same code work for stm32f767 Nucleo 144? , Thanks
@vladvlad9834
@vladvlad9834 Жыл бұрын
Повторил!!! Работает!! Только адрес выставил 0x3FHex
@ozantunca6457
@ozantunca6457 Жыл бұрын
Although I have done everything completely step by step and even though I have not received errors, I do not see any writing on the screen.
@amirphilip2234
@amirphilip2234 10 ай бұрын
I also face the same thing..the code is uploaded successfully but not output on the screen
@onlycarlx
@onlycarlx Жыл бұрын
Hi, it gives this error: ../Core/Src/liquidcrystal_i2c.c:3:8: error: unknown type name 'I2C_HandleTypeDef'
@IratiEsnaolaBlazquez
@IratiEsnaolaBlazquez Жыл бұрын
Does someone know which is the LCD 1602 Display he is using? Thank you!!!!! :)
@thronex4741
@thronex4741 3 ай бұрын
my display shows very dim text which is barely visible , its connected to 3.3v and if i connect to 5v the display wont start so i dont know how to solve this problem, can anyone help me?
@NizarMohideen
@NizarMohideen 3 ай бұрын
adjust the potentiometer on the backside
@thronex4741
@thronex4741 3 ай бұрын
@@NizarMohideen I did that nothing happened the potentiometer is all the way on one side where the text is barely visible on the other side the text is not visible at all and if i give 5v supply the backlight also doesn't switch on, i don't want to burn it either
@dinhle8452
@dinhle8452 3 жыл бұрын
can you do it with INMP411 module
@NizarMohideen
@NizarMohideen 3 жыл бұрын
I am sorry. I don't have INMP411 module with me at the moment
@mhassanbashir
@mhassanbashir Жыл бұрын
I am using STM32F407 it is working fine for 16x4LCD.Sir is it also work for 20x4LCD or not ??
@gauravkhanekar3924
@gauravkhanekar3924 Жыл бұрын
Yes it can work but littel bit changes are required 😊
@vijayrathore8284
@vijayrathore8284 2 жыл бұрын
sir itoa function gives me error,what should i do
@NizarMohideen
@NizarMohideen 2 жыл бұрын
Use sprintf instead of itoa as shown below sprintf(snum,"%d", x); You need to include stdio.h for this function as shown below /* USER CODE BEGIN Includes */ #include "stdio.h" /* USER CODE END Includes */
@vijayrathore8284
@vijayrathore8284 2 жыл бұрын
@@NizarMohideen thank you sir, it's working
@ghidhaouinada254
@ghidhaouinada254 Жыл бұрын
Hi, can I use the same code for lcd1604??
@neelambikevg8548
@neelambikevg8548 3 жыл бұрын
Will the same code work for stm32f401re?
@NizarMohideen
@NizarMohideen 3 жыл бұрын
Although I haven't tested it using stm32f401re, it should work with it. Thanks
@damiansklencik6830
@damiansklencik6830 2 жыл бұрын
When you selected your module just select your one and everything else same.... I used STM32F411RE and it worked with 20X4 LCD no problem
@sachiththagihashan2808
@sachiththagihashan2808 Жыл бұрын
@@damiansklencik6830 which module bro..? mine is not working.
@dduringddu
@dduringddu 8 ай бұрын
Thank you very much!! I owe you
@quocvan-s6b
@quocvan-s6b 6 ай бұрын
My code encounters an error related to itoe, please help me bro.
@NizarMohideen
@NizarMohideen 6 ай бұрын
If itoa function gives you an error, use sprintf instead of itoa as shown below sprintf(snum,"%d", x); You need to include stdio.h for this function as shown below /* USER CODE BEGIN Includes */ #include "stdio.h" /* USER CODE END Includes */
@vedattilgen1765
@vedattilgen1765 Жыл бұрын
i did the same but it doesn't work
@vladvlad9834
@vladvlad9834 Жыл бұрын
Класс!!! Спасибо!!!!!! Очень качественное видео!! И присутствует программный код!!!!!
@alexandergrass978
@alexandergrass978 2 жыл бұрын
great it works
60. STM32CubeIDE LCD 1602 Display. Parallel 16x2 with STM32F446RE
9:47
MicroPeta by Nizar Mohideen
Рет қаралды 31 М.
57. STM32CubeIDE LCD 1602 Display. I2C 16x2 with STM32F103C8T6
7:24
MicroPeta by Nizar Mohideen
Рет қаралды 20 М.
Mom Hack for Cooking Solo with a Little One! 🍳👶
00:15
5-Minute Crafts HOUSE
Рет қаралды 23 МЛН
My scorpion was taken away from me 😢
00:55
TyphoonFast 5
Рет қаралды 2,7 МЛН
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН
LCD via I2C in STM32 || CUBEIDE || PCF8574
12:22
ControllersTech
Рет қаралды 85 М.
STM32 HAL with CubeMX: Tutorial 42 - I2C LCD16x2 driver
8:25
Mutex Embedded
Рет қаралды 23 М.
How Did I write the I2C-LCD Library || Explained
14:41
ControllersTech
Рет қаралды 30 М.
3 engineers race to design a PCB in 2 hours | Design Battle
11:50
Predictable Designs
Рет қаралды 489 М.
RTC in STM32 || LCD 16x2 || HAL || CubeMx
16:31
ControllersTech
Рет қаралды 56 М.
Interface I2C-LCD with STM32 || AIP31068 with Built-in I2C
12:55
ControllersTech
Рет қаралды 2,9 М.
STM32 Nucleo - Keil 5 IDE with CubeMX: Tutorial 7 - I2C interface
10:26
Ethernet Web Server with STM32 & W5500 Tutorial | Mongoose WS API
14:05
2024's Biggest Breakthroughs in Math
15:13
Quanta Magazine
Рет қаралды 356 М.
Mom Hack for Cooking Solo with a Little One! 🍳👶
00:15
5-Minute Crafts HOUSE
Рет қаралды 23 МЛН