0
5.2kviews
With the help of an example, explain periodic task. List and explain the various types of tasks in an embedded system.

Mumbai University > Electronics Engineering > Sem 6 > Embedded System and RTOS

1 Answer
0
236views

Following are the various types of task in embedded system.

a) Periodic Task:

  1. A periodic task is the one that repeats after a certain fixed time interval.
  2. The precise time instants at which a periodic task occurs is demarcated by clock interrupts and hence periodic task are also known as clock-driven tasks.
  3. The time interval at which task repeats is called as period of the task.
  4. Mathematically, for a periodic task Ti; let φi be the time for the first occurrence of the task known as the phase of the task. Φi+pi is the next instant of occurrence of the task thus pi is the period of the task. The task has ei as the worst case execution time and di has its relative deadline

enter image description here

Example: Consider a cruise control mechanism on an automobile. The basic operation of cruise control is to keep the speed of the vehicle constant. Suppose the driver has selected 60mph as the desired speed. In case the vehicle is going slower or faster than the selected speed, then the embedded computer sends a signal to the engine controller to set the speed right. The frequency in which the computer checks whether the current speed of the vehicle is as per the set speed is called control rate and it is fixed by the control system designer.

b) Sporadic Task:

  1. A sporadic task recurs at random instants.
  2. A sporadic task Ti can be defined using the tuple:

    Ti = (ei,gi,di)

    Where

    • ei = worst case execution time of an instance of the task
    • gi= the minimum separation between two consecutive instances of the task
    • di = relative deadline.
  3. The minimum separation (gi) between two consecutive instances of task controls the rate at which sporadic tasks can arise.
  4. Sporadic tasks such as emergency message arrivals, reporting of accidents are highly critical whereas servicing an I/O device interrupt or a DMA interrupt is moderately critical. Example: In a robot, the task to handle an obstacle is highly sporadic in nature.

c) Aperiodic Task:

  1. Aperiodic task is similar to sporadic tasks and it can arise at any random instant.
  2. However, in case of an aperiodic task, the minimum separation gi between two consecutive instances can be 0. That is, two or more instances of an aperiodic task might occur at the same time instant.
  3. The deadline for an aperiodic task is expressed as either an average value or is expressed statistically. Aperiodic tasks are generally soft real-time tasks.
  4. Since aperiodic task can occur in quick succession there can be few deadline misses. Hence soft-real time activities are classified as aperiodic tasks. Example: Interactive commands issued by users are handled by aperiodic tasks and this includes handling keypad inputs, mouse movements, etc. Logging requests issued by other tasks can be sporadic in nature.
Please log in to add an answer.