摘要: 1. static struct fasync_struct *button_async; 这里是建立一个fasync的结构体 此结构体将会被 kill_fasync(&button_async, SIGIO, POLL_IN); 调用。这个函数将会给APP程序发送信号。 2. fasync_hel 阅读全文
posted @ 2020-06-24 17:11 闲云潭影 阅读(216) 评论(0) 推荐(0) 编辑
摘要: 最近在学习一些利用selenium 做爬虫的知识 这里面来总结一下函数的清单 1. wd = webdriver.Chrome(r'd:\webdrivers\chromedriver.exe') 这里面是启动chrome控制器 2. wd.get('https://www.baidu.com') 阅读全文
posted @ 2020-06-19 07:47 闲云潭影 阅读(383) 评论(0) 推荐(0) 编辑
摘要: 请注意, linux的应用层对字符设备都是采取文件读写的方式,所以说我们的驱动程序也是用的是文件的形式。 我们需要把所有的驱动程序封装到文件的读写形式里面。 1、 static int XXX_open(struct inode *inode, struct file *file) //这个函数是挂 阅读全文
posted @ 2020-06-18 05:51 闲云潭影 阅读(221) 评论(0) 推荐(0) 编辑
摘要: You are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you nee 阅读全文
posted @ 2020-06-16 06:28 闲云潭影 阅读(75) 评论(0) 推荐(0) 编辑
摘要: The Fibonacci numbers, commonly denoted F(n) form a sequence, called the Fibonacci sequence, such that each number is the sum of the two preceding one 阅读全文
posted @ 2020-06-16 05:38 闲云潭影 阅读(81) 评论(0) 推荐(0) 编辑
摘要: Write a function that reverses a string. The input string is given as an array of characters char[]. Do not allocate extra space for another array, yo 阅读全文
posted @ 2020-06-16 04:49 闲云潭影 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 本文请参考如下链接: https://github.com/labuladong/fucking-algorithm/blob/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E7%B3%BB%E5%88%97/%E5%9B%9E%E6%BA%AF%E7%AE 阅读全文
posted @ 2020-06-11 07:58 闲云潭影 阅读(217) 评论(0) 推荐(0) 编辑
摘要: linux 内核写led的驱动如图所示: 按照图 的方式我们发现我们需要写两个部分 一个是APP,一个是底层的驱动。其中APP是通过C库和系统层最后调用到底层的驱动的。 linux系统首先会把底层驱动以文件的形式挂载到dev文件夹内,然后APP利用文件写或者读的方式对底层的代码进行操作。 所以程序会 阅读全文
posted @ 2020-06-07 07:22 闲云潭影 阅读(284) 评论(0) 推荐(0) 编辑
摘要: 本文转载自 http://blog.chinaunix.net/uid-30271883-id-5098514.html 新人到此,一开始都知道该说些什么。毕竟是第一次写博客!还是不说那么多废话了。开始进入主题了! 在学校只是写那些很短的代码,可能基本都不会用的上makefile,但是在一个大型的p 阅读全文
posted @ 2020-05-28 11:29 闲云潭影 阅读(942) 评论(0) 推荐(0) 编辑
摘要: S2C2440当上电的时候会自动的把nor 或者nandflash的前4k字节拷贝到自己的ram中,可是如果当整个程序大于4k的时候怎么办? 代码重定义的方针就是把nor 或者是nandflash里面的代码通通的拷贝到SDRAM中去,然后所有的程序会从SDRAM里面去运行。 首先是写出脚本文件其格式 阅读全文
posted @ 2020-05-24 08:27 闲云潭影 阅读(256) 评论(0) 推荐(0) 编辑