The stbroadcast module provides stubborn anonymous best-effort local area broadcast.
A message sent with the stbroadcast module is repeated until either the message is canceled or a new message is sent. Messages sent with the stbroadcast module are not identified with a sender ID.
Channels
The stbroadcast module uses 1 channel.
|
file | stbroadcast.h |
| Header file for the Rime module Stubborn Anonymous BroadCast (stbroadcast)
|
|
Cancel the current stubborn message.
- Parameters
-
This function cancels a stubborn message that has previously been sent with the stbroadcast_send_stubborn() function.
Set up a stbroadcast connection.
- Parameters
-
c | A pointer to a user-supplied struct stbroadcast variable. |
channel | The Rime channel on which messages should be sent. |
u | Pointer to the upper layer functions that should be used for this connection. |
This function sets up a stbroadcast connection on the specified channel. No checks are made if the channel is currently used by another connection.
This function must be called before any other function that operates on the connection is called.
Send a stubborn message.
- Parameters
-
c | A stbroadcast connection that must have been previously set up with stbroadcast_open() |
t | The time between message retransmissions. This function sends a message from the Rime buffer. The
message must have been previously constructed in the
Rime buffer. When this function returns, the message
has been copied into a queue buffer.
If another message has previously been sent, the old
message is canceled. |
Set the retransmission time of the current stubborn message.
- Parameters
-
c | A stbroadcast connection that must have been previously set up with stbroadcast_open() |
t | The new time between message retransmissions. This function sets the retransmission timer for the
current stubborn message to a new value. |