随笔分类 - linux驱动
S3C2440
摘要:学了那么多程序语言,总是有一个Hello world开头,不禁感叹Hello world的强大。linux嵌入式也不例外、、、(1)linux开源当然少不了源代码的贡献#include <linux/init.h>#include <linux/module.h>MODULE_LICENSE("Dual BSD/GPL");static int hello_init(void){ printk(KERN_ALERT "Hello,world\n"); return 0;}static void hello_exit(void){
阅读全文
摘要:在mini2440中LED链接线使用引脚GPB5~8外接4个LED,操作方法是:1)引脚功能设为输出。2)要点亮LED,令引脚输出为0.3)要熄灭LED,令引脚输出为1.好了下边,给出详细的源码注释:#include <linux/module.h>#include <linux/kernel.h>#include <linux/fs.h>#include <linux/init.h>#include <linux/delay.h>#include <asm/irq.h>#include <mach/regs-gpi
阅读全文

浙公网安备 33010602011771号