由买买提看人间百态

topics

全部话题 - 话题: xenomai
(共0页)
d*******o
发帖数: 5897
1
来自主题: Linux版 - 问个kernel module的编译问题
刚学内核模块编程不久,照着网上的Linux Kernel Module Programming学的。现在有
个问题,如果我的kernel source code要调用非linux kernel source的函数,应该怎
么做呢?比如我现在的目录结构是:
/usr/src/linux 放的是linux kernel source
/usr/src/xenomai 放的是一个第三方的kernel patch和source,上面的linux kernel
source已经被这个目录下的source patch过,

我自己要写的kernel module放在
/home/pcuser/mymodule下,就一个文件,mymod.c,init函数里调用了/usr/src/
xenomai的kernel space API。

通过加-I -L选项,我能编译mymod.c,得到mymod.ko。但是insmod mymod.ko时,报错
,说有Undefined symbol,就是这个第三方的函数。这个第三方的source code有自己
的Makefile,在它的顶层目录里make是可以... 阅读全帖
S*A
发帖数: 7142
2
来自主题: Linux版 - 问个kernel module的编译问题
You need to make sure your module is using the
the xenomai kernel as the Kbuild source kernel.
Also you need to make sure the symbol you used in
the xenomai kernel is exported as kernel symbols.
You can try to locate the symbol in /proc/kallsyms.
If it is not in there, then you need to export those symbol
in the kernel first before they can be used in the module.
x****o
发帖数: 21566
3
来自主题: Linux版 - 问个kernel module的编译问题
static library?
If so, make sure they all appear in Makefile
e.g, in Makefile
...
obj-m := foo.o
foo-objs := yourcode.o xenomai.a
...
google "kernel module static library" or something similar maybe
h******t
发帖数: 15
4
我没有coding的经验,最近做个机器人控制的项目,接了某公司的source code,在其
基础上要做一些改动实现某些功能。
看了source code以后有些问题想请教一下这里的牛人们。
这个公司的这个机械臂项目背景是这样:
他们做了一个机械臂,做好了硬件和基本控制软件。然后有些学校买了继续开发。
我已知的用到的软件工具有:C++,Linux系统, Xenomai(real time patch for Linux)
,CMake编译
一个我很好奇的问题是,他们的code就是自己写的,还是用什么工具生成的?
我怀疑至少他们用了某工具,比如UML,生成了代码的框架,因为
source code的每个文件开头都有以下说明:
// Project : RobotArm
// File : %name: xxxxx %
//
// Version : %version: 15 %
// Date : %date_modified: Tue Mar 21 17:26:41 2008 %
// By : %derived_by: nly05035 %
其中date_m
d*******o
发帖数: 5897
5
来自主题: Programming版 - (ZT) 怎样学习RTOS?
RTOS的工作基本都要公民绿卡吧
要是只做软件,下个xenomai patch下linux内核,然后就可以写程序了
(共0页)