====== OSA : OS_Smsg_Accept ======
**OS_Smsg_Accept (smsg, os_smsg_type_var)**\\
**OS_Smsg_Accept_I (smsg, os_smsg_type_var)**\\
=== ===
Accept existing simple message. Before calling this service you should be sure that a message exists. After service completes, the simple message is cleared.
=== Call allowed: ===
Everywhere
=== Parameters: ===
{| class = "fpl"
|-
|//''smsg''//
|Simple message descriptor. Variable of ##[[en:osa:ref:description:data_types#OST_SMSG|OST_SMSG]]## type
|-
|//''os_smsg_type_var''//
|Variable of ##[[en:osa:ref:description:data_types#OST_SMSG|OST_SMSG]]## type, where simple message will be placed
|}
=== Returns: ===
nothing
=== Example: ===
OST_SMSG smsg;
void Task (void)
{
OST_SMSG my_smsg;
for (;;) {
/*...*/
if (OS_Smsg_Check(smsg)) { // if simple message exists
OS_Smsg_Accept (smsg, my_smsg); // then accept it and store into my_smsg
}
/*...*/
}
}
=== Old style name ===
**OS_AcceptSMsg**\\
=== See also ===
* [[en:osa:ref:allservices:OS_Smsg_Create|OS_Smsg_Create]]
* [[en:osa:ref:allservices:OS_Smsg_Send|OS_Smsg_Send]]
* [[en:osa:ref:allservices:OS_Smsg_Send_TO|OS_Smsg_Send_TO]]
* [[en:osa:ref:allservices:OS_Smsg_Send_Now|OS_Smsg_Send_Now]]
* [[en:osa:ref:allservices:OS_Smsg_Check|OS_Smsg_Check]]
* [[en:osa:ref:allservices:OS_Smsg_Wait|OS_Smsg_Wait]]
* [[en:osa:ref:allservices:OS_Smsg_Wait_TO|OS_Smsg_Wait_TO]]
----
* [[en:osa:ref:services:alphabetical|Alphabetical]]
* [[en:osa:ref:services:brieflist|All services]]
~~UP~~