Stand alone dRO

More
03 Nov 2012 15:43 #26222 by bigfefi
Stand alone dRO was created by bigfefi
Hi all!
I'd like to create a stand-alone DRO, with some function like the "real" ones.
But... I don't understand a thing or two... :P
Is possible to create a stand alone GUI (without launch Axis or touchy ot others ) that manage encoder
and do some calculation using Gladevcp?
I don't' want to integrate in axes, but I'd like to make it indipendent...
I hope I explain...

Greetings

Please Log in or Create an account to join the conversation.

More
03 Nov 2012 19:14 #26223 by BigJohnT
Replied by BigJohnT on topic Stand alone dRO
Sure you can do that with just HAL and GladeVCP. I have some tutorials on my web site about creating different things like that.

gnipsel.com/

John

Please Log in or Create an account to join the conversation.

More
04 Nov 2012 04:20 #26246 by andypugh
Replied by andypugh on topic Stand alone dRO

Is possible to create a stand alone GUI (without launch Axis or touchy ot others ) that manage encoder
and do some calculation using Gladevcp?


Yes.

My approach (there are others) would be to write a HAL file to load the required HAL components (like encoder counters) and to launch the GUI.
You can then load RTAPI and the HAL file with

halrun -I -f yourhalfile.hal

This could be wrapped up in a file (made executable) containing

#! /bin/bash
halrun -I -f yourhalfile.hal

Your HAL file would, at a minimum need

loadrt threads name1=servo-thread period1=1000000 name2=base-thread period2=50000
loadrt encoder count=3
addf encoder.0.update-counters base-thread
addf encoder.1.update-counters base-thread
addf encoder.2.update-counters base-thread
addf encoder.0.capture-position servo-thread
addf encoder.1.capture-position servo-thread
addf encoder.2.capture-position servo-thread

loadusr (Typical GladeVCP startup stuffs)
net x-pos encoder.0.position gladevcp.display.0
net y-pos encoder.0.position gladevcp.display.1
net z-pos encoder.0.position gladevcp.display.2

start

The only unusual things about this HAL file are that it needs to load threads, and it needs to start the threads.

Typical DRO features like zeroing counts and entering the actual position could be handled in either HAL or GladeVCP Python (setting arbitrary position would be pretty painful in just HAL, but not impossible)

Please Log in or Create an account to join the conversation.

More
08 Nov 2012 21:01 #26375 by bigfefi
Replied by bigfefi on topic Stand alone dRO
Hi again.
I was trying BigJohn tutorial (part3, install your own gui).
I'm running everythings on a virtual machine, with win7 as host.
I have two problem
1) When I launch the gui the HAL GREMLIN component hang-up the system, so I have to reboot. If I cancel gremlin from the glade file, the gui run right.
2) I have installed the gui (gui3.glade), made the modification, but when I try to launch it I obtain this...
Print file information:
Warning: Spoiler!

Please Log in or Create an account to join the conversation.

More
08 Nov 2012 23:34 #26382 by PCW
Replied by PCW on topic Stand alone dRO
I dont think you can run real time configs in a virtual environment
I would try a 'sim' environment/kernel for a virtual machine

Please Log in or Create an account to join the conversation.

More
12 Nov 2012 16:21 #26474 by bigfefi
Replied by bigfefi on topic Stand alone dRO
That's right.
In fact I installed sim version and it runs.
After that I find that HAL GREMLIN crash the system, maybe due to opengl conflict, even if xlgears works.
So I have to use glade touchy instead, for example.
At home, with a real system, I was able to create my "personal" panel with 1 axes DRO.
Now I have to understand how to "create" the DTG function like in the Axis's DRO tab, where destination will be define by the DRO function that you are using.
Is possible to integrate a touch in the DRO system to zero the axis?

Please Log in or Create an account to join the conversation.

More
14 Nov 2012 20:40 #26579 by bigfefi
Replied by bigfefi on topic Stand alone dRO
i'm trying BigJohn tutorial .
I have modified a little the GUI part, and adapt the file to mym files names.
but when I launch it I get this error

Can not find -sec MOT -var MOT -num 1
Can not find -sec IO -var IO -num 1
Can not find -sec LINUXCNC -var NML_FILE -num 1
Can not find -sec EMC -var NML_FILE -num 1
7403
PID TTY STAT TIME COMMAND
7421
PID TTY STAT TIME COMMAND
Stopping realtime threads
Unloading hal components


What could be the problem?

Please Log in or Create an account to join the conversation.

More
14 Nov 2012 22:50 #26583 by BigJohnT
Replied by BigJohnT on topic Stand alone dRO
Did you copy the file to the installed location?

John

Please Log in or Create an account to join the conversation.

More
15 Nov 2012 07:06 #26597 by bigfefi
Replied by bigfefi on topic Stand alone dRO
Yes.
At the end I follow step by step the tutorial, using the file I've downloaded from the site...
I used also sudo cp ...
Could be that the problem is I'm using sim linuxcnc with e sim configuration?

Please Log in or Create an account to join the conversation.

More
15 Nov 2012 07:37 #26598 by BigJohnT
Replied by BigJohnT on topic Stand alone dRO
Yes that could be a problem... I've never ran the tutorials on a sim or a virtual machine.

John

Please Log in or Create an account to join the conversation.

Moderators: HansU
Time to create page: 0.090 seconds
Powered by Kunena Forum