HD44780: Add a charmap which makes input in KOI8-R appear correctly on

displays using hd44780 controller with european charset.
This commit is contained in:
mmdolze
2010-01-28 19:25:17 +00:00
parent 1f513ae997
commit 88aabdccc1
4 changed files with 63 additions and 6 deletions
+1
View File
@@ -22,6 +22,7 @@ v.0.5dev (ongoing development)
* hd44780: Exclude pin for switchable backlight from keypad scanning * hd44780: Exclude pin for switchable backlight from keypad scanning
* server core: New network input buffering * server core: New network input buffering
* hd44780: Extended subdriver API and performance improvement for lcd2usb * hd44780: Extended subdriver API and performance improvement for lcd2usb
* hd44780: Add KOI8-R character mapping (Yura Scheglyuk)
v0.5.3 v0.5.3
+ lcdexec: notification when called program finishes + lcdexec: notification when called program finishes
+1 -1
View File
@@ -480,7 +480,7 @@ Size=20x4
# Character map to to map ISO-8859-1 to the LCD's character set # Character map to to map ISO-8859-1 to the LCD's character set
# [default: hd44780_default; legal: hd44780_default, hd44780_euro, # [default: hd44780_default; legal: hd44780_default, hd44780_euro,
# ea_ks0073, sed1278f_0b ] # ea_ks0073, sed1278f_0b, hd44780_koi8_r ]
CharMap=hd44780_default CharMap=hd44780_default
# If your display is slow and cannot keep up with the flow of data from # If your display is slow and cannot keep up with the flow of data from
+7 -1
View File
@@ -2820,6 +2820,7 @@ This can be done by specifying <option>--enable-drivers=all</option> or by inclu
<parameter><literal>hd44780_euro</literal></parameter> | <parameter><literal>hd44780_euro</literal></parameter> |
<parameter><literal>ea_ks0073</literal></parameter> | <parameter><literal>ea_ks0073</literal></parameter> |
<parameter><literal>sed12780f_0b</literal></parameter> | <parameter><literal>sed12780f_0b</literal></parameter> |
<parameter><literal>hd44780_koi8_r</literal></parameter> |
<parameter><literal>none</literal></parameter> <parameter><literal>none</literal></parameter>
} }
</term> </term>
@@ -2843,6 +2844,11 @@ This can be done by specifying <option>--enable-drivers=all</option> or by inclu
<listitem><para> <listitem><para>
<literal>sed12780f_0b</literal> is for some SED 1278 displays. <literal>sed12780f_0b</literal> is for some SED 1278 displays.
</para></listitem> </para></listitem>
<listitem><para>
<literal>hd44780_koi8_r</literal> maps input from a client in
Russian KOI8-R to displays with a ROM mask supporting the european
charset (ROM code A02).
</para></listitem>
<listitem><para> <listitem><para>
The <literal>none</literal> charmap does not translate any characters. The <literal>none</literal> charmap does not translate any characters.
It displays the characters the display controllers actually has It displays the characters the display controllers actually has
@@ -2851,7 +2857,7 @@ This can be done by specifying <option>--enable-drivers=all</option> or by inclu
</para></listitem> </para></listitem>
</itemizedlist> </itemizedlist>
You only need to set this parameter if you have a non-standard You only need to set this parameter if you have a non-standard
HD44780 display. HD44780 display or charmap.
<tip> <tip>
<para> <para>
+50
View File
@@ -282,6 +282,55 @@ const unsigned char SED1278F_0B_charmap[] = {
175, 151, 163, 150, 129, 121, 32, 253 175, 151, 163, 150, 129, 121, 32, 253
}; };
/*
* Table for HD44780 controller with ROM mask supporting
* the european charset (ROM code A02).
*
* Russian KOI8-R codepage as input, comments in KOI8-R.
*/
const unsigned char HD44780_KOI8R_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, 92, 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 */
45, 124, 43, 43, 43, 43, 43, 43,
43, 43, 43, 32, 32, 32, 32, 32,
32, 32, 32, 32, 183, 183, 32, 126,
28, 29, 32, 32, 176, 178, 183, 247,
/* #160 */
45, 124, 43, 203, 43, 43, 43, 43, /* ё */
43, 43, 43, 43, 43, 43, 43, 43,
43, 43, 43, 203, 43, 43, 43, 43, /* Ё */
43, 43, 43, 43, 43, 43, 43, 169,
/* #192 */
172, 65, 128, 137, 129, 69, 216, 146, /* ю а б ц д е ф г */
88, 132, 133, 75, 134, 77, 72, 79, /* х и й к л м н о */
135, 173, 80, 67, 84, 136, 130, 66, /* п я р с т у ж в */
98, 142, 131, 139, 143, 140, 138, 141, /* ь ы з ш э щ ч ъ */
/* #224 */
172, 65, 128, 137, 129, 69, 216, 146, /* Ю А Б Ц Д Е Ф Г */
88, 132, 133, 75, 134, 77, 72, 79, /* Х И Й К Л М Н О */
135, 173, 80, 67, 84, 136, 130, 66, /* П Я Р С Т У Ж В */
98, 142, 131, 139, 143, 140, 138, 141 /* Ь Ы З Ш Э Щ Ч Ъ */
};
#define MAX_CHARMAP_NAME_LENGTH 16 #define MAX_CHARMAP_NAME_LENGTH 16
struct charmap { struct charmap {
@@ -293,6 +342,7 @@ const struct charmap available_charmaps[] = {
{ "none", none_charmap }, { "none", none_charmap },
{ "hd44780_default", HD44780_charmap }, { "hd44780_default", HD44780_charmap },
{ "hd44780_euro", HD44780_euro_charmap }, { "hd44780_euro", HD44780_euro_charmap },
{ "hd44780_koi8_r", HD44780_KOI8R_charmap},
{ "ea_ks0073", EA_KS0073_charmap }, { "ea_ks0073", EA_KS0073_charmap },
{ "sed1278f_0b", SED1278F_0B_charmap } { "sed1278f_0b", SED1278F_0B_charmap }
}; };