Python stat toolinfo

  • JT
  • JT's Avatar Topic Author
  • Away
  • Administrator
  • Administrator
More
11 Oct 2024 17:21 #311820 by JT
Python stat toolinfo was created by JT
Following the directions in the docs for toolinfotoolinfo(toolno)(returns dict of tooldata for toolno) - An initial stat.poll() is required to initialize. toolno must be greater than zero and less than or equal to the highest tool number in use. Dictionary items include all tooldata items: toolno, pocketno, diameter,frontangle,backangle,orientation, xoffset,yoffset, … woffset, comment#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import linuxcnc
s = linuxcnc.stat()
s.poll()
toolno = 1
print(s.toolinfo(toolno))
>>> s.poll()
>>> toolno = 1
>>> print(s.toolinfo(toolno))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'linuxcnc.stat' object has no attribute 'toolinfo'

I'm running 2.9.2-64-abunchofletters

Anyone know when this was added?

JT
The following user(s) said Thank You: travis036

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

  • JT
  • JT's Avatar Topic Author
  • Away
  • Administrator
  • Administrator
More
11 Oct 2024 17:30 #311821 by JT
Replied by JT on topic Python stat toolinfo
Looks like it is only in master so having it in the 2.9 docs is an error.

JT
The following user(s) said Thank You: tommylight

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

More
11 Oct 2024 18:00 - 11 Oct 2024 18:12 #311825 by Aciera
Replied by Aciera on topic Python stat toolinfo
Looking at the python module documentation in the 2.9 source:
github.com/LinuxCNC/linuxcnc/blob/2.9/do...ython-interface.adoc
it seems that these sites are showing the documentation for master instead of 2.9:
linuxcnc.org/docs/stable/html/config/python-interface.html
linuxcnc.org/docs/2.9/html/config/python-interface.html

[edit]
I'll file this as an issue on github
github.com/LinuxCNC/linuxcnc/issues/3149
Last edit: 11 Oct 2024 18:12 by Aciera.
The following user(s) said Thank You: tommylight, JT

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

Time to create page: 0.093 seconds
Powered by Kunena Forum