Hello to all guys,
Thank you so much for the support. Now I'm able to use all the necessary safety devices in the tool change. I have included preliminary checks in the PMC editor (door, air, etc.).
I attach my script to other users who will need it in the future, at the end, the right G43 H, which is in the tool table, is also set, the next step will be to set it automatically by a touch probe.
Use with caution.
Now the other problem is: how to behave to put the tool at 0?
I made a macro that works alone, but with the current script I can not insert it.
moreover it does not manage the tool 0, it would not know where to start to resume the selected one