Objects

“Object” is the general term for resources handled by µT-Kernel. Besides tasks, objects include memory pools, semaphores, event flags, mailboxes and other synchronization and communication mechanisms, as well as time event handlers (cyclic handlers and alarm handlers).

Attributes can generally be specified when an object is created. Attributes determine differences in object behavior or the initial object state. When TA_XXXXX is specified for an object, that object is called a “TA_XXXXX attribute object”. If there is no particular attribute to be defined, TA_NULL (=0) is specified. Generally, there is no interface provided for reading attributes after an object is registered. In an object or handler attribute value, the lower bits indicate system attributes and the upper bits indicate implementation-dependent attributes. This specification does not define the bit position at which the upper and lower distinction is to be made. In principle, however, the system attribute portion is assigned from the least significant bit (LSB) toward the most significant bit (MSB), and implementation-dependent attributes from the MSB toward the LSB. Bits not defining any attribute must be cleared to 0.

In some cases, an object may contain extended information. Extended information is specified when the object is registered and is passed in the parameters when the object starts execution. Extended information has no effect on µT-Kernel behavior and can be read by calling a system call to refer the status of the object. Each object is identified by an ID number. In the µT-Kernel, the ID number cannot be specified by users and is automatically allocated when an object is created. Therefore, it is difficult to identify objects when debugging. For this reason, when creating objects, users can specify an object name for debugging. This name is just for debugging and can be referenced only from debugger support functions. The µT-Kernel itself never checks the name of an object.

Comments

Click here to Post a Comment