Subroutine error
- beltramidave
- Offline
- Elite Member
Less
More
- Posts: 174
- Thank you received: 4
07 Aug 2021 16:39 #217137
by beltramidave
Subroutine error was created by beltramidave
Running V2.7.15
Getting an error message when trying to run a touch off routine via a pyvcp button. This has just started and had been working for a couple years. I have 2 subs not working and the rest work fine. Have not edited anything recently to effect these either. It appears that it is looking in the currently open file for the sub, but it is totally separate.
The reason I say that it appears to be looking in the currently loaded file is because after a reboot, there is no file loaded yet and it shows a different error
Anybody with any ideas appreciated. I have looked at subs and ini file for some type of corruption, but to no avail..
Thanks
Getting an error message when trying to run a touch off routine via a pyvcp button. This has just started and had been working for a couple years. I have 2 subs not working and the rest work fine. Have not edited anything recently to effect these either. It appears that it is looking in the currently open file for the sub, but it is totally separate.
The reason I say that it appears to be looking in the currently loaded file is because after a reboot, there is no file loaded yet and it shows a different error
Anybody with any ideas appreciated. I have looked at subs and ini file for some type of corruption, but to no avail..
Thanks
Attachments:
Please Log in or Create an account to join the conversation.
- tommylight
- Away
- Moderator
Less
More
- Posts: 19385
- Thank you received: 6490
07 Aug 2021 16:58 #217141
by tommylight
Replied by tommylight on topic Subroutine error
In the ini file there is "open file", see what file is mentioned there as it seems to be missing from the config folder.
Or just set it to
""
And save, this way it does not try to open anything at start.
Or just set it to
""
And save, this way it does not try to open anything at start.
Please Log in or Create an account to join the conversation.
- beltramidave
- Offline
- Elite Member
Less
More
- Posts: 174
- Thank you received: 4
07 Aug 2021 18:40 #217148
by beltramidave
Replied by beltramidave on topic Subroutine error
The problem isn’t that anything is loading at startup. The problem is my subroutine is not working.
My subroutine folder is at the same location as the .Ini files is looking for as my other subs work.
My subroutine folder is at the same location as the .Ini files is looking for as my other subs work.
Please Log in or Create an account to join the conversation.
- BigJohnT
- Offline
- Administrator
Less
More
- Posts: 7330
- Thank you received: 1176
08 Aug 2021 12:39 - 08 Aug 2021 12:40 #217215
by BigJohnT
Replied by BigJohnT on topic Subroutine error
Attach your ini file and the files in question instead of screen shots.
JT
JT
Last edit: 08 Aug 2021 12:40 by BigJohnT.
Please Log in or Create an account to join the conversation.
- beltramidave
- Offline
- Elite Member
Less
More
- Posts: 174
- Thank you received: 4
08 Aug 2021 15:11 #217244
by beltramidave
Replied by beltramidave on topic Subroutine error
Here are the files. The subs 100 & 102 are the ones that were giving me an issue. All the rest of the subs were working fine.
I have rebooted several times since the initial post and now this morning all subs are working again. It's almost like Linuxcnc is loading something correctly, yet when this happened the first time, it was just out of the blue and the PC had not been shut down recently.
Guessing that you won't find anything in the files. Frustrating that it happens only occassionaly.
I have rebooted several times since the initial post and now this morning all subs are working again. It's almost like Linuxcnc is loading something correctly, yet when this happened the first time, it was just out of the blue and the PC had not been shut down recently.
Guessing that you won't find anything in the files. Frustrating that it happens only occassionaly.
Please Log in or Create an account to join the conversation.
- roland
- Offline
- Premium Member
Less
More
- Posts: 138
- Thank you received: 63
08 Aug 2021 17:11 #217248
by roland
Replied by roland on topic Subroutine error
usually there is an M2 at the end of the sub file.
In your case the M2 is missing. Maybe this has an affect
In your case the M2 is missing. Maybe this has an affect
Please Log in or Create an account to join the conversation.
- andypugh
- Offline
- Moderator
Less
More
- Posts: 23538
- Thank you received: 4854
11 Aug 2021 00:21 #217447
by andypugh
Replied by andypugh on topic Subroutine error
It looks like the problem might well be the lack of an M2 at the end of the subs.
Please Log in or Create an account to join the conversation.
- beltramidave
- Offline
- Elite Member
Less
More
- Posts: 174
- Thank you received: 4
11 Aug 2021 10:09 #217500
by beltramidave
Replied by beltramidave on topic Subroutine error
I can most certainly add M2 to the end and see if it makes a difference, but none of my other subs have it and they work fine all the time. I will try and report back, ThanksIt looks like the problem might well be the lack of an M2 at the end of the subs.
Please Log in or Create an account to join the conversation.
- beltramidave
- Offline
- Elite Member
Less
More
- Posts: 174
- Thank you received: 4
19 Aug 2021 11:21 #218132
by beltramidave
Replied by beltramidave on topic Subroutine error
Sorry for the lapse in replies.
Adding M2 to the end of my subroutine had no effect on my issue.
Adding M2 to the end of my subroutine had no effect on my issue.
Please Log in or Create an account to join the conversation.
- MaHa
- Offline
- Platinum Member
Less
More
- Posts: 390
- Thank you received: 155
19 Aug 2021 15:34 #218145
by MaHa
Replied by MaHa on topic Subroutine error
in the ini file
OPEN_FILE = /home/probotix/Desktop/Warmup Routine.ngc
having spaces in .ngc files could cause problems...
in o100 SUB
o101 if [#1 NE #5400]
but after start, maybe there is no tool in spindle, #5400 , and then further down the routine, P#1 must be a valid toolnumber from tooltable
G10 L11 P#1 Z0 R0
i think you need to exclude read this when loading, with something like
o800 IF [#<_task> EQ 0]
o800 RETURN [99]
o800 ENDIF
OPEN_FILE = /home/probotix/Desktop/Warmup Routine.ngc
having spaces in .ngc files could cause problems...
in o100 SUB
o101 if [#1 NE #5400]
but after start, maybe there is no tool in spindle, #5400 , and then further down the routine, P#1 must be a valid toolnumber from tooltable
G10 L11 P#1 Z0 R0
i think you need to exclude read this when loading, with something like
o800 IF [#<_task> EQ 0]
o800 RETURN [99]
o800 ENDIF
Please Log in or Create an account to join the conversation.
Time to create page: 0.196 seconds