- LinuxCNC
- General LinuxCNC Questions
- Interrogating LinuxCNC for realtime information (position, etc.)
Interrogating LinuxCNC for realtime information (position, etc.)
- ericm
- Offline
- New Member
Less
More
- Posts: 2
- Thank you received: 0
30 Apr 2018 23:04 #109875
by ericm
Interrogating LinuxCNC for realtime information (position, etc.) was created by ericm
What's the best way to get realtime information about position, velocity, program line number, etc. from LinuxCNC? I want to be able to take this data and send it to another server for display on an operational dashboard. I've been poking around and it seems like there are a ton of ways to do this, but I'm not sure what would be the best. In this case, "best" is a combination of easiest, least likely to break in the future, and that puts the least load on the processor.
Thanks in advance!
Thanks in advance!
Please Log in or Create an account to join the conversation.
- bevins
- Offline
- Platinum Member
Less
More
- Posts: 1937
- Thank you received: 335
02 May 2018 15:03 #110026
by bevins
Replied by bevins on topic Interrogating LinuxCNC for realtime information (position, etc.)
Please Log in or Create an account to join the conversation.
- andypugh
- Offline
- Moderator
Less
More
- Posts: 23178
- Thank you received: 4866
09 May 2018 11:53 #110423
by andypugh
One very easy way is to ssh in to the LinuxCNC machine and "halcmd loadusr halmeter".
I do that quite often, typically to monitor motion.program-line to see when the machine is finished or waiting for a (manual) tool change.
You can look at any HAL pin this way, and can open mutliple instances of halmeter.
A very similar way would be to create a custom Glade panel with pins that link to the HAL pins of interest, and then to load that in a remote X session on the other machine (halcmd loadusr gladevcp mypanel...).
I think that you could relatively easily have the Glade panel link its own pins, but there is also the option of having it poll linuxnc_stat
linuxcnc.org/docs/2.7/html/config/python...ding_linuxcnc_status
Or your remote widget could send linuxcncrsh commands and parse the return values:
linuxcnc.org/docs/2.7/html/man/man1/linuxcncrsh.1.html
As you say, there are lots of ways to do this. Halmeter is the least work. (because it is no work)
Replied by andypugh on topic Interrogating LinuxCNC for realtime information (position, etc.)
What's the best way to get realtime information about position, velocity, program line number, etc. from LinuxCNC? I want to be able to take this data and send it to another server for display on an operational dashboard. I've been poking around and it seems like there are a ton of ways to do this, but I'm not sure what would be the best.
One very easy way is to ssh in to the LinuxCNC machine and "halcmd loadusr halmeter".
I do that quite often, typically to monitor motion.program-line to see when the machine is finished or waiting for a (manual) tool change.
You can look at any HAL pin this way, and can open mutliple instances of halmeter.
A very similar way would be to create a custom Glade panel with pins that link to the HAL pins of interest, and then to load that in a remote X session on the other machine (halcmd loadusr gladevcp mypanel...).
I think that you could relatively easily have the Glade panel link its own pins, but there is also the option of having it poll linuxnc_stat
linuxcnc.org/docs/2.7/html/config/python...ding_linuxcnc_status
Or your remote widget could send linuxcncrsh commands and parse the return values:
linuxcnc.org/docs/2.7/html/man/man1/linuxcncrsh.1.html
As you say, there are lots of ways to do this. Halmeter is the least work. (because it is no work)
The following user(s) said Thank You: ericm
Please Log in or Create an account to join the conversation.
- ericm
- Offline
- New Member
Less
More
- Posts: 2
- Thank you received: 0
11 May 2018 02:07 #110557
by ericm
Replied by ericm on topic Interrogating LinuxCNC for realtime information (position, etc.)
Thanks! That's exactly the info was looking for.
Cheers,
Eric
Cheers,
Eric
Please Log in or Create an account to join the conversation.
- LinuxCNC
- General LinuxCNC Questions
- Interrogating LinuxCNC for realtime information (position, etc.)
Time to create page: 0.064 seconds