Advanced Search

Search Results (Searched for: )

  • ts
  • ts
22 Aug 2025 12:59 - 23 Aug 2025 14:34
Replied by ts on topic Use of ODOT Ethercat coupler I/O?

Use of ODOT Ethercat coupler I/O?

Category: EtherCAT

Hi
Is your modules state PreOp or you switch them to OPstate?
Please could you share your xml files for linixcnc?
Ps working on the same task, try to connect odot 8033 with linixcnc 2.9.4 as i understood oncase of beckhoff each module - coupler, di, next on di, do, next one do, ai - each have own id in ethercat network. But as in case of odot, perhaps, only coupler have own address ethercat, other modules using special address register according position from the coupler.
  • Todd Zuercher
  • Todd Zuercher's Avatar
22 Aug 2025 10:58
Replied by Todd Zuercher on topic Displaying Active Work Coordinate System

Displaying Active Work Coordinate System

Category: GladeVCP

Well, not sure why but it isn't working.  I'm seeing several references to "object has no attribute 'stat'" in the terminal, the first 3 of which were there before adding this modification to the glade panel.   Any ideas what I'm doing wrong?

Here is what was printed to the terminal.
digital4@digital4:~/Desktop$ linuxcnc
LINUXCNC - 2.7.15-28-gd7ded6e
Machine configuration directory is '/home/digital4/linuxcnc/configs/Digital_4g'
Machine configuration file is 'double.ini'
Starting LinuxCNC...
.
Found file(REL): ./Digital_4w.hal
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 99, in _f
    return f(self, *a, **kw)
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 461, in on_activate
    ensure_mode(self.stat, self.linuxcnc, linuxcnc.MODE_MDI)
AttributeError: 'EMC_Action_MDI' object has no attribute 'stat'
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 99, in _f
    return f(self, *a, **kw)
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 461, in on_activate
    ensure_mode(self.stat, self.linuxcnc, linuxcnc.MODE_MDI)
AttributeError: 'EMC_Action_MDI' object has no attribute 'stat'
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 99, in _f
    return f(self, *a, **kw)
  File "/usr/lib/pymodules/python2.7/gladevcp/hal_actions.py", line 461, in on_activate
    ensure_mode(self.stat, self.linuxcnc, linuxcnc.MODE_MDI)
AttributeError: 'EMC_Action_MDI' object has no attribute 'stat'
/usr/bin/gladevcp:212: RuntimeWarning: missing handler 'on_window1_destroy'
  builder.connect_signals(handlers)
Xlib.protocol.request.QueryExtension
Xlib.protocol.request.QueryExtension
Traceback (most recent call last):
  File "./double.py", line 47, in periodic_check
    self.stat.poll()
AttributeError: HandlerClass instance has no attribute 'stat'
^Ctask: 105602 cycles, min=0.000034, max=0.022691, avg=0.010203, 0 latency excursions (> 10x expected cycle time of 0.010000s)
Traceback (most recent call last):
  File "/usr/bin/axis", line 3549, in <module>
    o.mainloop()
  File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1035, in mainloop
    self.tk.mainloop(n)
  File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1432, in __call__
    def __call__(self, *args):
KeyboardInterrupt
Shutting down and cleaning up LinuxCNC...
  • emresensoy
  • emresensoy
22 Aug 2025 09:49 - 22 Aug 2025 15:05
Türkçe was created by emresensoy

Türkçe

Category: Other Languages

Dear moderators, I would like to open a Turkish section. If you find it appropriate, I can also serve as a moderator for Turkish section.
  • rodw
  • rodw's Avatar
22 Aug 2025 05:58
Replied by rodw on topic Homing with 2 inputs/sensors?

Homing with 2 inputs/sensors?

Category: HAL

It might not be a trivial solution, but you could write a custom home component that takes the two pins as input. eg rough, then fine.
Ref: linuxcnc.org/docs/stable/html/man/man9/homecomp.9.html
Linuxcnc does this using home_latch_velocity eg fast sensing, then slow for accuraccy on the one pin.
  • hitchhiker
  • hitchhiker
22 Aug 2025 05:01
Replied by hitchhiker on topic Homing with 2 inputs/sensors?

Homing with 2 inputs/sensors?

Category: HAL

Hi
Thanks for answer.
Its openloop. I think the second sensor that wait for the metal pin on the pulley makes the homing more accurate.

Sensor 1 rough homing to a reference marked area.
Sensor 2 then fine homing.
Call it 2 state homing?

