1.2. Messages

The inter-module communication subsystem ("IMC") is partially inspired by the QNX IPC. Modules communicate to eachother by sending and receiving messages. Each message has unique numeric identifier, assigned by the system, and a name, by which it can be located. It can optionally have any number of binary attachments (parameters) and require a response. The layout of attachments and response requirement are not bound to the message; a message can have a different set of attachments each time it is sent.

Modules subscribe to receive messages by calling the para_msg_subscribe function. Multiple modules can subscribe to receive any particular message. If a message requires a response, it is only delivered to the first module that subscribed for it, otherwise it is delivered to all modules that subscribed for it (the latter is referred to as "notification" later in this document).

There is a special type of urgent messages, called "signals", which never have parameters and need not be registered or subscribed to. Signals have a greater priority than regular messages and are always retreived first. The only useful data a signal is carrying is its identifier, a 32-bit integer. Signals are intended to help coordinate threads of a single module, thus there is no special meaning in signal identifiers; they typically are internal enums.