✅✅✅ working without any issue ..... I'm using with STM32G030 MCU .......... good thing compare to other library it print Integer directly with separate function without converting it into string. Thanks for reducing our work load.
One more question please sir. If we have done everything like this, and want to print some sensor data also in while(1), how would lcd code come then? for example, over here: ADC_Select_CH4(); HAL_ADC_Start(&hadc1); HAL_ADC_PollForConversion(&hadc1,1000); ADC_VAL_Voltages[0] = readValue5; readValue5 = HAL_ADC_GetValue(&hadc1); voltage1 =(float)readValue5/4095*16.5; HAL_ADC_Stop(&hadc1); Thankyou!
You can use Lcd_int(&lcd, x); // x need to be an integer If it is a float value, break into two integers One for integral and another one for decimal separated by an dot Use three lines of code as below Lcd_int(&lcd, x) Lcd_string(&lcd, ".") Lcd_int(&lcd, y)
I'm curious if it goes well, because the author is connecting VDD to 5V and according to Datasheet of the LCD, the MIN Input High Voltage is 0.7VDD what is 3.5V, but as known the GPIOs only deliver 3.3V.
Hi, I followed your guide but I've a problem with display: the left side is less visible than the right side. I tried with from 10 - 330 Ohm resistor but nothing has changed
Hi Sir, I watched both F1 and F4 videos. Could you please tell if the lcd.c and lcd.h files/code would be same for all stm32 versions, and just change that #include part?
Hello sir...! My 1st question:-That lcd.h and lcd.c files can use any type board...? Please reply and clarify me... 2nd question:- why you are take random pins like different port pins. Why not take same serial pins like.. PORT-B 0,1,2,3,4,5,6. Can you please clarify my doubts sir ......?
It should work with all STM32 boards You can use any pins you want as long as you put the pins in Lcd_PortType ports[] = { D4_GPIO_Port, D5_GPIO_Port, D6_GPIO_Port, D7_GPIO_Port }; Lcd_PinType pins[] = {D4_Pin, D5_Pin, D6_Pin, D7_Pin}; Lcd_create(ports, pins, RS_GPIO_Port, RS_Pin, EN_GPIO_Port, EN_Pin, LCD_4_BIT_MODE);
can i ask a question sir?....the backlight does not light up. But my lcd setup is in 4bit please i need help, plus my board is installed on a board that uses seperate supply from the data input...really need assisstance
Hi, Great tutorial..I tried this example for all LCD pins connected to PORTC with connections as below: PORTC0-->RS PORC2--->EN, PORTC3 ,C4,C5,C6 ----> D4 to D7 but,I am just getting boxes and no display on LCD.. but,if I change my pins to that as shown in example it works fine.. why is it not working for my pinouts that I am using?
Set those pins to GPIO_Output use below format for ports // Lcd_PortType ports[] = { D4_GPIO_Port, D5_GPIO_Port, D6_GPIO_Port, D7_GPIO_Port }; For example Lcd_PortType ports[] = { GPIOC, GPIOB, GPIOA, GPIOA }; use below format for pins // Lcd_PinType pins[] = {D4_Pin, D5_Pin, D6_Pin, D7_Pin}; For example Lcd_PinType pins[] = {GPIO_PIN_7, GPIO_PIN_6, GPIO_PIN_7, GPIO_PIN_6}; Lcd_HandleTypeDef lcd; use below format to create LCD // Lcd_create(ports, pins, RS_GPIO_Port, RS_Pin, EN_GPIO_Port, EN_Pin, LCD_4_BIT_MODE); For example lcd = Lcd_create(ports, pins, GPIOB, GPIO_PIN_5, GPIOB, GPIO_PIN_4, LCD_4_BIT_MODE); If still doesn’t work with your new pins, use a simple led blink on each pins to check for faulty pins You can also try with some other pins. Thanks
@@NizarMohideen Hello..I checked that because of improper wiring all the problems now all works fine..I would like to know how do you avoid wiring problems which go unnoticed and we keep checking the program..