[Lcdproc] FW: [PATCH] spanish "ntilde" in HD44780 driver charmap
David Lopez Perez
eldavidillo at hotmail.com
Sun Dec 6 13:29:53 UTC 2009
Hello list,
Some time ago, I submitted a patch for lcdproc 0.5.2 to replace three mappings in the default hd44780 charmap with more suitable glyphs. They were:
-the micro symbol (Greek character 'µ')
-the lowercase ntilde (Spanish character 'ñ')
-the uppercase ntilde (Spanish character 'Ñ')
I just tried 0.5.3 and I'm glad to see the mapping for the micro symbol was updated.
However, the issue with the spanish ntilde still stands; it's being mapped as a standard 'n'.
The 'ñ' is a very common letter in Spanish, Portuguese and Galician; the 'n' is not the same and it just wasn't good enough for me ;D so I made another patch for 0.5.3. This time I added a separate mapping in hd44780-charmap.h instead of modifying the default charmap. I'm attaching it here.
--- hd44780-charmap.h-original 2009-12-06 13:00:38.000000000 +0100
+++ hd44780-charmap.h 2009-12-06 13:56:37.000000000 +0100
@@ -241,6 +241,59 @@
175, 151, 163, 150, 129, 121, 32, 253
};
+/*
+ * HD44780 charset with spanish 'ñ' (ntilde)
+ *
+ * Over the default charmap, the following translations
+ * are being performed:
+ * - map lowercase 'ñ' (ntilde) to the corresponding character
+ * - map uppercase 'Ñ' (ntilde) to the same character as above
+ *
+ */
+
+const unsigned char HD44780_spa_charmap[] = {
+ /* #0 */
+ 0, 1, 2, 3, 4, 5, 6, 7,
+ 8, 9, 10, 11, 12, 13, 14, 15,
+ 16, 17, 18, 19, 20, 21, 22, 23,
+ 24, 25, 26, 27, 28, 29, 30, 31,
+ /* #32 */
+ 32, 33, 34, 35, 36, 37, 38, 39,
+ 40, 41, 42, 43, 44, 45, 46, 47,
+ 48, 49, 50, 51, 52, 53, 54, 55,
+ 56, 57, 58, 59, 60, 61, 62, 63,
+ /* #64 */
+ 64, 65, 66, 67, 68, 69, 70, 71,
+ 72, 73, 74, 75, 76, 77, 78, 79,
+ 80, 81, 82, 83, 84, 85, 86, 87,
+ 88, 89, 90, 91, 47, 93, 94, 95,
+ /* #96 */
+ 96, 97, 98, 99, 100, 101, 102, 103,
+ 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 116, 117, 118, 119,
+ 120, 121, 122, 123, 124, 125, 126, 127,
+ /* #128 */
+ 128, 129, 130, 131, 132, 133, 134, 135,
+ 136, 137, 138, 139, 140, 141, 142, 143,
+ 144, 145, 146, 147, 148, 149, 150, 151,
+ 152, 153, 154, 155, 156, 157, 158, 159,
+ /* #160 */
+ 160, 33, 236, 237, 164, 92, 124, 167,
+ 34, 169, 170, 171, 172, 173, 174, 175,
+ 223, 177, 178, 179, 39, 228, 247, 165,
+ 44, 185, 186, 187, 188, 189, 190, 63,
+ /* #192 */
+ 65, 65, 65, 65, 225, 65, 65, 67,
+ 69, 69, 69, 69, 73, 73, 73, 73,
+ 68, 238, 79, 79, 79, 79, 239, 120,
+ 48, 85, 85, 85, 245, 89, 240, 226,
+ /* #224 */
+ 97, 97, 97, 97, 225, 97, 97, 99,
+ 101, 101, 101, 101, 105, 105, 105, 105,
+ 111, 238, 111, 111, 111, 111, 239, 253,
+ 48, 117, 117, 117, 245, 121, 240, 255
+};
+
#define MAX_CHARMAP_NAME_LENGTH 16
struct charmap {
@@ -251,6 +304,7 @@
const struct charmap available_charmaps[] = {
{ "hd44780_default", HD44780_charmap },
{ "hd44780_euro", HD44780_euro_charmap },
+ { "hd44780_spanish", HD44780_spa_charmap },
{ "ea_ks0073", EA_KS0073_charmap },
{ "sed1278f_0b", SED1278F_0B_charmap }
};
_________________________________________________________________
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.omnipotent.net/pipermail/lcdproc/attachments/20091206/9cb54589/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hd44780-charmap.patch
Type: text/x-patch
Size: 2615 bytes
Desc: not available
URL: <http://lists.omnipotent.net/pipermail/lcdproc/attachments/20091206/9cb54589/attachment-0001.bin>
More information about the LCDproc
mailing list