StandardChannel.Open Method
This method opens a channel. This channel is identified by the combination of VendorId, ProductCode, and ChannelId. If a channel with the same combination already exists, it will be opened.
Namespace:
IntervalZero.MaxRT.Libraries.DebugMessage
Assembly:
IntervalZero.MaxRT.Libraries (in IntervalZero.MaxRT.Libraries.dll) Version: 1.0.0.0 (File version: 1.0.1)
Syntax
public void Open(
uint VendorId,
uint ProductCode,
uint ChannelId,
uint DefaultMessageFilter,
uint BufferLength,
uint MessageTextLength,
uint MessageDataLength
)
Parameters
VendorId
Type: UInt32
The vendor ID of the application. This should correspond to the CustomerId of the wRTOS SDK license used to build the program.
ProductCode
Type: UInt32
The product ID defined by the vendor.
ChannelId
Type: UInt32
The debug channel ID defined by the vendor.
DefaultMessageFilter
Type: UInt32
A selection of messages to log even when the console is not open.
BufferLength
Type: UInt32
The number of messages in the queue. This value is between 100 and 20,000. The recommended value is 10,000.
MessageTextLength
Type: UInt32
The maximum length of the message text in characters. This value is between 0 and 128.
MessageDataLength
Type: UInt32
The maximum length of the message data in bytes. This value is between 0 and 512.
Return Value
Type: void
InvalidOperationException is thrown when the channel is already open.
MaxRTNativeException is thrown when these errors occur:
| Error code | Meaning |
|---|---|
|
ERROR_INVALID_PARAMETER |
One of the following conditions occurred:
|
|
ERROR_NOT_ENOUGH_MEMORY |
Failed to create the channel. |
|
ERROR_ABANDONED_WAIT_0 |
Failed to acquire the synchronization lock for the channel. |
See Also: