lookaz
August 11, 2015, 2:09am
1
Hi
i was looking for how to display a special character on the LCD, then i found this topic :
The Arduino programming language Reference, organized into Functions, Variable and Constant, and Structure keywords.
i want to ask how can i get the declaration of other characters as he declared smiley as follow in his code:
i hope someone can help...thx
[byte smiley[8] = {
B00000,
B10001,
B00000,
B00000,
B10001,
B01110,
B00000,
};]
Paul_B
August 11, 2015, 3:21am
2
If you post it marked as "code", it is easier to visualise.
byte smiley[8] = {
B00000,
B10001,
B00000,
B00000,
B10001,
B01110,
B00000,
};
Just replicate it with cut-and-paste and alter the 1s and 0s to produce your pattern.
lookaz
August 11, 2015, 3:50am
3
done, i'm actually new for using the forum, whatever thank
i hope next reply contains an answer
Paul_B
August 11, 2015, 10:37am
4
I'm not sure what further information you need.
MAS3
August 11, 2015, 8:46pm
5
Have another look at that.
The ones are a dot, the zeros are a blank.
byte smileySad[8] = {
B00000,
B10001,
B00000,
B00000,
B01110,
B10001,
B00000,
};
That's a different smiley.
This is your canvas, a 8x5 bit array.
(Zeros do not get printed on the display, only where there is a 1)
byte smileySad[8] = {
B00000,
B10001,
B00000,
B00000,
B01110,
B10001,
B00000,
};
You can make whatever you want but you can only have a total of 8 special characters, so keep this in mind.
Also making one, displaying it then making another using the same address, does not allow you to keep the old one on screen. This is because you are not using the arduino's memory to save these characters, you are using the display's internal memory. So even if you draw a character on screen then move the cursor and write over it with another character, the old one will change too.
lookaz
August 12, 2015, 1:16am
7
actually what i need to know is the 8x5 bit array representation of other special characters so that i can use different special character with my LCD
Paul_B
August 12, 2015, 2:38am
8
And that is what has been explained to you - how to draw the character into the array.
lookaz
August 13, 2015, 4:47am
9
i understood, sry my english is not good enough i was keep trying to understand, whatever i got it .. thx