Real-time programming in Modula-2

Gough, K. John and Mohay, George M. and Pease, Wayne (1991) Real-time programming in Modula-2. Australian Computer Journal, 23 (4). pp. 175-182.

Metadata

HTML CitationEndNoteDublin CoreReference Manager

Full text not available from this archive.

Abstract

The unit of pseudo-parallelism in Modula-2 is the coroutine; coroutines switch control to one another through the use of simple coroutine TRANSFER operations. In the case of programs which need to cater for realtime events (i.e. interupts) an I/O coroutine awaiting an interrupt suspends itself pending the occurrence of the specified interrupt using the IOTRANSFER operation. Recognition of the awaited interupt, when it occurs, then causes execution of an asynchronous coroutine transfer which despatches the awaiting I/O coroutine. The module priority mechanism ensures inter alia, that other interrupts occurring during execution of that I/O or device handler coroutine will only be recognised if they are of higher priority. A modified set of Modula-2 coroutine primitives, prototyped using the PDP-11 M23 Modula-2 system, has been described previously. That model included the new primitive operation Attachinterrupt which effectively replaces IOTRANSFER, leading to an arguably simpler and more elegant structure for real-time pseudo- parallel Modula-2 programs. That model has now been extended to incorporate the additional primitive functions Priority and Previous respectively. The former provides a means by which a realtime coroutine may interrogate the priority of the coroutine which it has preempted (interrupted), while the latter is invoked by a coroutine in order to establish the identity of the coroutine which it has preempted via an interrupt or which it has succeeded via a synchronous transfer operation. This paper discusses the rationale for the extended model and its implementation in one of the most popular Modula-2 systems in use today, the Logitech Version 3 compiler for the IBM PC, and illustrates its use.

Item Type:Article (Commonwealth Reporting Category C)
Additional Information:Unavailable in electronic format.
Uncontrolled Keywords:Modula-2, realtime programming, coroutines, pseudo-parallelism, priorities
Fields of Research (FOR2008):08 Information and Computing Sciences > 0803 Computer Software > 080399 Computer Software not elsewhere classified
08 Information and Computing Sciences > 0803 Computer Software > 080308 Programming Languages
08 Information and Computing Sciences > 0803 Computer Software > 080304 Concurrent Programming
Subjects:280000 Information, Computing and Communication Sciences > 280300 Computer Software > 280303 Programming Languages
280000 Information, Computing and Communication Sciences > 280300 Computer Software > 280399 Computer Software not elsewhere classified
280000 Information, Computing and Communication Sciences > 280300 Computer Software > 280301 Programming Techniques
Socio-Economic Objective (SEO2008):UNSPECIFIED
ID Code:3525
Deposited By:
Deposited On:14 Nov 2007 14:59
Last Modified:08 Jan 2010 15:12

Archive Staff Only: edit this record