Original is the secomd sensor used for 2 things..
Thing 1 homing accurate..
Thing 2 counts the pin everytime the pulley is turned full.
The full rotation means as example 400 steps done.. is the pin triggering the sensor befor or later then its out of position.
But i only want to use the secomd sensor for more precise homing.

This is not possible right? To make it possible it needs a special component or?

i found this:

github.com/mydani/linuxcnc_misc/blob/mai...e_index_stepdir.comp

looks like inside linuxcnc there is no other option.

thanks
  • cmorley
  • cmorley
22 Aug 2025 01:28 - 22 Aug 2025 01:31
Replied by cmorley on topic Displaying Active Work Coordinate System

Displaying Active Work Coordinate System

Category: GladeVCP

I think you need to add a timer to call a function to read linuxcnc's stat.
Here is most of the odea - not tested:

# add this at top:
import gobject

#add this to to bottom of __init__ :
# called every 100 ms
gobject.timeout_add(100, self.periodic_check)
self.last = 1
self.convert = { 1:"G54(Front)", 2:"G55(Rear)", 3:"56", 4:"57", 5:"58", 6:"59", 7:"59.1", 8:"59.2", 9:"59.3"}

# add this function
def periodic_check(self):
    self.stat.poll()
    current =  self.stat.g5x_index
    if current != self.last:
        text = self.convert[int(current)]
        # update label
        self.builder.get_object('work_coord_label').set_text(text)
    self.last = current
    return True
  • PCW
  • PCW's Avatar
21 Aug 2025 21:13 - 21 Aug 2025 21:31
Replied by PCW on topic Homing with 2 inputs/sensors?

Homing with 2 inputs/sensors?

Category: HAL

You cannot connect an output pin to joint.N.index-enable
because joint.N.index-enable pins are bidirectional ("Tri-State")

When index is used for homing, LinuxCNC expects to use encoder
hardware to detect the actual index pin and signal that detection
to LinuxCNC via the joint.N.index-enable pin. joint.N.index-enable
is used as a bidirectional signal, that is, when LinuxCNC detects the
coarse home position, it then sets joint.N.index-enable true. This signals
the hardware to enable index detection. When the index is detected,
the hardware normally does two things: it clears (sets to false)
joint.N.index-enable (signaling LinuxCNC that the index has been detected)
and normally also zeros the position.

Does this joint have encoder feedback or it this an open-loop step/dir system?

If no encoder (and you have an up-to-date LinuxCNC installation) , there is firmware
that supports homing to index in open loop step/dir systems, so instead of connecting
a GPIO pin to joint.N.index-enable you would connect to hm2_7i92.0.stepgen.NN.index-enable
to joint.N.index-enable.




 
  • hitchhiker
  • hitchhiker
21 Aug 2025 20:23
Homing with 2 inputs/sensors? was created by hitchhiker

Homing with 2 inputs/sensors?

Category: HAL

Hi!

i have here a axis which has 2 home sensors.
The first sensor is the reference.
the second is a sensor on the pulley.

how it works? Home to first sensor.. then go back until sensor 2 is active.

i the first sensor works on linuxcnc..then i add the second..
net index-sensor gpio001.... 
inet index-sensor joint...index-enable

but then i get error.. 

cant add i/o pin to index... its already output pin hm2_7192.0.gpio.005.in

in the ini i change the parameter for use index as true.. but this doesnt solve anything.

do i need to add a encoder in the bitfile or what is my failure??

thanks
  • Martin.L
  • Martin.L
21 Aug 2025 17:49 - 21 Aug 2025 17:59
Replied by Martin.L on topic Carousel ATC setup on Probe Basic

Carousel ATC setup on Probe Basic

Category: QtPyVCP

Understanding this is not a quick answer I drop here an AI analysis of your sample atc_sim config. Maybe it can be a good starting point?
  • scsmith1451
  • scsmith1451's Avatar
21 Aug 2025 16:02
Replied by scsmith1451 on topic Set program zero using XY positioning laser

Set program zero using XY positioning laser

Category: Advanced Configuration

After several attempt to use the _ini() variables in my macro to move the table to the x/y offset location, I've finally just hard coded the values into the macro.  While this is not the ideal implementation, it does keep the values in a single location should I need to modify them in the future.

At this point I now have all of my gvcp buttons working except the combo box to select the current coordinate system to use for a given job.  I'll work on that option at a later date.  The key frustration is the inability to jog once the laser is toggled.

This is particularly interesting in that both the spindle enable and the spindle coolant are enabled via relays as well and neither of them inhibit jogging after they are activated. 

Does anyone have any suggestions regarding why the laser might inhibit jogging? 

These are the HAL commands associated with the laser:

