bitbang Nokia 5110 LCD with 14M2

lbenson

Senior Member
bitbang Nokia 5110 LCD with 14M2 and 20M2 20X2

I modified (simplified) matherp's code for controlling the Nokia 5110 LCD module with HSPI to make it work with bitbanging on the 14M2 (and removed all his cool text formatting and bar graphing code).

I realized that if I rearranged the pin definitions in the program, the 5110 would directly plug into an 14M2 single-inline-pin PCB I had made.

Here's the SIP board and module plugged in. The 14sip pcb is entirely concealed by the LCD.

14M2-Nokia5110-LCD.jpg

The code is attached. Module sold here ($2.26US): http://www.ebay.com/itm/New-84-48-LCD-Module-Blue-Backlight-Adapter-PCB-for-Nokia-5110-Arduino-SCW-/221907963298?hash=item33aabecda2:g:1NUAAOSwT5tWHMxT

Matherp's post is here: http://www.picaxeforum.co.uk/showthread.php?25360-Nokia-5110-revisited

My Eagle 14sip board design is here: http://www.picaxeforum.co.uk/showthread.php?25538-08M2-and-14M2-SIP-boards-with-Eagle-PCB-files

I didn't connect the "backlight" leds (which aren't backlighting, and don't help much to my mind). Note that the contrast setting is critical, and depends on the particular module you use. I soldered a right-angle header on the underside of the board to give access to C.0-C.3, and another for power. B.0 is available for sertxd and any other use.

This effectively makes for an 08M2 with display module. The same pin types and number of pins are available--B.0 as output, C.3 as input, C.0, C.1, and C.2 as input/output. More I/Os would be available with a 20M2.
 

Attachments

Last edited:

lbenson

Senior Member
Reserved for the results of 20sip_LCD1.brd testing (in several weeks when the boards get back from Oshpark).
 

lbenson

Senior Member
I never got back to that 20sip_LCD1.brd 22 months ago. When I did, I wanted a DS3231 module as well as the LCD, and that didn't work with the LCD on port B, so I switched it to port C.

20LCD_RTC_Eagle.jpg

20LCD_RTC_2.jpg

The add-on modules stack nicely, with the DS3231 fitting above the 20M2, and the Nokia 5110 LCD fitting on top of that (I had female headers with long legs to elevate the LCD--normal female headers wouldn't work.

I modified the code so that by setting or commenting out the "#define M2" line either a 20M2 or a 20X2 would work. The 20X2 would of course be faster if you used HSPI, but the pins conflict with I2C. As before, the code follows matherp, hippy, and srnet.
 

lbenson

Senior Member
As before, I used Oshpark to have the boards made--$7.40 for 3.

20LCD_Nokia5110.jpg

nokia5110_DS3231.jpg

The LCD is available here for $2.28 U.S.: https://www.ebay.com/itm/LCD-Display-Module-Adapter-PCB-with-Blue-Back-Light-for-Nokia-5110-3310-bhee2s/323038223415

The red version with two sets of identical connectors will work, but you have to make sure you plug it in the right way. The backlight only works with the jumper next to the header for the LCD. The 180R, if it is installed, must go on the bottom and must be soldered first before the 20-pin socket covers the through holes. Note that unless things have changed, the "3V-5V" on the blue board is untrue--use 3V only--5V fried it in my experience two years ago.

The DS3231 for $1.25 U.S.: https://www.ebay.com/itm/1pc-DS3231-Precision-RTC-Module-Memory-Module-for-Arduino-Raspberry-Pi/251544821678
 
Last edited:

lbenson

Senior Member
The Eagle CAD schematic files are attached. Remove the ".txt" file extension to get the ".sch" and ".brd" files.

The ".brd" file can be sent directly to Oshpark. Turnaround was 14 days.
 

Attachments

Last edited:

lbenson

Senior Member
The basic file is too big for a post. Here it is zipped.

The current time from the RTC is updated every minute on the first line of the LCD. The time power was applied is shown on the third line.

I have used the program for timing how long a UPS lasts with various things attached, and how long a 12V battery lasts. If B.2 is high when the program starts, the program monitors that for going low, and if it does, the time that occured is shown on the 5th line. I tried to put the battery voltage on the 6th line, but something I did causes the LCD to shut off when I call that, so I omitted it--a problem for future attention.

The LCD and the RTC are both powered from PICAXE pins--C.0 for 0V and C.1 for 3V. Not setting those upon initialization will cause the RTC to not work. Control of the sequence for applying power to the LCD is required upon startup, so it can't just be connected to the board power.

Downward pointing header pins on the B port would allow B.0, B.1, B.3, B.4, and B.6 to be used. C.6 is not brought out.

The resistors, 10K, 22K, 4K7, and 4K7 are 1/6 watt, and the 4K7 ones are vertically mounted.
 

Attachments

Last edited:

Spouky

New member
bitbang Nokia 5110 LCD with 14M2 and 20M2 20X2

I modified (simplified) matherp's code for controlling the Nokia 5110 LCD module with HSPI to make it work with bitbanging on the 14M2 (and removed all his cool text formatting and bar graphing code).

I realized that if I rearranged the pin definitions in the program, the 5110 would directly plug into an 14M2 single-inline-pin PCB I had made.

Here's the SIP board and module plugged in. The 14sip pcb is entirely concealed by the LCD.

View attachment 19467

The code is attached. Module sold here ($2.26US): http://www.ebay.com/itm/New-84-48-LCD-Module-Blue-Backlight-Adapter-PCB-for-Nokia-5110-Arduino-SCW-/221907963298?hash=item33aabecda2:g:1NUAAOSwT5tWHMxT

Matherp's post is here: http://www.picaxeforum.co.uk/showthread.php?25360-Nokia-5110-revisited

My Eagle 14sip board design is here: http://www.picaxeforum.co.uk/showthread.php?25538-08M2-and-14M2-SIP-boards-with-Eagle-PCB-files

I didn't connect the "backlight" leds (which aren't backlighting, and don't help much to my mind). Note that the contrast setting is critical, and depends on the particular module you use. I soldered a right-angle header on the underside of the board to give access to C.0-C.3, and another for power. B.0 is available for sertxd and any other use.

This effectively makes for an 08M2 with display module. The same pin types and number of pins are available--B.0 as output, C.3 as input, C.0, C.1, and C.2 as input/output. More I/Os would be available with a 20M2.
*****************************
For PICAXE 18M2 I just changed C4 to C2, and I put a variable resistor to connect Nokia BKL pin (backlight) to negative. My Nokia screen version requires 4.5 volt, voltage might vary according to the store you buy it.
 
Top