NXT_MessageWrite
Writes a "NXT-to-NXT message" to the NXT's incoming BT mailbox queue
Contents
Syntax:
NXT_MessageWrite(message)
NXT_MessageWrite(message, mailbox)
NXT_MessageWrite(message, mailbox, handle)
Description:
NXT_MessageWrite(message) sends given message to the NXT brick
NXT_MessageWrite(message, mailbox) stores message in the specified mailbox. If no mailbox is specified, default one is 0 (zero)
NXT_MessageWrite(message, mailbox, handle) uses the given NXT connection handle. If no handle is specified, the default one (COM_GetDefaultNXT()) is used.
Note:
Use this function to store data locally on the NXT. There are 10 usable mailbox queues, each with a certain size (so be careful to avoid overflows). Maximum message limit is 58 bytes / chars. This function can be used to communicate with NXC programs (the NXC-function "ReceiveRemoteString" can be used to read the data on the NXT).
Examples:
NXT_MessageWrite('F010045');
NXT_MessageWrite('F010045', 1);
handle = COM_OpenNXT();
NXT_MessageWrite('F010045', 0, handle);
See also
Signature
- Author: Laurent Vaylet, The MathWorks SAS (France), Alexander Behrens (see AUTHORS)
- Date: 2008/12/17
- Copyright: 2007-2010, RWTH Aachen University