NEWS
LinuxCNC 2.5.2 Release
There are no translations available.

LinuxCNC 2.5.2 Update Released (changelog).
 
LinuxCNC 2.5.1 Release
There are no translations available.

LinuxCNC 2.5.1 Update Released (changelog). If the Package Manager does not prompt you to upgrade see this page.

 
LinuxCNC 2.5.0 Release
There are no translations available.

New major release (changelog). See the instructions to update your system from EMC 2.4 to LinuxCNC 2.5.
 
Home Forum Configuring LinuxCNC HAL Components the problem of using "comp"

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: the problem of using "comp"

the problem of using "comp" 13 Mai 2012 05:46 #20049

I have a problem of using the "comp"

I create a file "ddt.comp" in my Desktop ,and put the simple example into it.The code is below:

component ddt "Compute the derivative of the input function";
pin in float in;
pin out float out;
variable float old;
function _;
license "GPLv2 or later";
;;
float tmp = in;
out = (tmp - old) / fperiod;
old = tmp;

But I failed.Some words of the errors is below:
include/linux/mmzone.h:18:26 error: linux/bounds.h:No such file or directory
include/linux/mmzone.h:300:error:'MAX_NR_ZONES' undeclared here (not in a function)

I search in internet and find that some people using linux (not linuxcnc ,just linux ) face the problem too.I use the codes as they said:
#cd /usr/src/linux-headers-2.6.32-122
#make prepare
then I use the code:
#cd /home/awesomepanda/Desktop
#comp --install ddt.comp
I failed again and the same errors appear.

I can use "comp ddt.comp" to produce the .c file ,but I cann't use "comp --compile ddt.comp" and "comp --install ddt.comp"




The version of linuxcnc that I am using is 2.4.3. So I think I should call it "emc2".

Then I do this "sudo apt-get install emc2-dev".
The result turns out :
Get:1 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:2 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:3 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:4 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:5 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:6 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:7 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:8 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:9 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:10 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:11 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:12 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:13 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
Get:14 www.linuxcnc.org/emc2/ lucid/emc2.4 emc2 1:2.4.7 [14.2MB]
...

I wait for a long time .Nothing special happens.The only changed thing is the number behind "Get:"

Is anything wrong with my net?



Sorry to thouble you guys again and again.But those "simple problems" really let me down.

Any words are appreciated to post to me.

Best Regards!
The administrator has disabled public write access.

Re:the problem of using "comp" 13 Mai 2012 06:28 #20051

  • BigJohnT
  • BigJohnT's Avatar
  • OFFLINE
  • Administrator
  • Posts: 5080
  • Thank you received: 102
  • Karma: 136
If you have dev installed and this only applies to LinuxCNC not to Linux.

linuxcnc.org/docview/html/hal/comp.html#_compiling

If you don't have dev installed then

linuxcnc.org/docview/html/hal/comp.html#_installing

Of course this is for 2.5 and I have no idea what works still for outdated versions of EMC.

A document search seems to get the most relative hits to LinuxCNC vs a google search unless you use the site search function.

John
Last Edit: 13 Mai 2012 06:33 by BigJohnT.
The administrator has disabled public write access.

Re:the problem of using "comp" 13 Mai 2012 09:02 #20055

  • ArcEye
  • ArcEye's Avatar
  • OFFLINE
  • Moderator
  • Posts: 1418
  • Thank you received: 114
  • Karma: 130
Hi
I wait for a long time .Nothing special happens.The only changed thing is the number behind "Get:"
Is anything wrong with my net?
www.linuxcnc.org/emc2/ does not exist any more, that is why you can't download 2.4.7 like that

The easiest thing for you to do would probably be to follow the instructions and upgrade to 2.5 and install the dev package for that too.

This entails you changing the entries in /etc/apt/sources.list to reflect the new path after branding changes, thereafter package upgrade downloads will work.

You should then have a dev package and headers etc which match
Check you have linux-headers-2.6.32-122-rtai as well as 2.6.32-122, albeit most of the files in the former are links to the latter.

The other package you need, which you probably already have, is build-essentials

regards
The administrator has disabled public write access.

Re:the problem of using "comp" 13 Mai 2012 12:07 #20059

  • BigJohnT
  • BigJohnT's Avatar
  • OFFLINE
  • Administrator
  • Posts: 5080
  • Thank you received: 102
  • Karma: 136
Although for 2.4.x I just verified that sudo apt-get install emc2-dev should still work...

John
The administrator has disabled public write access.

Re:the problem of using "comp" 13 Mai 2012 17:30 #20065

Thank you for replying my problem so enthusiastically!

I cann't use "#comp --install ddt.comp " to create the component ddt. I think the reason may be that I have not install emc2-dev. So I try to install it.

However,I think for a while.Athough I failed to use "#comp --install ddt.comp ",I think the reason is not that I cann't install emc2-dev.

Is there a way to solve this?It's not convenient for me to update to the newest version.




By the way ,Big John said " sudo apt-get install emc2-dev " still works ,But I failed again ,maybe that I install linuxcnc in the VMware Workstation.


Best Regards!
The administrator has disabled public write access.

Re:the problem of using 14 Mai 2012 02:47 #20071

  • andypugh
  • andypugh's Avatar
  • OFFLINE
  • Moderator
  • Posts: 4244
  • Thank you received: 152
  • Karma: 130
awesomepanda wrote:
I failed again ,maybe that I install linuxcnc in the VMware Workstation.

That can't be the whole problem, as I have installed and used comp with no problems under VMware.

It is possible that your VM has something odd about its internet connection, though. I think that the failure to install emc-dev is the problem, it should nly need to get the file once.

You could try getting it through the software centre (GUI) rather than with apt at the command line.
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Time to create page: 1.511 seconds
Powered by Kunena Forum
© 2013 LinuxCNC.org
Joomla! is Free Software released under the GNU General Public License.