Nokia 5110 gLCD
Nokia 5110 gLCD
Probably a easier way to do this, but I only have the home edition of Flowcode and I like a challenge. I have ported a .asm program I found to do a "Hello world!" message and small graphic to Flowcode. If anybody is interested in continuing on with my work, here is the .fcf file. The processor used is a PIC 16F1937. I do not know of an easy way to split up the bits from a byte so I sent the byte to port d and read each bit into a variable in order to get and set individual bytes. As far as I know the communication uses SPI. As I have stated on my other posts, I am an amateur when it comes to Flowcode, .asm, and C. Any constructive criticism, suggestions and comments are welcome.
EDITED - old file deleted. New version available. See other post.
EDITED - old file deleted. New version available. See other post.
Last edited by opieflus on Mon Dec 31, 2012 9:06 am, edited 1 time in total.
Nokia 5110 gLCD finally ported for Flowcode!
I have just finished porting a Nokia 5110 gLCD to work with Flowcode. All normal characters are available. No graphics yet. This program is a very custom job because Flowcode does not support this gLCD as of yet that I am aware of.
The functions are used via normal macro routines instead of Flowcodes built-in macro routines. As long as you do not go messing around with the macros, it should work just fine for you.
I have put on a small demo with a few timers and "Hello world!" message.
Have fun! And happy new year!
File edited/updated - Notations now included at top of file.
The functions are used via normal macro routines instead of Flowcodes built-in macro routines. As long as you do not go messing around with the macros, it should work just fine for you.
I have put on a small demo with a few timers and "Hello world!" message.
Have fun! And happy new year!
File edited/updated - Notations now included at top of file.
- Attachments
-
- Nokia 5110 gLCD.fcf
- (55.37 KiB) Downloaded 985 times
Re: Nokia 5110 gLCD
New update! Graphics are now included. Bitmap array, vertical and horizontal lines, and a scale are included. I no longer use the hacked led macro to get the defines and rom array in. All defines and rom array settings are in supplementary code section.
- Attachments
-
- Nokia 5110 with graphics.fcf
- (93.98 KiB) Downloaded 1103 times
-
- Posts: 7
- Joined: Wed Sep 18, 2013 11:15 pm
- Location: Argentina
- Has thanked: 2 times
- Been thanked: 1 time
Re: Nokia 5110 gLCD
Hello!
I have nokia 5110 screen and wanted to test your file.
When I try to compile I get many errors
. Flowcode V5.
What will be my problem of not being able to compile?
Thank you!!
I have nokia 5110 screen and wanted to test your file.
When I try to compile I get many errors

