- 博客(9)
- 资源 (1)
- 收藏
- 关注
原创 minicom崩溃问题的解决
现象:启动某些开发板时,minicom会崩溃,提示信息是“minicom: ../iconv/loop.c:4 30: internal_utf8_loop_single: Assertion `inptr - bytebuf > (state->__count & 7) failed"。分析原因:应该是minicom的语言设置有问题。解决办法:在PC的终端输入"export LC_AL
2009-02-25 09:46:00 884
原创 C语言编程如何获取SD卡的块大小
代码如下:#include #include #include static unsigned long get_BLKGETSIZE_sectors(int fd){ uint64_t v64; unsigned long longsectors; if (ioctl(fd, BLKGETSIZE64, &v64) == 0) { /* Go
2009-02-17 14:56:00 4976
原创 ubuntu下使用USB手柄
1, 安装手柄驱动:# modprobe joydev2. 安装手柄测试软件:# sudo apt-get install joystick3. 测试手柄:# jstest /dev/js0 或者 # jstest /dev/input/js0
2009-02-16 20:01:00 4480
原创 编程参考
The Linux Kernel API:http://docs.huihoo.com/gnu_linux/kernel-api/index.html Linux常用C函数(中文版):http://man.chinaunix.net/develop/c&c++/linux_c/default.htm C++ Reference:http://man.chinaunix.
2009-02-16 14:32:00 373
原创 如何使用proc文件系统让用户空间和内核空间进行交互
参考:http://www.ibm.com/developerworks/cn/linux/l-proc.html下面再给出一个proc系统中write_proc函数的例子:static int usb_power = 1;static int usb_proc_write(struct file* file, const char* buffer, unsigned long c
2009-02-16 08:43:00 795
原创 在Ubuntu上用zsnes玩SFC游戏
安装:apt-get install zsnes运行:zsens注意:必须以root用户身份运行,不然会出现“Could not set 512x448 video mode: Unable to open a console terminal”错误。 参考:http://muzuiget.blog.ubuntu.org.cn/archives/use-sfc-f如果没有声音,
2009-02-11 14:13:00 1143
原创 在Ubuntu上用mednafen玩GBA游戏
mednafen是一個多功能摸疑器, 支援gb, gba, nes, md等等, 可是沒有GUI界面. 不緊要, 能玩就好了.安装:sudo apt-get install mednafen运行:mednafen 文件路径注意:必须以root用户运行,不然会出现"Could not initialize SDL: Unable to open a console terminal."错
2009-02-11 13:58:00 3260
原创 在Ubuntu上用gfceu玩FC游戏
首先,安装gfceu,方法见http://linuxdesktop.cn/2007/06/22/gfceu-playe-fc-game.html。其次,还要让Ubuntu启动framebuffer,具体方法见http://forum.ubuntu.org.cn/viewtopic.php?t=89141。最后,必须以root用户运行程序,不然会出现“ [SDL] Unable to ope
2009-02-11 11:53:00 833
原创 ubuntu使用firefox听在线音乐
sudo apt-get install mplayer mozilla-mplayer 同时在firefox里安装了一个mediaWrap的plugin 如果还不行的话,sudo apt-get remove totem-mozilla 我试过了,现在可以听www.1ting.com的音乐了。
2009-02-10 15:12:00 469
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人