[solved] HAL pin indicating state of G91/G90
- Aciera
- Topic Author
- Offline
- Administrator
Less
More
- Posts: 4025
- Thank you received: 1734
23 Jul 2021 13:37 #215688
by Aciera
HAL pin indicating state of G91/G90 was created by Aciera
Does anybody know if there is a hal pin that indicates the state of G90/G91 mode?
I'd like to have the state indicated on my machine panel.
I'd like to have the state indicated on my machine panel.
Please Log in or Create an account to join the conversation.
- rodw
- Away
- Platinum Member
Less
More
- Posts: 10805
- Thank you received: 3559
23 Jul 2021 13:57 #215691
by rodw
Replied by rodw on topic HAL pin indicating state of G91/G90
- #<_absolute> - Return 1 if G90 is on, else 0.
- #<_incremental> - Return 1 if G91 is on, else 0.
Ref: linuxcnc.org/docs/html/gcode/overview.html
The following user(s) said Thank You: Aciera
Please Log in or Create an account to join the conversation.
- cmorley
- Offline
- Moderator
Less
More
- Posts: 7778
- Thank you received: 2075
23 Jul 2021 18:24 #215709
by cmorley
Replied by cmorley on topic HAL pin indicating state of G91/G90
What version of linuxcnc are you using?
Please Log in or Create an account to join the conversation.
- Aciera
- Topic Author
- Offline
- Administrator
Less
More
- Posts: 4025
- Thank you received: 1734
24 Jul 2021 07:23 #215744
by Aciera
Replied by Aciera on topic HAL pin indicating state of G91/G90
I'm using current master.
Please Log in or Create an account to join the conversation.
- Aciera
- Topic Author
- Offline
- Administrator
Less
More
- Posts: 4025
- Thank you received: 1734
24 Jul 2021 07:54 - 24 Jul 2021 09:52 #215748
by Aciera
Replied by Aciera on topic [solved] HAL pin indicating state of G91/G90
So my approach would be to create a python (or C) component to get the parameters mapped to hal-pins but I can't get my head around on how to access the paramters:
#<_absolute>
#<_incremental>
Does anybody have an example to get me started?
[edit]
I guess I could parse the contents of the linuxcnc.stat object?
linuxcnc.org/docs/html/config/python-interface.html
Or I think this is better:
linuxcnc.org/docs/html/gui/GStat.html
Ok this one doesn't seem to report back when G90/G91 changes.
[edit2]
I solved this by using linuxcnc.stat
#<_absolute>
#<_incremental>
Does anybody have an example to get me started?
[edit]
I guess I could parse the contents of the linuxcnc.stat object?
linuxcnc.org/docs/html/config/python-interface.html
Or I think this is better:
linuxcnc.org/docs/html/gui/GStat.html
Ok this one doesn't seem to report back when G90/G91 changes.
[edit2]
I solved this by using linuxcnc.stat
Last edit: 24 Jul 2021 09:52 by Aciera.
The following user(s) said Thank You: phillc54
Please Log in or Create an account to join the conversation.
- cmorley
- Offline
- Moderator
Less
More
- Posts: 7778
- Thank you received: 2075
24 Jul 2021 16:37 #215790
by cmorley
Replied by cmorley on topic [solved] HAL pin indicating state of G91/G90
I will add g90/91 to Gstat - for the future.
Please Log in or Create an account to join the conversation.
Time to create page: 0.055 seconds