Brother TC-225 / TC-229 adventure!

More
19 Aug 2017 11:09 #97736 by andypugh

the second issue i had was that weighted sums are s32, and m66 is expecting a bit. so i just did the weighted sum inside the g code. works fine, just a few more lines of code.)


There are HAL functions that convert between data types, but doing it in the G-code might be tidier.

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

More
19 Aug 2017 17:12 #97746 by ihavenofish
ok, were stuck on remapping m6.

i put the subroutine path in the ini, and remap m6 line pointing to the ngc file.
it still pops up the "please remove tool" dialogue and does nothing else, so i assume I'm missing something either in the ini, or in hal, or both.

there was an example id found before, but i cant seem to find now.

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

More
19 Aug 2017 17:24 #97747 by andypugh
It sounds like you still have hal_manualtoolchange in the HAL file.

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

More
19 Aug 2017 17:43 #97748 by ihavenofish
aha. that's a safe bet, cause i sure didn't delete it :P

ill be in front of the machine in a few hours, ill check it over.

thanks!

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

More
20 Aug 2017 07:29 #97761 by ihavenofish
ok, got m6 to remap to my subroutine, but i cant manage to figure out how i pass the T number to it. i assume i need to map T to variable which then gets read... somehow.

I'm tired now and my brain has stopped working :P

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

More
20 Aug 2017 08:26 #97764 by andypugh
Are you using the standard-glue Python scripts in the remap?

In your G-code you can probably use #<tool> for the tool number.
There may also be #<tool_in_spindle>, #<selected_tool>, #<current_pocket> and #<selected_pocket>

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

More
20 Aug 2017 15:08 #97786 by ihavenofish
no python at this point.

i guess that's required?

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

More
20 Aug 2017 16:02 #97787 by ihavenofish
looking at the python stuff... is there a "standard" one? or am i creating one and placing it somewhere, based on the example in the docs?

----
def change_prolog(self, **words):
try:
if self.selected_pocket < 0:
return "M6: no tool prepared"

if self.cutter_comp_side:
return "Cannot change tools with cutter radius compensation on"

self.params["tool_in_spindle"] = self.current_tool
self.params["selected_tool"] = self.selected_tool
self.params["current_pocket"] = self.current_pocket
self.params["selected_pocket"] = self.selected_pocket
return INTERP_OK
except Exception, e:
return "M6/change_prolog: %s" % (e)
---

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

More
20 Aug 2017 16:10 - 20 Aug 2017 16:12 #97788 by ihavenofish
ooooh, stdglue is something different. i see where that's supposed to be added.

is the idea that this will pass the #<tool> into my ngc's list of variables?

thanks!
Last edit: 20 Aug 2017 16:12 by ihavenofish.

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

More
20 Aug 2017 16:23 #97789 by ihavenofish
ok, i think i got it. (not at the shop yet, so this is just in my head)

we add stdglue, which contains out prolog and epilog scrpts. those allow parameters to pass back and forth.

so in my ngc, i need to both read (for the T value) and write back status so the system knows the tool has changed for use in other features, like tool tables, display, etc..

ill get this all down eventually :P

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

Moderators: cncbasher
Time to create page: 0.329 seconds
Powered by Kunena Forum