PxMbxRequestMbx()

Request an application-specific server mailbox.

APPLIES TO

8.2.0 , 8.2.1 , 9.0.0 , 9.1.0

SYNOPSIS
PxMbx_t PxMbxRequestMbx (PxMbxReq_t mbxreqid);
ARGUMENTS
mbxreqid

The id of the requested server mailbox

RETURN VALUES
  • Mailbox object handle of the requested mailbox if available

  • Invalid mailbox handle if mailbox is not available

DESCRIPTION

PxMbxRequestMbx requests a handle to an application-specific mailbox that has been assigned before for a defined system service (mbxreqid) by PxMbxRegisterMbx.

IMPLEMENTATION GUIDELINES
Before call
  • mbxreqid must be a valid PXROS-HR service mailbox (V).

  • If the mailbox was created on another core, PxGetGlobalServerMbx() needs to be called first, once on the current core

After call
  • The function returns the requested service mailbox. This mailbox id may be checked with one of the following macros:

    • PxMbxIdIsValid() must be true.

    • PxMbxIdGet() must not be _PXIllegalObjId.

Best Practice
  • No restrictions

SEE ALSO
USAGE
#include "pxdef.h"

PxMbx_t mbx = PxMbxRequestMbx(mbxreqid);

if (!PxMbxIdIsValid(mbx)) {
    // Report error
}