Hello Guest it is April 17, 2021, 05:07:04 PM

Author Topic: Link script to m8 and m9 command  (Read 343 times)

0 Members and 1 Guest are viewing this topic.

Link script to m8 and m9 command
« on: January 10, 2020, 09:02:51 PM »
I have create a m1000 and m1001 command to send http command to a smart switch for my dust collector. Everything work good but i will like to use the flood command so i was thinking to add m8 and m9 to the macro folder with my script but it does not work, what could i do to trigger m1000 when m8 is activate and m9 to m1001 when it desactivate.
Thanks

Offline TPS

*
  •  2,110 2,110
    • View Profile
Re: Link script to m8 and m9 command
« Reply #1 on: January 11, 2020, 11:17:37 AM »
you can not "customize" M8/M9 macro, but
you can use macropump and GETOEMDRO(13) (Floot ON) to send your http commands.
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.
Re: Link script to m8 and m9 command
« Reply #2 on: January 11, 2020, 07:25:27 PM »
Hi,
in Mach4 you can overwrite an existing m8/m9 with your own version, but not in Mach3.

Craig
My wife left with my best friend...
     and I miss him!
Re: Link script to m8 and m9 command
« Reply #3 on: January 12, 2020, 02:52:55 PM »
I came with this code for the macro pump:
Code: [Select]
Dust_status = GetOEMLed(13)
Dust_Var = GetVar(500)

If Dust_status = -1 Then
If Dust_Var = 0 Then
message "Dust collector change to ON"
SetVar(500, 1)
Else
message "No change"
End If
End If

If Dust_status = 0 Then
If Dust_Var = 1 Then
message "Dust collector change to OFF"
SetVar(500, 0)
Else
message "No change"
End If
End If

Now how from the macropump i could execute the m1000 and m1001 command

Thanks

Offline TPS

*
  •  2,110 2,110
    • View Profile
Re: Link script to m8 and m9 command
« Reply #4 on: January 13, 2020, 08:27:20 AM »
do not call a macro from a macro, yust copy yout code from M1000/M1001 into macropump.
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.