License#

Copyright 2018 Silicon Laboratories Inc. www.silabs.com

SPDX-License-Identifier: Zlib

The licensor of this software is Silicon Laboratories Inc.

This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.

Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:

  1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.

  2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.

  3. This notice may not be removed or altered from any source distribution.

/***************************************************************************/
#ifndef _MAILBOX_SERVER_H_
#define _MAILBOX_SERVER_H_

#include "mailbox/mailbox-protocol.h"
#include "mailbox/mailbox-types.h"

EmberAfMailboxStatus emberAfPluginMailboxServerAddMessage(EmberNodeId destination,
                                                          uint8_t *message,
                                                          EmberMessageLength messageLength,
                                                          uint8_t tag,
                                                          bool useSecurity);
// ------------------------------------------------------------------------------
// Callbacks

void emberAfPluginMailboxServerMessageDeliveredCallback(EmberAfMailboxStatus status,
                                                        EmberNodeId messageDestination,
                                                        uint8_t tag);

#endif //_MAILBOX_SERVER_H_

Callbacks#

void
emberAfPluginMailboxServerMessageDeliveredCallback(EmberAfMailboxStatus status, EmberNodeId messageDestination, uint8_t tag)

Mailbox Server Message Delivered Callback.

Functions#

emberAfPluginMailboxServerAddMessage(EmberNodeId destination, uint8_t *message, EmberMessageLength messageLength, uint8_t tag, bool useSecurity)

Add a message to the mailbox server queue. The message is stored in the internal queue until the destination node queries the mailbox server node for messages or upon timeout.

Callbacks Documentation#

emberAfPluginMailboxServerMessageDeliveredCallback#

void emberAfPluginMailboxServerMessageDeliveredCallback (EmberAfMailboxStatus status, EmberNodeId messageDestination, uint8_t tag)

Mailbox Server Message Delivered Callback.

Parameters
[in]status

An EmberAfMailboxStatus value of:

[in]messageDestination

The node ID of the destination.

[in]tag

The tag value passed in the emberAfPluginMailboxServerAddMessage() API.

This callback is invoked at the server when a message submitted locally by the server was successfully delivered or when it timed-out.

See Also


Definition at line 110 of file /mnt/raid/workspaces/ws.04isO4uyE/overlay/gsdk/protocol/flex/mailbox/mailbox-server/mailbox-server.h

Function Documentation#

emberAfPluginMailboxServerAddMessage#

EmberAfMailboxStatus emberAfPluginMailboxServerAddMessage (EmberNodeId destination, uint8_t * message, EmberMessageLength messageLength, uint8_t tag, bool useSecurity)

Add a message to the mailbox server queue. The message is stored in the internal queue until the destination node queries the mailbox server node for messages or upon timeout.

Parameters
[in]destination

The node ID of the destination for this data message.

[in]message

A pointer to the message to be enqueued.

[in]messageLength

The length in bytes of the message to be enqueued.

[in]tag

A tag value which will be returned in the corresponding emberAfPluginMailboxServerMessageDeliveredCallback() callback. The application can use to match the callbacks with the call.

[in]useSecurity

Set it true if the data message should be sent to the server using security.

Returns

See Also


Definition at line 79 of file /mnt/raid/workspaces/ws.04isO4uyE/overlay/gsdk/protocol/flex/mailbox/mailbox-server/mailbox-server.h