4DSP Support Forum

Products => Board Support Package (Installation, Licensing, ...) => Topic started by: Fabrics13 on June 20, 2014, 02:40 AM

Title: Installing 4fm driver using linux
Post by: Fabrics13 on June 20, 2014, 02:40 AM
Hi
 
I am currently trying to install the 4fm driver in linux. I have followed the 4FM Linux getting started guide and I successfully extracted the driver package. However when I type make, make can't find the /lib/modules/3.2.0 -4-amd64/build directory. I had a look at the makefile and this is the directory it is pointing at. If i look in the /lib/modules/3.2.0 -4-amd64/ directory there is no build folder or file. I tried removing build reference in the makefile and the file modules cannot be found. I had a quick look for this file but couldn't find it..... How can I resolve this.
 
Cheers,
Dave
Title: Re: Installing 4fm driver using linux
Post by: arnaudNL on June 20, 2014, 04:31 AM
Dear David,


These issues are common in the Linux world unfortunately. This is why 4DSP decided to only supported a small set of distribution and kernel versions. Here is a list of the distros we are supporting:


- Debian using kernel 2.6.33.7 and up.
- Redhat/CentOS 5.0 (kernel 2.6.18).
- Ubuntu 12.04 LTS (3.11.x).


It might be possible to compile the BSP on other distributions/kernels but it might be time consuming, spending a lot of time on google in order to find a solution.


The easiest results will be obtained by using one of the distribution we are supporting!


Best Regards,
Arnaud
Title: Re: Installing 4fm driver using linux
Post by: tonyku on June 20, 2014, 01:16 PM

Have you installed linux-headers-* (your verison of kernel)???

You'll need to install that package and it *should* create that diretory.


Title: Re: Installing 4fm driver using linux
Post by: Fabrics13 on June 22, 2014, 10:05 PM
Arnaud,
 
I am using Debian kernal version 3.2.57-3.
 
Tonyku,
 
I installed a number of programming and build packages, but I hadn't installed linux headers. After installing linux headers the problem was solved.
 
Thankyou both for your advice,
David
 
Title: Re: Installing 4fm driver using linux
Post by: Fabrics13 on June 23, 2014, 02:30 AM
Hi again,
 
I installed the driver. I only got a warning "You may need to install module-init-tools", however module-init-tools was already installed. When I ran modprobe 4fm i got an error "FATAL: Module 4fm not connected".
 
For your reference, I have the VP780 with an FMC126 module and all of the CPLD LEDs are off at power on.
 
Also the udev.rules file does not exsist in the etc/udev/rules.d folder.
 
Regards,
David
 
 
 
Title: Re: Installing 4fm driver using linux
Post by: arnaudNL on June 23, 2014, 04:31 AM
David,


Linux development is something different than Windows where you have to search a lot of information on the internet.


The error you get is that your kernel cannot use the driver for a reason or another or does not know that path to it.


Can you confirm you sent a depmod -a command in the shell prior to run modprobe?


As far as udev, this is changing between distributions, same comments check that on Google for detailed pointer for your given distribution; the name is generally decorated with number for priorities, etc..


I really hope that helps..


Arnaud















Title: Re: Installing 4fm driver using linux
Post by: tonyku on June 23, 2014, 04:49 PM
If udev.rules file does not exist then you need to create the files.

On the installation for the kernel module - i assume you install it with root?  (i.e. sudo make install)   

You'll need to do some of these commands:

sudo insmod 4fm.ko
sudo depmod -a
sudo modprobe 4fm

At this point it should show in the console whether it detected any devices.   the FATAL message is typically if you run it without root permissions.

If you choose not to create udev.rules, you can still run the applications but the application wlil need to run as root.


Title: Re: Installing 4fm driver using linux
Post by: arnaudNL on June 26, 2014, 05:44 AM
David,

Anything you need answered more on that topic? I will be closing the topic tomorrow without extra feedbacks!

Thanks,
Arnaud
Title: Re: Installing 4fm driver using linux
Post by: arnaudNL on June 27, 2014, 07:03 AM
This topic is being closed because the issue is considered as resolved by 4DSP. Feel free to create a new topic for any further inquiries.