一片冰心在玉壶

那时我们有梦,关于文学,关于爱情,关于穿越世界的旅行, 如今我们深夜饮酒,杯子碰到一起,都是梦破碎的声音. 交往都是初逢,爱情都在心里,往事都在梦中, 希望都带着注释,信仰都带着呻吟. 总有善意的光逃避现世的繁琐而寻找片刻的安宁, 也许,就是你凝视这里的眼睛

博客园 首页 联系 订阅 管理
上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 18 下一页

2013年8月17日 #

摘要: PC104,Xlinux下,突然发现串口3,4不能用。。。以为是硬件的问题,换成wince后,3,4工作正常,排除电路问题在linux下查看dmesg:serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550Aserial8250: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550Aserial8250: ttyS2 at I/O 0x3e8 (irq = 4) is a 16550Aserial8250: ttyS3 at I/O 0x2e8 (irq = 3) is a 16550A很明显设置有问题,查看BIOS, 阅读全文
posted @ 2013-08-17 15:55 Sankye 阅读(5297) 评论(0) 推荐(0)

2013年7月27日 #

摘要: int speaker(unsigned int freq,unsigned int delay){ static int flag=0,bit; if(flag==0) { flag=1; iopl(3); } outb(0xb6,0x43); outb((freq & 0xff),0x42); outb((freq >> 8),0x42); bit=inb(0x61); outb(3 | bit,0x61); usleep(10000*delay); outb(0xfc | bit,0x61);}voi... 阅读全文
posted @ 2013-07-27 14:32 Sankye 阅读(426) 评论(0) 推荐(0)

2013年7月26日 #

摘要: X86 pc104 tslib 嵌入式linux usb触摸 驱动 阅读全文
posted @ 2013-07-26 16:05 Sankye 阅读(1764) 评论(0) 推荐(0)

2013年6月24日 #

摘要: (一)1.首先将字体(我选择windows下的宋体simsun.ttf)copy至qte的lib/font目录下2.设置环境变量export QT_QWS_FONTDIR=/mnt/nfs/qte-arm/lib/fonts/3.在函数里指定字体 eg:测试例程 1#include2#include3#include4#include5#include6#include7#include8intmain(intargc,char*argv[])9{10 QApplication app(argc,argv);11// app.setFont(QFont("simsun")) 阅读全文
posted @ 2013-06-24 19:55 Sankye 阅读(17952) 评论(1) 推荐(0)

2013年6月7日 #

摘要: 在WINCE下,控制背光的方法很多,在驱动程序里控制最常见,这里在应用程序里控制。要实现的功能如下:1 触摸屏一段时间内没有输入信息,背光关闭2 点击触摸屏,背光打开用到一个头文件#include "pwinuser.h"这个文件下载在这里:http://files.cnblogs.com/sankye/mousehook.rar安装钩子:EVENTMSG msg = {HC_ACTION};g_hHook = QASetWindowsJournalHook(WH_JOURNALRECORD, MouseProc, &msg);鼠标钩子函数:int iTimeCou 阅读全文
posted @ 2013-06-07 16:08 Sankye 阅读(275) 评论(0) 推荐(0)

2013年6月1日 #

摘要: 必须记下了,每次都会忘1 下载tslib-1.3:2 解压安装生成configure,这里比一般的开源项目少做一步,要先运行解压目录下的脚本 ./autogen.sh./configure --prefix=/home/tslib-1.3/build --enable-inputapi=no我在运行的时候总出现ts_open:Inappropriate ioctol for device错误,后来我干脆把程序里的宏USE_INPUT_API相关的都删除了,就好了。。3 拷贝build目录下的文件到目标板上,我的是X86,/tslib下4配置环境变量export TSLIB_TSDEVICE=/ 阅读全文
posted @ 2013-06-01 17:09 Sankye 阅读(746) 评论(0) 推荐(0)

2013年5月11日 #

摘要: 在EVC下的默认TAB控件很难看,本人自己画的,可以实现你想要的任何效果http://files.cnblogs.com/sankye/evc-tabctrl.rar 阅读全文
posted @ 2013-05-11 16:35 Sankye 阅读(290) 评论(0) 推荐(0)

2013年5月7日 #

摘要: BitButtonNL.cpp//////////////////////////////////////////////////////////////////////////////* * BitButtonNL.cpp : implementation file * * Author sankye zhang * 2013-5-07 *//////////////////////////////////////////////////////////////////////////////#in... 阅读全文
posted @ 2013-05-07 14:51 Sankye 阅读(501) 评论(0) 推荐(0)

2013年3月26日 #

摘要: #include "stdafx.h"#include <stdio.h>#define PACKVALUE 4#pragma pack(push)#pragma pack(PACKVALUE) typedef struct{ char sa; double sb; int sc;} innerS; typedef struct{ int a; char b; short c; innerS d[2];} testS; #pragma pack(pop) typedef unsign... 阅读全文
posted @ 2013-03-26 11:45 Sankye 阅读(402) 评论(0) 推荐(0)

2013年2月28日 #

摘要: CDC *pDC=this->GetDC(); CRect rc(100,100,390,390); // GetClientRect( &rc ); int xStart = (rc.right+rc.left)/2; int yStart = (rc.bottom+rc.top)/2; CTime time = CTime::GetCurrentTime(); CString strDigits; int i,x,y; CSize size; CPen Pen(PS_SOLID,5,RGB(0,0,0)); CPe... 阅读全文
posted @ 2013-02-28 10:50 Sankye 阅读(334) 评论(0) 推荐(0)

上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 18 下一页