# *** Crosshair laser Toggle and LED ***
net machine-is-on => gladevcp.crosshair-ctl-active
net crosshair-toggle-out <= gladevcp.crosshair-toggle
net crosshair-toggle-out => hm2_5i25.0.7i76.0.0.output-02
net crosshair-toggle-out => gladevcp.crosshair-led

I don't see anything that might be interfering with jogging.

Spindle-enable and coolant-flood, (I'm using M8 to cool my spindle), are configured as follows:
# --- SPINDLE-ENABLE ---
net spindle-enable  =>     hm2_5i25.0.7i76.0.0.output-00

# --- COOLANT-FLOOD ---
net coolant-flood  =>     hm2_5i25.0.7i76.0.0.output-01

The main difference that I notice is that these function are activated by LCNC signals. Maybe there is something associate with these two signals that needs to be added to the laser activation process.

I'm open to any suggestions that might point me in the right direction to resolve this issue.

Kind regard,
 
  • nathanb
  • nathanb
21 Aug 2025 15:48
Replied by nathanb on topic Raspberry Pi 5 with 7c81 WORKING!

Raspberry Pi 5 with 7c81 WORKING!

Category: Driver Boards

Hi, I also got my rpi5 and the 7c81 to run. First I had problems in the pncconf due to language settings. After this pncconf worked fine. Afterwards I had to change the hm2_spix in the created .hal
  • Todd Zuercher
  • Todd Zuercher's Avatar
21 Aug 2025 15:46
Displaying Active Work Coordinate System was created by Todd Zuercher

Displaying Active Work Coordinate System

Category: GladeVCP

I'm trying to modify a GladeVCP to have a label that displays the current active work coordinate system.  And to put it bluntly Python is kicking my butt.  So how exactly would one set up the python handler file to read the linuxcnc stat.g5x_index then use that to change the string that is displayed in the gtk label? 
In my  GladeVCP the label I want to use is named "work_coord_label" and I would like the label to read "G54(front)" when the G54 coordinate system is active, and "G55(Rear)" when G55 is active.  (The other coordinate systems can meerly read G56,G57... as there is no plan to use them at this point.)

PS.  This is on a machine running Linuxcnc ver 2.7.25 (And I don't think I can ugrade because this system requires a very low latency RTAI config that I don't think I can easily replicate with newer versions.)
  • Mars
  • Mars
21 Aug 2025 14:18
Replied by Mars on topic Adaptive Feed Rate HAL example?

Adaptive Feed Rate HAL example?

Category: HAL

Thanks for your discussion. A few minutes ago I got my simple concept breadboard running with adaptive feed so that I can throw a physical switch that is attached to a GPIO pin on the Rpi5 and the trajectory backs up. As is typical, once I got some of the basic ideas of the HAL programming (thanks A METRIC TON to swolebro and his excellent tutorials!), I has able to hack a HAL file together. I now need to think more about the system architecture which relates to your discussion. Am I missing something or does the linuxCNC documentation lack one key element that is critical for the newbie: there are precious few if any examples of HAL command syntax in the documentation...not the case for most languages. I think including a few examples per command would greatly lower the learning curve.
  • PCW
  • PCW's Avatar
21 Aug 2025 13:49 - 21 Aug 2025 13:50
Replied by PCW on topic Stop feed when spindle rpm lower

Stop feed when spindle rpm lower

Category: AXIS

This is normally what motion.spindle-at-speed is used for.
LinuxCNC checks motion.spindle-at-speed  after the
spindle speed has changed in the Gcode and pauses
the first cutting move after the spindle speed change until
motion.spindle-at-speed is true. 

If you have a way to read the spindle speed, usually the
"near" hal component is used to generate the spindle-at-speed
signal. This can also be done if the spindle drive has a signal to report
that is is at speed.

Note that this will not work if you want to stop or alter the feed rate
if the spindle slows during operation, as motion.spindle-at-speed is ignored
after the first cutting move that follows a spindle speed change.

If you need to alter or stop the feed if the spindle speed drops during operation,
you would need to use adaptive feed (motion.adaptive-speed) and some hal math
or logic.
 
  • Artur_1617
  • Artur_1617's Avatar
21 Aug 2025 13:25
Stop feed when spindle rpm lower was created by Artur_1617

Stop feed when spindle rpm lower

Category: AXIS

Hi,
I looking for something can stop feed when spindle rpm is lower what is setup in G code S300 for example -15% and start feed when rpm back to S300.
 
Displaying 9751 - 9765 out of 17939 results.
Time to create page: 0.423 seconds
Powered by Kunena Forum