Nokia 5110 with an Arduino

Discussion in 'Embedded Systems and Microcontrollers' started by orlandoperalta23, Sep 29, 2016.

  1. orlandoperalta23

    Thread Starter New Member

    Oct 22, 2015
    12
    2
    Hi everybody

    I´m trying to use the Nokia 5110 with an arduino. The schematic is like this:
    upload_2016-9-29_12-16-17.png

    I was searching and prove a lot of librarys, but the display always appear blank

    I´m also was trying replace the DC4050 by 10k resistors to limit the current, but the result is the same

    I dont understand what I´m doing wrong

    My reference pages are:

    http://forums.4fips.com/viewtopic.php?t=1086
    https://www.sparkfun.com/products/10168
    https://learn.adafruit.com/nokia-5110-3310-monochrome-lcd/overview
    http://forum.arduino.cc/index.php?topic=176794.0
    https://brainy-bits.com/tutorials/how-to-use-the-nokia-5110/


    But all this attempts were a failure.

    If you can help me with this, I´ll be grateful
     
  2. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,070
    3,841
    The displays are standardized but the red pcb is not standardized. Make sure the pin out on your board are in the same order as those on the tutorials. If not, adjust jumper wires appropriately.

    Also, what code are you using?
     
    orlandoperalta23 likes this.
  3. orlandoperalta23

    Thread Starter New Member

    Oct 22, 2015
    12
    2
    Hi GopherT, thanks for your answer.

    [​IMG]
    That is my display, so I´m sure about the pinout. And my code is this;

    Code (Text):
    1. #define RST 3
    2. #define CE 4
    3. #define DC 5
    4. #define DIN 6
    5. #define CLK 7
    6.  
    7. void LcdWriteCmd(byte cmd)
    8. {
    9. digitalWrite(DC, LOW); //DC pin is low for commands
    10. digitalWrite(CE, LOW);
    11. shiftOut(DIN, CLK, MSBFIRST, cmd); //transmit serial data
    12. digitalWrite(CE, HIGH);
    13. }
    14.  
    15. void setup()
    16. {
    17. pinMode(RST, OUTPUT);
    18. pinMode(CE, OUTPUT);
    19. pinMode(DC, OUTPUT);
    20. pinMode(DIN, OUTPUT);
    21. pinMode(CLK, OUTPUT);
    22. digitalWrite(RST, LOW);
    23. digitalWrite(RST, HIGH); LcdWriteCmd(0x21); // LCD extended commands
    24. LcdWriteCmd(0xB8); // set LCD Vop (contrast)
    25. LcdWriteCmd(0x04); // set temp coefficent
    26. LcdWriteCmd(0x14); // LCD bias mode 1:40
    27. LcdWriteCmd(0x20); // LCD basic commands
    28. LcdWriteCmd(0x09); // LCD all segments on
    29. }
    30.  
    31. void loop()
    32. {
    33. }
    Thanks for your time
     
  4. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,070
    3,841
    Who wrote this script? I'm not sure the serialOut command can support four parameters. I think you are limited to three.
     
  5. orlandoperalta23

    Thread Starter New Member

    Oct 22, 2015
    12
    2
    is a script that i found in the description of this video:

    As you can see, this code works fine in the video, but no for me.

    So, other code that a try was this:http://forums.4fips.com/viewtopic.php?t=1086, that use the library u8glib (https://github.com/olikraus/u8glib). I follow all steps, but the display still blank.

    I have a question: If I try with an arduino UNO instead an arduino Nano, could this solve the problem. It means, exists a significant difference in port characteristics between them?
     
    Last edited: Oct 2, 2016
  6. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,070
    3,841
    It looks ok, except you seem to have two commands on line 23. Move the

    image.jpeg
     
  7. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,070
    3,841
    Also, use pins 4,5,6,7,8 instead of 3 thru 7 (pin 3 can get finnicky with interrupt).

    Add a delay(1) command after the reset is complete.
     
  8. orlandoperalta23

    Thread Starter New Member

    Oct 22, 2015
    12
    2
    Thanks for your answer.

    Later a lot of effort I test with a different bread board and now it works fine

    GopherT, you are awesome. Thanks for your help
     
    GopherT likes this.
  9. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,070
    3,841
    Thanks for checking back to let us know you got it working.
     
Loading...