16x2 lcd not responding properly

hello!!
i am working on a project which is a password protected door lock system. it uses, atmega32 microcontroller, a motor controlled by L293D motor driver, a keypad and a widely used 16x2 lcd. i have attached the circuit diagram. but as i press the security code, the lcd doesnt respond although the motor rotates according to the code. why does the lcd not respond?? does anybody have any explanation???

Replies

  • Abhishek Rawal
    Abhishek Rawal
    Where is circuit diagram ?
  • dhruba sunuwar
    dhruba sunuwar
    Abhishek Rawal
    Where is circuit diagram ?
    i have also uploaded the picture of the motor i have used.. when i used other motors it works properly but when the one shown in the figure is used the lcd doesnt respond!!
  • Harshad Italiya
    Harshad Italiya
    #-Link-Snipped-# :
    If you are using another motor and it is working properly then I think the motor you are using is drawing more current and so LCD is not getting enough to turn ON. What is the source you are providing and how you are regulating 5v?
  • dhruba sunuwar
    dhruba sunuwar
    dhruba sunuwar
    hello!!
    i am working on a project which is a password protected door lock system. it uses, atmega32 microcontroller, a motor controlled by L293D motor driver, a keypad and a widely used 16x2 lcd. i have attached the circuit diagram. but as i press the security code, the lcd doesnt respond although the motor rotates according to the code. why does the lcd not respond?? does anybody have any explanation???
    Harshad Italiya
    #-Link-Snipped-# :
    If you are using another motor and it is working properly then I think the motor you are using is drawing more current and so LCD is not getting enough to turn ON. What is the source you are providing and how you are regulating 5v?
    i have used an ac adaptor, that converts the ac to 9v dc. i'v used LM7805 to power the microcontroller and LM7809 to power the motor.
  • Harshad Italiya
    Harshad Italiya
    dhruba sunuwar
    i have used an ac adaptor, that converts the ac to 9v dc. i'v used LM7805 to power the microcontroller and LM7809 to power the motor.
    Check current consumption in both motor and post them here.
  • dhruba sunuwar
    dhruba sunuwar
    Harshad Italiya
    Check current consumption in both motor and post them here.
    the motor to which LCD wasnt responding draws 140mA and the one to which LCD responds properly draws 30mA. what you said earlier appears to be correct. what should be done to use the 140mA current drawing motor?? a separate power supply for the motor driver perhaps? is it possible to use the single source and also not have the above mentioned problem(i.e. lcd not responding properly)??
  • lal
    lal
    Yes, it is. Use a source with higher current capacity. What is the maximum current capacity of the DC adapter you are using now and is it current limited?

    By the way, using a 7809 on a 9V DC output wouldn't do any good. IIRC, it is not a LDO regulator and you would need to supply an input with 2.5V to 3V head room for regulation. That is, input has to be around 12V DC. A quick look at the data sheet would help. If you continue using the 9V supply, 7809 may be avoided for the motor. It is not doing any help in this scenario I guess.
  • Harshad Italiya
    Harshad Italiya
    dhruba sunuwar
    the motor to which LCD wasnt responding draws 140mA and the one to which LCD responds properly draws 30mA. what you said earlier appears to be correct. what should be done to use the 140mA current drawing motor?? a separate power supply for the motor driver perhaps? is it possible to use the single source and also not have the above mentioned problem(i.e. lcd not responding properly)??
    In this case 7805 should provide enough current ! What is capacity of your adaptor?
  • dhruba sunuwar
    dhruba sunuwar
    Harshad Italiya
    In this case 7805 should provide enough current ! What is capacity of your adaptor?
    9v 0.85A
  • dhruba sunuwar
    dhruba sunuwar
    lal
    Yes, it is. Use a source with higher current capacity. What is the maximum current capacity of the DC adapter you are using now and is it current limited?

    By the way, using a 7809 on a 9V DC output wouldn't do any good. IIRC, it is not a LDO regulator and you would need to supply an input with 2.5V to 3V head room for regulation. That is, input has to be around 12V DC. A quick look at the data sheet would help. If you continue using the 9V supply, 7809 may be avoided for the motor. It is not doing any help in this scenario I guess.
    the adapter's output is 9v, 0.85A.
    as you said i tried using a 12v 9Ah battery.. but the problem still persists!
  • Harshad Italiya
    Harshad Italiya
    dhruba sunuwar
    i used 12v 9Ah battery.. but the problem still persists!
    Ok, if you can have dedicated 5v supply for motor and another 5v regulator for all other things then please try that and update the result. If that is also not working then we may think on something else that is creating this issue
  • Arthur McKendry
    Arthur McKendry
    dhruba sunuwar
    hello!!
    i am working on a project which is a password protected door lock system. it uses, atmega32 microcontroller, a motor controlled by L293D motor driver, a keypad and a widely used 16x2 lcd. i have attached the circuit diagram. but as i press the security code, the lcd doesnt respond although the motor rotates according to the code. why does the lcd not respond?? does anybody have any explanation???
    W/O looking at the actual LCD data sheet it would seem that your unused Data Input Pins D0,D1,D2 and D3 need to be connected. Most LCD inputs are expecting ASCII codes, for example the numbers 0,1,2 are ASCII (Hex) 30,31,32, a binary "1" would be 0011 0001. This takes all 8 bits. Even if using the LCD is using BCD codes the unused input bits probably need to be terminated or grounded. You may even need all 8 bits to put it in "nibble"/4 bit mode. You can share 4 of your KeyPad I/O pins for this. When writing to the LCD set those pins to Outputs. When reading from the Keypad set them as inputs and don't toggle the LCD R/W, CE or E lines. Write your code so the Keypad and LCD routines share the lines (only one routine allowed active at once), no re-entrant code.
  • dhruba sunuwar
    dhruba sunuwar
    thank you for the
    Arthur McKendry
    W/O looking at the actual LCD data sheet it would seem that your unused Data Input Pins D0,D1,D2 and D3 need to be connected. Most LCD inputs are expecting ASCII codes, for example the numbers 0,1,2 are ASCII (Hex) 30,31,32, a binary "1" would be 0011 0001. This takes all 8 bits. Even if using the LCD is using BCD codes the unused input bits probably need to be terminated or grounded. You may even need all 8 bits to put it in "nibble"/4 bit mode. You can share 4 of your KeyPad I/O pins for this. When writing to the LCD set those pins to Outputs. When reading from the Keypad set them as inputs and don't toggle the LCD R/W, CE or E lines. Write your code so the Keypad and LCD routines share the lines (only one routine allowed active at once), no re-entrant code.
    thank you for the suggestion, but that's not exactly the solution to the problem i have encountered. you see, the lcd displays perfectly for once or twice and also responds properly for keypad inputs that too for once or twice, but after some time it stops responding and have to be reset. i went through somearticles, and they mentioned about the use of decoupling capacitors.. i used a decoupling capacitor, and it works perfectly now. thank you so much for you concern sir!! 😀
  • dhruba sunuwar
    dhruba sunuwar
    Harshad Italiya
    Ok, if you can have dedicated 5v supply for motor and another 5v regulator for all other things then please try that and update the result. If that is also not working then we may think on something else that is creating this issue
    i went through some articles online and i used a decoupling capacitor across lcd's supply. and it worked!! thanks for your suggestions
  • Harshad Italiya
    Harshad Italiya
    dhruba sunuwar
    i went through some articles online and i used a decoupling capacitor across lcd's supply. and it worked!! thanks for your suggestions
    Good to see that it's working at your end. Please keep us updated about your project.

You are reading an archived discussion.

Related Posts

Hello all my crazy engineers, I'm Logan and currently working as a website designer in Bhopal, after a long wait i finally got job but not satisfied. As I'm a...
I am Idachaba Ojodale, a computer science student in federal university, Lokoja, kogi state Nigeria. I am about writing my final year project. I love football, my hobby is watching...
As an electronics and telecommunication engineer, which is best suitable career with hot sallery for this stream? Experianced people please share your openions.
sir I am doing my B.E (Ece)in Sathyabama university chennai so I have planned to do a internship program with drdo so indeed I don't no to which mail id...
My Name: Rahul Matwala My Engineering Discipline: Electronics & Communication What Do I Do? : Tech. Support Engineer How many years of experience do I have? only 0.75 year. What...