上一页 1 ··· 38 39 40 41 42 43 44 45 46 ··· 78 下一页
摘要: 最近接触到一个很有意思的问题,如何在Windows控制台下画图,翻遍了C的头文件也没找到画图的函数,好吧,那就用Windows提供的API函数吧,看来想移植是没戏了。先画一个简单的图,类似心电图那种吧,假设得到的数据是纵坐标的值,横坐标默认从0开始,每隔512uS(微秒的那个符号不会打)得到一个纵坐... 阅读全文
posted @ 2014-04-29 14:44 毛毛虫的薄刻 阅读(169) 评论(0) 推荐(0) 编辑
摘要: 从Vista开始,想阻止系统关机就开始变麻烦了,不能只拦截WM_QUERYENDSESSION了,操作系统只给一个应用程序两秒钟的时间去保存自己的东西,两秒钟之后,不管做完了没有,Game Over!可是如果你正在刻录一张光盘呢?两秒钟是都不够的,所以Vista之后也给提供了一种方式阻止系统关机,就... 阅读全文
posted @ 2014-04-29 14:43 毛毛虫的薄刻 阅读(276) 评论(0) 推荐(0) 编辑
摘要: /* *vxworks 串口测试 ** zjx at evoc 2007.5.17*pippo add rs485 串口测试at evoc 2007,12,21**pippo add 文件系统测试at evoc 2007,12,21**使用方法:*1. comrecv ttynum,rate (tt... 阅读全文
posted @ 2014-04-22 14:15 毛毛虫的薄刻 阅读(526) 评论(0) 推荐(0) 编辑
摘要: 使用串口下载vxworks映象的方法由于坛子里这方面的可行性文章比较少,不时有一些网友在询问这方面的问题,再加上通过这种方法可以调试网络驱动,所以我花了一点时间把整个下载过程试了一下。1.配置config.h文件 a.修改DEFAULT_BOOT_LINE为tsfs(target server fi... 阅读全文
posted @ 2014-04-22 08:51 毛毛虫的薄刻 阅读(293) 评论(0) 推荐(0) 编辑
摘要: #include #include int main() {for(int i = 0; i < 3; i ++) { int pid = fork(); if(pid == 0) { printf("child\n"); } else { printf(... 阅读全文
posted @ 2014-03-28 18:43 毛毛虫的薄刻 阅读(141) 评论(0) 推荐(0) 编辑
摘要: 本文针对Award公司开发的计算机系统BIOS提出了一种嵌入应用程序的方法,其基本原理对别的品牌的BIOS也一样适用,仅需稍加修改。文中作者给出并讨论一个完整的例子程序,该程序已经通过实验验证。正文一.BIOS简述这里所讲的BIOS是指计算机主板上的BIOS,是整个计算机的关键和灵魂,计算机一启动就... 阅读全文
posted @ 2014-03-25 08:33 毛毛虫的薄刻 阅读(247) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include #include //mmap#include "hifb.h"#include "sample_c... 阅读全文
posted @ 2014-03-22 10:43 毛毛虫的薄刻 阅读(383) 评论(0) 推荐(0) 编辑
摘要: //测试maoprintf("\n\n"); unsigned int cmd=1; unsigned long arg =4;fd = open("/dev/sil9024", O_RDWR);if (fd < 0) { printf("open sil9024 fail\n"); }else{p... 阅读全文
posted @ 2014-03-21 16:22 毛毛虫的薄刻 阅读(199) 评论(0) 推荐(0) 编辑
摘要: printk是在内核中运行的向控制台输出显示的函数,Linux内核首先在内核空间分配一个静态缓冲区,作为显示用的空间,然后调用sprintf,格式化显示字符串,最后调用tty_write向终端进行信息的显示。printk与printf的差异,是什么导致一个运行在内核态而另一个运行用户态?其实这两个函... 阅读全文
posted @ 2014-03-21 09:42 毛毛虫的薄刻 阅读(115) 评论(0) 推荐(0) 编辑
摘要: kernel 2.6.35 及之前的版本中struct file_operations 一共有3个ioctl :ioctl,unlocked_ioctl和compat_ioctl现在只有unlocked_ioctl和compat_ioctl 了在kernel 2.6.36 中已经完全删除了struc... 阅读全文
posted @ 2014-03-20 09:32 毛毛虫的薄刻 阅读(238) 评论(0) 推荐(0) 编辑
上一页 1 ··· 38 39 40 41 42 43 44 45 46 ··· 78 下一页