Dear Sirs,
I read the topic, but I still have a problem.
KRC2, software 4.1.5
There is a point in the program where the robot has to stop, , the robot is waiting for a press an outer button and parallel with stopping sends an user message.
I'm using for the message a copy of the sample program in "TP" (abbreviated) , which works well.
The robot prints the user message and the system message about "wait for" as well.
For the safety, after pressing and release the button I trigger a new user message for confirmation, and follows a second "wait for".
This second waiting for pressing button executed well ( and the system message about waiting as well ), but the second user message do not printed.
The message code:
DEF first user message()
DECL INT ANSWER
DECL INT OFFSET
DECL STATE_T STATE
DECL MSG_T EMPTY_MSG
EMPTY_MSG={MSG_T:VALID FALSE,RELEASE FALSE,TYP #NOTIFY,MODUL[] " ",KEY[]" ",PARAM_TYP #VALUE,PARAM[]" ",DLG_FORMAT[]
" ",ANSWER 0}
$MSG_T=EMPTY_MSG
$MSG_T.MODUL[]=" "
$MSG_T.KEY[]=" this is my first user message "
$MSG_T.PARAM[]="PARAM"
$MSG_T.PARAM_TYP=#VALUE
$MSG_T.TYP=#QUIT
$MSG_T.VALID=TRUE
END
The second user message is the same, only the message content is an other text.
the first user message came from main program, robot stopped and trigged the following subprogram:
DEF continue the work ()
WAIT FOR IN 16 'OUTER BUTTON' STATE TRUE ; waiting press button
WAIT FOR IN 16 'OUTER BUTTON' STATE FALSE ; waiting release button
WAIT TIME= 1 SEC
second user message() ; this is the second user message, witch do not prints on display
WAIT TIME= 1 SEC
WAIT FOR IN 16 'OUTER BUTTON' STATE TRUE ; waiting press button again
END
My question :
Why do not prints the second user message to display, but executes the next program steps ?
Thanks a lot for help.