What will be my problem of not being able to compile?
Thank you!!
-
- Matrix Staff
- Posts: 9521
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
Re: Nokia 5110 gLCD
Hi fernandosartorelli,
What version of Flwocode V5 have you got?
I have V5.5.2.1 (30.01.2013) and compiles for me with no errors.
Can you attachfile so someone can spot whats gong on.
Martin
What version of Flwocode V5 have you got?
I have V5.5.2.1 (30.01.2013) and compiles for me with no errors.
Can you attach
Code: Select all
Nokia 5110 with graphics.msg.txt
Martin
Martin
-
- Posts: 7
- Joined: Wed Sep 18, 2013 11:15 pm
- Location: Argentina
- Has thanked: 2 times
- Been thanked: 1 time
Re: Nokia 5110 gLCD
Hello Martin!
Thanks for answering!
FC version is 5.1
Try to change case but nothing.
Thank you
Thanks for answering!
FC version is 5.1
Try to change case but nothing.
Thank you
Code: Select all
File name: E:\Alarmas\cosas\Nokia 5110\Nokia 5110 with graphics.c
Description:
Generated by: Flowcode v5.1.0.0
Date: Thursday, November 26, 2015 11:37:41
Iniciando el compilador…
C:\Program Files\Flowcode\v5\Tools\boostc\boostc_pic16_flowcode.exe -v -t PIC16F1937 "Nokia 5110 with graphics.c"
BoostC Optimizing C Compiler Version 7.04 (for PIC16 architecture)
http://www.sourceboost.com
Copyright(C) 2004-2011 Pavel Baranov
Copyright(C) 2004-2011 David Hobday
Nokia 5110 with graphics.c
Starting preprocessor: C:\PROGRA~1\Flowcode\v5\Tools\boostc\pp.exe "Nokia 5110 with graphics.c" -i C:\PROGRA~1\Flowcode\v5\Tools\boostc\include -d _PIC16F1937 -la -c2 -o "Nokia 5110 with graphics.pp" -v -d _BOOSTC -d _PIC16 -d _PIC16x -d _CHAR_INDEX
.......
Nokia 5110 with graphics.c(1085:6): error: unknown identifier 'FCL_COMMAND'
Nokia 5110 with graphics.c(1085:6): error: invalid operand 'FCL_COMMAND'
Nokia 5110 with graphics.c(1085:18): error: failed to generate expression
Nokia 5110 with graphics.c(1092:6): error: unknown identifier 'FCL_LCDOUT'
Nokia 5110 with graphics.c(1092:6): error: invalid operand 'FCL_LCDOUT'
Nokia 5110 with graphics.c(1092:17): error: failed to generate expression
Nokia 5110 with graphics.c(1104:2): error: unknown identifier 'FCL_LCDOUT'
Nokia 5110 with graphics.c(1104:2): error: invalid operand 'FCL_LCDOUT'
Nokia 5110 with graphics.c(1104:13): error: failed to generate expression
Nokia 5110 with graphics.c(1143:24): error: unknown identifier 'FCL_X_POSITION_0TO83'
Nokia 5110 with graphics.c(1143:24): error: invalid operand 'FCL_X_POSITION_0TO83'
Nokia 5110 with graphics.c(1143:22): error: failed to generate expression
Nokia 5110 with graphics.c(1143:14): error: arguments of 'FCM_SendByte' don't match the parameters of call
Nokia 5110 with graphics.c(1143:2): error: failed to generate expression
Nokia 5110 with graphics.c(1144:24): error: unknown identifier 'FCL_Y_POSITION_0TO5'
Nokia 5110 with graphics.c(1144:24): error: invalid operand 'FCL_Y_POSITION_0TO5'
Nokia 5110 with graphics.c(1144:22): error: failed to generate expression
Nokia 5110 with graphics.c(1144:14): error: arguments of 'FCM_SendByte' don't match the parameters of call
Nokia 5110 with graphics.c(1144:2): error: failed to generate expression
Nokia 5110 with graphics.c(1155:11): error: unknown identifier 'PFCL_STRING'
Nokia 5110 with graphics.c(1155:9): error: arguments of 2 overloads of 'strlen8' don't match the parameters of call
Nokia 5110 with graphics.c(1155:2): error: failed to generate expression
Nokia 5110 with graphics.c(1155:2): error: invalid operand 'strlen8( PFCL_STRING )
# 1155
'
Nokia 5110 with graphics.c(1155:13): error: failed to generate expression
Nokia 5110 with graphics.c(1160:13): warning: local variable 'length_Str' may be used uninitialized
Nokia 5110 with graphics.c(1163:14): error: unknown identifier 'PFCL_STRING'
Nokia 5110 with graphics.c(1163:14): error: invalid operand 'PFCL_STRING'
Nokia 5110 with graphics.c(1163:26): error: failed to generate expression
Nokia 5110 with graphics.c(1163:12): error: invalid operand '*(PFCL_STRING + i) '
Nokia 5110 with graphics.c(1163:31): error: failed to generate expression
Nokia 5110 with graphics.c(1163:31): error: invalid operand '- '
Nokia 5110 with graphics.c(1163:10): error: failed to generate expression
Nokia 5110 with graphics.c(1167:6): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1169:14): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1172:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1174:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1177:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1179:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1182:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1184:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1187:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1189:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1192:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1194:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1197:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1199:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1202:11): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1204:15): warning: local variable 'pos_Str' may be used uninitialized
Nokia 5110 with graphics.c(1221:25): error: unknown identifier 'FCL_X_POSITION'
Nokia 5110 with graphics.c(1221:25): error: invalid operand 'FCL_X_POSITION'
Nokia 5110 with graphics.c(1221:23): error: failed to generate expression
Nokia 5110 with graphics.c(1221:14): error: arguments of 'FCM_SendByte' don't match the parameters of call
Nokia 5110 with graphics.c(1221:2): error: failed to generate expression
Nokia 5110 with graphics.c(1222:25): error: unknown identifier 'FCL_Y_POSITION'
Nokia 5110 with graphics.c(1222:25): error: invalid operand 'FCL_Y_POSITION'
Nokia 5110 with graphics.c(1222:23): error: failed to generate expression
Nokia 5110 with graphics.c(1222:14): error: arguments of 'FCM_SendByte' don't match the parameters of call
Nokia 5110 with graphics.c(1222:2): error: failed to generate expression
Nokia 5110 with graphics.c(1240:6): error: unknown identifier 'FCL_BITMAP_NUMBER'
Nokia 5110 with graphics.c(1240:6): error: invalid operand 'FCL_BITMAP_NUMBER'
Nokia 5110 with graphics.c(1240:24): error: failed to generate expression
Nokia 5110 with graphics.c(1256:6): error: unknown identifier 'FCL_BITMAP_NUMBER'
Nokia 5110 with graphics.c(1256:6): error: invalid operand 'FCL_BITMAP_NUMBER'
Nokia 5110 with graphics.c(1256:24): error: failed to generate expression
Nokia 5110 with graphics.c(1293:6): error: unknown identifier 'PFCL_X_OR_Y_LINE'
Nokia 5110 with graphics.c(1293:6): error: invalid operand 'PFCL_X_OR_Y_LINE'
Nokia 5110 with graphics.c(1293:23): error: failed to generate expression
Nokia 5110 with graphics.c(1302:6): error: unknown identifier 'PFCL_X_OR_Y_LINE'
Nokia 5110 with graphics.c(1302:6): error: invalid operand 'PFCL_X_OR_Y_LINE'
Nokia 5110 with graphics.c(1302:23): error: failed to generate expression
Nokia 5110 with graphics.c(1323:14): error: unknown identifier 'FCL_X_START'
Nokia 5110 with graphics.c(1323:13): error: arguments of 'FCM_Goto_XY' don't match the parameters of call
Nokia 5110 with graphics.c(1323:2): error: failed to generate expression
Nokia 5110 with graphics.c(1325:6): error: unknown identifier 'FCL_SCALE_INPUT'
Nokia 5110 with graphics.c(1325:6): error: invalid operand 'FCL_SCALE_INPUT'
Nokia 5110 with graphics.c(1325:22): error: failed to generate expression
Nokia 5110 with graphics.c(1328:11): error: unknown identifier 'FCL_X_START'
Nokia 5110 with graphics.c(1328:11): error: invalid operand 'FCL_X_START'
Nokia 5110 with graphics.c(1328:9): error: failed to generate expression
Nokia 5110 with graphics.c(1328:9): internal error: failed to generate 'for' expression
Nokia 5110 with graphics.c(1328:2): error: error in 'for' loop statement
Nokia 5110 with graphics.c(1331:11): error: unknown identifier 'FCL_SCALE_INPUT'
Nokia 5110 with graphics.c(1331:11): error: invalid operand 'FCL_SCALE_INPUT'
Nokia 5110 with graphics.c(1331:9): error: failed to generate expression
Nokia 5110 with graphics.c(1331:9): internal error: failed to generate 'for' expression
Nokia 5110 with graphics.c(1331:2): error: error in 'for' loop statement
Nokia 5110 with graphics.c success
failure
Código de retorno = 1
Flowcode no pudo compilar el código C del diagrama de flujo por los siguientes errores:
Si su diagrama de flujo contiene código C, revíselo cuidadosamente. Si su diagrama de flujo no contiene código C o si ya ha revisado el código C, contactese con Soporte Técnico.
FINALIZADO
-
- Valued Contributor
- Posts: 2045
- Joined: Wed Aug 27, 2008 10:31 pm
- Location: Netherlands
- Has thanked: 553 times
- Been thanked: 1081 times
Re: Nokia 5110 gLCD
That is a very old version. I would suggest you update to V5.5.2.1.fernandosartorelli wrote:FC version is 5.1
“Integrity is doing the right thing, even when no one is watching.”
― C.S. Lewis
― C.S. Lewis
-
- Valued Contributor
- Posts: 2045
- Joined: Wed Aug 27, 2008 10:31 pm
- Location: Netherlands
- Has thanked: 553 times
- Been thanked: 1081 times
Re: Nokia 5110 gLCD
This is not a library, Flowcode 5 does not support libraries. It is a flowchart you should be able to open (make sure to select Flowcode for PIC files in the bottom right corner of the open window).
“Integrity is doing the right thing, even when no one is watching.”
― C.S. Lewis
― C.S. Lewis