Embed tab not displayed with autostart

  • Axolito
  • Axolito's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
29 Nov 2024 19:09 #315576 by Axolito
I like my linuxcnc machine to be ready automatically. The session opens automatically and launches a little script that waits a few seconds, launches my linuxcnc config and offers to shut down the system when I leave the linuxcnc interface.

This script works very well, even on another machine at work. But I'm having a little problem with a custom embedded tab in place of the cooling buttons I use to control my dust collector.

When I run my config by hand, it usually displays correctly, but with autostart, my button is missing. Even without using my little script or extending the delay.

It's a LinuxCNC ISO that's a bit old (maybe two years) but updated, so maybe that's the problem, because at work, on a machine where I've used a more recent ISO, I don't have any problems.

My current LinuxCNC version: 2.9.3
GMOCCAPY: 3.4.8

I've attached my script, my ini file and two screenshots

It's quite strange. But it doesn't matter.
I'm curious to know what could be the problem.
Thanks
Attachments:

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

More
29 Nov 2024 19:17 #315578 by Aciera
Replied by Aciera on topic Embed tab not displayed with autostart
maybe writing the terminal output to a file could provide some clues
/usr/bin/linuxcnc '/home/axel/linuxcnc/configs/mini-cnc-tc-dust/mini-cnc-tc-dust.ini' >> '/home/axel/linuxcnc/debug_log.txt

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

  • Axolito
  • Axolito's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
29 Nov 2024 19:56 #315583 by Axolito
Replied by Axolito on topic Embed tab not displayed with autostart
Thank you, I had indeed forgotten to do this.

Even stranger, when I run the script by hand, the log file fills up, but this isn't really interesting because in this situation everything works correctly. But when it's run automatically, the log file remains empty.

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

More
30 Nov 2024 10:18 #315634 by Aciera
Replied by Aciera on topic Embed tab not displayed with autostart
Maybe add a debug output to the autostart command:

... >> /home/axel/autostart_log.txt

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

  • Axolito
  • Axolito's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
30 Nov 2024 10:36 #315635 by Axolito
Replied by Axolito on topic Embed tab not displayed with autostart
I had also tried, same problem

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

More
30 Nov 2024 12:04 #315641 by Aciera
Replied by Aciera on topic Embed tab not displayed with autostart
Maybe it is sending the output to stderr not stdout. This should direct both to the file:
/usr/bin/linuxcnc '/home/axel/linuxcnc/configs/mini-cnc-tc-dust/mini-cnc-tc-dust.ini' &> '/home/axel/linuxcnc/debug_log.txt
...  &> /home/axel/autostart_log.txt 

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

  • Axolito
  • Axolito's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
30 Nov 2024 15:05 #315655 by Axolito
Replied by Axolito on topic Embed tab not displayed with autostart
That didn't work either, but I came up with an idea to get the logs in a roundabout way.

I use :
xfce4-terminal -x linuxcnc '/home/axel/linuxcnc/configs/mini-cnc-tc-dust/mini-cnc-tc-dust.ini'
Then I saved the output in the attached file.

This is an error related to the toggle.1 function in the HAL file for the dust collector button.

I was able to solve my problem with this information!
My “loadrt toggle” was in the “postgui.hal” file, I moved it to the “machine.hal” file.
For some reason, the “postgui.hal” file isn't loaded at exactly the same time when it's an autostart and when it's a manual start.

In any case, now it's cleaner and more stable.
Thanks for the help.
Attachments:
The following user(s) said Thank You: Aciera

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

Moderators: newbynobiHansU
Time to create page: 0.061 seconds
Powered by Kunena Forum