Macro not completing or sometimes not running at all

Macro not completing or sometimes not running at all
none 0.0 0

cMT3108XP

v6.09.01.524 build 2024.03.12

customer is encountering this issue in which they have a PLC object that executes a macro when a button is pressed. The macro seems to execute inconsistently. Originally, we got around this by essentially executing the macro twice, once with the button itself in a combo button and another time in the PLC object tied to said button.

We thought this had fixed the issue, but it seems we were mistaken.

The behavior as such is that the macro will not always execute when the button is pressed and that creates a serious issue in operation of the machine.

Anything you can suggest trying would be great. My only suspicion would be some kind of run-time or memory issue but I am not sure how to test this. A conference call to troubleshoot this would also be appreciated.

Hi @Cstarr,

Could you please post the macro in question so we can look closer?

macro_command main()

char command2[3] = {0x54,0x0d,0x0a} //this is T
char falses[1] = {false}
//OUTPORT(command1[0], "Free Protocol",3)
//DELAY(150)
OUTPORT(command2[0], "Free Protocol",3)
DELAY(50)
SetData(falses[0], "Weintek Built-in CODESYS", "Application.PLC_PRG.Scale_Tare",1)

end macro_command

Hi @Cstarr,

Please use one of the following system tags to monitor the status of the macro at runtime.

Ok, the macros that I need to monitor are No. 0 and 10. Is this the complete list of macros that can be monitored or is there a means to add No. 10?

@Cstarr,

You would use LW-10910 to monitor macro ID #10.

1 Like

If the macro were to fail for any reason, would it always have a status 32?