Class IoEventOutput

Nested Relationships

Nested Types

Inheritance Relationships

Base Type

Class Documentation

class IoEventOutput : public EventOutput

This class defines event output functions that can be processed by the Io module. Also see I/O Outputs.

Public Types

enum IoEventOutputType

This enumerator class enumerates the types of event output functions that can be processed by this module.

Values:

enumerator SetIOOutBit

This output function sets an I/O output bit.

If the I/O output bit is changed by another function, this output function will not overwrite the I/O output bit until this event is triggered again (see Triggering Events).

The parameters for this output function are specified in the SetIOOutBit structure of output.

Public Functions

IoEventOutput()
virtual int GetOutputModuleId()

Return the ModuleId of the Io module.

virtual WMX3APIFUNC GetOutputData(unsigned char *buff, int buffSize, int *dataSize)

Convert the values specified in other member variables of the class inheriting this class to a binary representation that can be sent to the engine.

Convert the values specified in other member variables of the class inheriting this class to a binary representation that can be sent to the engine.

Parameters:
  • buff[out] A pointer to a buffer that will contain the binary representation of the member variables.

  • buffSize[in] The size of the buffer in bytes.

  • dataSize[out] A pointer to an unsigned int that will contain the size of the binary representation of the member variables, in bytes. This size of the buffer will be occupied.

virtual WMX3APIFUNC SetOutputData(int moduleId, unsigned char *data, int dataSize)

Convert the binary representation of the values specified in other members of the class inheriting this class and copies them back to the other members.

Convert the binary representation of the values specified in other members of the class inheriting this class and copies them back to the other members.

Parameters:
  • moduleId[in] The ID of the module that defines the binary representation of the member variables.

  • data[in] A pointer to a buffer that contains the binary representation of the member variables.

  • dataSize[in] The size of the buffer in bytes.

Public Members

IoEventOutputType outputFunction

Specifies the event output function.

union wmx3Api::IoEventOutput::OutputFunctionArguments output

Specifies the arguments for the event output function.

union OutputFunctionArguments

This union defines the structs containing arguments for each output function.

Public Functions

OutputFunctionArguments()

Public Members

struct wmx3Api::IoEventOutput::OutputFunctionArguments::SetIOOutBit setIOOutBit
struct SetIOOutBit

This structure contains arguments for the SetIOOutBit output function.

Public Members

unsigned int byteAddress

The byte address of the I/O output bit.

unsigned char bitAddress

The bit address of the I/O output bit.

unsigned char invert

If this argument is set to 1, the I/O output bit will be set to 0 when the event is triggered. If this argument is set to 0, the I/O output bit will be set to 1.

unsigned char setOffState

If this argument is set to 1, in addition to the operation when the event is triggered, the I/O output bit is set to 0 (or to 1 if invert is 1) when the event is not triggered. If this argument is set to 0, no operation is executed when the event is not triggered.