Interface: tos.interfaces.TokenReceiveMsg

interface TokenReceiveMsg

Receive messages with an identifying token that can be used for acknowledgement.

Author:
Phil Buonadonna

Commands
command result_t ReflectToken(uint8_t Token) Sends a one byte token down the original channel that received the token.

Events
event TOS_MsgPtr receive(TOS_MsgPtr Msg, uint8_t Token) A packet and an associated token have been recieved.

Commands - Details

ReflectToken

command result_t ReflectToken(uint8_t Token)

Sends a one byte token down the original channel that received the token. This function can be used as an acknowledgement mechanism.

Parameters:
Token - A one byte token.
Returns:
SUCCESS if the provider was able to queue the token for transmission.

Events - Details

receive

event TOS_MsgPtr receive(TOS_MsgPtr Msg, uint8_t Token)

A packet and an associated token have been recieved. The one-byte token is a unique value linked to the message received. This interface is designed for use by modules like HDLCM which may pass a token up that is later used as part of an acknowledgement process.

Parameters:
Msg - A pointer to the received TOS_Msg
Token - A one byte token associated with the recieved message.
Returns:
A buffer for the provider to use for the next packet.