Hi

We solve the QT keyboard problem making some changes on the file kbdpc101_qws.cpp:


static const QWSKeyMap pc101KeyM[] = {
....

{   Qt::Key_J,      'j'     , 'J'     , '4'  },
{   Qt::Key_K,     'k'     , 'K'     , '5'  },
{   Qt::Key_L,      'l'     , 'L'     , '6'  },
{   Qt::Key_U,     'u'     , 'U'     , '7'  },
{   Qt::Key_I,       'i'     , 'I'     , '8'  },
{   Qt::Key_O,      'o'     , 'O'     , '9'  },
{   Qt::Key_Equal,      '='     , '+'     , '3'  },
{   Qt::Key_N,      'n'     , 'N'     , '1'  },
{   Qt::Key_M,      'm'     , 'M'     , '2'  },  // 50
{   Qt::Key_Slash,      '/'     , '?'     , '0'  },
}

The struct QWSKeymap is defined in as:

struct QWSKeyMap {
    uint key_code;
    ushort unicode;
    ushort shift_unicode;
    ushort ctrl_unicode;
};

Best Regards


Carlos



On Wed, Dec 9, 2009 at 8:37 AM, Carlos Camargo <cicamargoba@gmail.com> wrote:
Hi Xiangfu

I'm reading the file qkbdpc101_qws.cpp, but I think that the page suggested by you don't fix the problem, because this is not a layout problem; In this file:

 Qt::Key_1,      '1'     , '!'     , 0xffff  },

and Key_1 is defined in:  qnamespace.h as:

        Key_1 = 0x31,
        Key_Shift = 0x01000020,                // modifiers
        Key_Control = 0x01000021,
        Key_Meta = 0x01000022,
        Key_Alt = 0x01000023,
        Key_CapsLock = 0x01000024,
        Key_NumLock = 0x01000025,
        Key_ScrollLock = 0x01000026,


Carlos


On Mon, Dec 7, 2009 at 6:42 PM, Carlos Camargo <cicamargoba@gmail.com> wrote:
Thanks Xiangfu

I'll check it

Carlos


On Sat, Dec 5, 2009 at 5:35 AM, Xiangfu Liu <xiangfu@qi-hardware.com> wrote:
Hi Carlos
I found some info[1] may some help:
----
QT/Embedded (version 3.x) when used with the standard pc keyboard on linux reads the scancodes directly
from the tty device and thus has no knowledge of any keyboard maps that have been loaded for the linux console.
The following patch provides a function into the keyboard devices of QT/Embedded which lets you assign a new scancode conversion table.
[1]http://llg.cubic.org/patches/qtegerman.html

Carlos Camargo wrote:
> Hi Xiangfu
>
> On terminal all works fine, but doesn't works on QT
>


--
Xiangfu Liu
Email: xiangfu at qi-hardware dot com
Web: http://www.qi-hardware.com

_______________________________________________
Qi Developer Mailing List
Mail to list (members only): developer@lists.qi-hardware.com
Subscribe or Unsubscribe: http://lists.qi-hardware.com/cgi-bin/mailman/listinfo/developer



--
Carlos Iván Camargo Bareño
Profesor Asistente
Departamento de Ingeniería Eléctrica y Electrónica
Universidad Nacional de Colombia
cicamargoba@unal.edu.co



--
Carlos Iván Camargo Bareño
Profesor Asistente
Departamento de Ingeniería Eléctrica y Electrónica
Universidad Nacional de Colombia
cicamargoba@unal.edu.co



--
Carlos Iván Camargo Bareño
Profesor Asistente
Departamento de Ingeniería Eléctrica y Electrónica
Universidad Nacional de Colombia
cicamargoba@unal.edu.co