Chinaunix首页 | 论坛 | 博客
  • 博客访问: 3518302
  • 博文数量: 864
  • 博客积分: 14125
  • 博客等级: 上将
  • 技术积分: 10634
  • 用 户 组: 普通用户
  • 注册时间: 2007-07-27 16:53
个人简介

https://github.com/zytc2009/BigTeam_learning

文章分类

全部博文(864)

文章存档

2023年(1)

2021年(1)

2019年(3)

2018年(1)

2017年(10)

2015年(3)

2014年(8)

2013年(3)

2012年(69)

2011年(103)

2010年(357)

2009年(283)

2008年(22)

分类: LINUX

2009-08-03 09:36:25

First, down load Qt version 3.1.2 from the Trolltech web site.

Then apply this patch to the Qt source code and use the following commands on your PC to build Qt:

export QTDIR=`pwd`
./configure -embedded arm -qt-mouse-linuxtp -DQT_QWS_ADS
gmake

Put the 'lib' directory on your board (a conventient way to do this is with NFS, alternatively, you could use a jffs or cramfs on the on-board flash memory).

To run a Qt program on your board, use the following commands (assuming that the lib directory is in /nfs/qt/lib):

export QTDIR=/nfs/qt
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$QTDIR/lib
export QWS_MOUSE_PROTO=linuxtp

For a PS2 mouse the last line should be changed to:

export QWS_MOUSE_PROTO=IntelliMouse

For a serial mouse:

export QWS_MOUSE_PROTO=Microsoft

To run the example in $QTDIR/examples/widgets:

./widgets -qws

Here is a calibration program (adapted from Opie) that you can use to calibrate the touch screen. This program saves the calibration parameters in the file /etc/pointercal.

 For a USB mouse, use:

      export QWS_MOUSE_PROTO=IntelliMouse


and replace /dev/psaux with a link to /dev/input/mice, i.e.

      cd /dev
      rm psaux
      ln -s input/mice psaux


Qt will see the USB mouse as a PS2 mouse.

To configure the kernel to support USB mice, be sure the following are enabled in your kernel configuration:

      CONFIG_INPUT=y
      CONFIG_INPUT_MOUSEDEV=y
      CONFIG_USB_HID=y
      CONFIG_USB_HIDINPUT=y

http://blog.sina.com.cn/s/blog_48d63030010002i4.html

阅读(962) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~