[html]article C at_work.gif (Under Construction...) [1]#1 Software Engineering 1: Course Notes Barry McMullin Last Modified: 23rd February 1996 Note that this complete document is available in LaTexswe1root.tex and plain ASCIIswe1root.txt forms. Thus, you can download the document and browse it offline.LaTeX is a typesetting mark-up language, particularly suitable for hierarchically organised documents, and documents using mathematical notation extensively. It is a de-facto standard in academic publishing. A LaTeX source file is still a form of ASCII, but with typesetting commands interspersed with the "raw" text. In principle it can be read with any tool which can display ASCII files. However, note that this, and other online text documents, may be too large to load into the MS-Windows NotePad application. In such cases, you will need to use some alternative viewing tool, such as the Programmer's File Editorftp://ftp.hea.ie/pub/windows/programr/pfe0507.zip. This is a powerful (and free!) professional text editor for Windows. It does the same job as NotePad, but much better! This is the top-level, online, hypermedia documentation for the course Software Engineering 1. This is a required course for all students enrolled on Stage 1 of the B.Eng. (Electronic Engineering) http://www.eeng.dcu.ie/eenghome/ee_info/ee_info.html or B.Eng. (Telecommunications Engineering) programmes offered by the School of Electronic Engineering http://www.eeng.dcu.ie/eenghome/eenghome.html of Dublin City University http://www.compapp.dcu.ie/DCU_home.html. at_work.gif These online notes are under construction, and may be incrementally extended and corrected as the year progresses. Introduction The course provides an introduction to Software Engineering - which is to say the skill of developing software or programs for digital computers. The vast majority of modern technological products - from dishwashers to communications satellites, CD players to industrial robots - include at least one, and often many more, embedded microprocessors. A microprocessor is the central processing component of a general purpose computer, implemented as a single integrated circuit (IC). The specific behaviours or functionalities of the completed product are then realised by providing these microprocessors with appropriate sequences of instructions, or software. Software is thus a crucial foundation for virtually all modern technological products - and software development is an essential and pervasive skill for every engineering discipline. This is reflected in the design of the engineering programmes in DCU, where Software Engineering takes a prominent role all stages - beginning with this very important introductory course. The objective of the course is that, on completion, you should be able to design, code, test and debug small, but complete, programs. The course introduces a modern high level procedural language (ANSI C), supported on a general purpose computing platform (ISA hardware, running MS-DOS and MS-Windows). The course is preparatory in nature, providing necessary foundations for a variety of courses in subsequent stages of the relevant programs. Syllabus This section is subject to further revision. [Background:] Introduction to stored program digital computers. Historical perspectives. The nature of software engineering: issues of cost, reliability and efficiency. The von Neumann architecture, and the idea of a sequential machine. Evolution of computers and programming languages. [Characters and Text:] Computerised text. Characters and character sets. The 7-bit ASCII character set. Text files. Text editing. Directories. Text files as computer programs: the concepts of translation, execution, and debugging. The use of an Integrated Development Environment (IDE). [Identifiers:] Concept of identifiers. File and directory names as identifiers. Identifier uniqueness. Syntax of identifiers in programs. Reserved identifiers in (keywords). Conventions and guidelines on identifier usage. [Data:] Concepts of data type, constants, and variables. Type int. int constants and range. Declaring variables. [Operators:] Arithmetic operators: + (addition), - (subtraction), * (multiplication), / (quotient), (remainder). Negative operands: direction of quotient truncation and sign of remainder. Exceptions: overflow and divide-by-zero. int values corresponding to "truth" and "falsehood". Equality operators: == (equal to), != (not equal to). Relational operators: > (greater than), >= (greater than or equal to), < (less than), <= (less than or equal to). Logical operators: (AND), (OR), ! (negation). [Expressions:] Forming expressions. Concept of expression evaluation. Sequential nature of expression evaluation. Order of evaluation: operator precedence and associativity; forcing associativity with parentheses. [Assignment:] The concept of assignment. Operator side effects. The assignment operator (=): evaluation and side effects. Increment (++) and decrement (--) operators. Type unsigned int; type conversion. [Programs:] Skeleton structure of a program: the main function. Declarations and statements. Comments. The concept of flow of control. Types of statements: expression, if, if-else and switch statements. Compound statements. The idea of iteration and the while statement. Symbolic constants and define. Input and output by direct modification and examination of variables within an Integrated Development Environment. Monitoring execution: tracing and breakpoints. [Development Cycle:] Specification. Algorithm design. Coding. Compilation and linkage. Testing: selection of test cases. Exception handling. Defensive design. Debugging. Instructors The lecturers for the course are Dr. Barry McMullin http://www.eeng.dcu.ie/7Emcmullin/home.html, and Mr. John Whelan http://www.eeng.dcu.ie/7Esneville/john.html. The laboratory demonstrators are Fiona Murray and Peter Hillary. Textbook The course textbook is currently under review. The textbook used in 1994-95 proved to be unsatisfactory in various ways, and alternatives are being considered. A textbook will not be required until term 2 in any case. Tutorials A voluntary, "walk-in", tutorial will be offered each week. This is currently scheduled for Tuesday, from 10.00--11.00 pm, in the CAE lab - however, this is likely to change. Tutorials will not begin before week 5 of term 1. At least one of the instructors and/or demonstrators will be present at this time. This is an excellent opportunity to look for help in completing any lab exercises which you have outstanding, particularly if you are stuck with some problem you simply can't seem to overcome. You can, of course, submit queries by e-mail at any time (see Feedbackfeedback); but this may be impractical for various reasons (e.g., if your problem is that you can't get the mail system to work!). In such cases, the tutorial is your opportunity to get the problem sorted. Assessment The course will be assessed by way of two supervised Laboratory Examinations. The first of these will take place early in Term 2, the second at the end of Term 3. The overall subject mark will be a weighted sum of the marks achieved in these two examinations: 25 from the first, 75 from the second. The format of the examinations will be very similar to the format of the normal lab exercises. Each student will work alone. The examinations will be of three hours duration. Instructions will be accessed via the World Wide Web. The work to be done will be derived from work done during the normal lab sessions - though it will, of course, differ in detail. A report will be required, submitted electronically. This report will form the basis for marking the examination. Detailed information on the format of the report, and the marking scheme to be used, are available in the Laboratory Report Guidelines http://www.eeng.dcu.ie/7Emcmullin/swe1/rptfmt/rptfmt.html. It was originally intended that students repeating this course 1995/96 would be required to sit both lab examinations, in exactly the same way as students attending for the first time.The course was assessed by written exam up to 1993-94; an option of written exam was offered to repeat students in 1994-95; that option is now formally ceased, and is not available in 1995-96. However, there are some differences in detail in the material being examined in the first lab exam in 1995/96 compared to 1994/95. In the light of this, the examination requirements for repeat students have now been relaxed and amended as follows: Repeat students are not required to sit the first Lab examination. Instead they may sit only a special final lab examination, which will be of similar content and format to the final lab examination for 1994/95, and will count for 100 of the repeat mark. Alternatively, at their own option, repeat students may opt to be assessed on exactly the same basis as first time students, sitting both lab exams, with the standard marking allocation (25 + 75) between them. Note carefully that these examinations will be based on the material presented in 1995/96, and this does differ in some respects from that presented in 1994/95. Specifically, in 1995/96, a special software module (safe-c) has been used. This provides certain simplified facilities in a packaged form. This also relies on the use of a different C compiler (GNU cc). Repeat students opting to sit the same lab exams as first time students must ensure that they familiarise themselves with this module, with the GNU cc compiler and with the specific lab exercises assigned in session 1995/96. All the relevant reference information is available in the normal way on the School Web site. If you are a repeat student, it will be assumed that you are accepting assessment by model 1 above, unless you indicate otherwise, in writing, to the faculty administrative Assistant Ms. Valerie Hogg no later than 20th December 1995. Feedback The preferred way of giving feedback on any aspect of the course via the SOFTENG1-95 http://www.eeng.dcu.ie/7Emajordom/softeng1-95.info.html electronic mailing list. You can monitor postings to this list (and responses) in the archives http://www.eeng.dcu.ie/7Emajordom/hm_archives. You send email to the mailing list by addressing it to SOFTENG1-95@mjmail.eeng.dcu.ie mailto:softeng1-95@mjmail.eeng.dcu.ie. If appropriate, you can give me private feedback on any aspect of the course, or ask questions etc., by sending e-mail to mcmullin@eeng.dcu.ie mailto:mcmullin@eeng.dcu.ie. I normally check this mailbox at least once every day, and will respond as quickly as I can. This is far and away the most reliable and effective way of getting in touch with me. On-Line Resources The following additional materials are available in separate online documents: Laboratory Exercises http://www.eeng.dcu.ie/7Emcmullin/swe1/swe1labs/swe1labs.html: These are the notes for the individual lab sessions. General Examination Instructions http://www.eeng.dcu.ie/7Emcmullin/swe1/95-96/exams/general: These are the general instructions for the Laboratory Examinations. This document includes links to specific examination exercises - which, of course, become active only during the examination sessions. Laboratory Report Guidelines http://www.eeng.dcu.ie/7Emcmullin/swe1/rptfmt/rptfmt.html: These are the guidelines for the preparation and submission of the formal lab reports. C Source File Directory http://www.eeng.dcu.ie/7Emcmullin/swe1/src/: This directory provides access to C source files introduced in the lectures, as the course progresses. The safe-c User Guide http://www.eeng.dcu.ie/7Emcmullin/swe1/safe-c/: This is the detailed technical documentation for the safe-c module, which is a collection of entities (data types, constants, functions) to facilitate introductory programming. The C Standard Library http://www.eeng.dcu.ie/7Emcmullin/swe1/stdlib/: This provides introductory documentation for the C Standard Library. DJGPP http://www.delorie.com/djgpp: DJGPP is a port (version) of the GNU C Compiler for the PC platform. This is the compiler which we will be generally using in this course. This node provides access to all the online documentation for DJGPP. There is also a very wide range of resources available elsewhere on the Internet, on the subjects of and C++ programming. Pointers to many of these have been collected on the Web Page called Learn C/C++ Todayhttp://vinny.csd.mu.edu/learn.html. If you are looking out for further elaboration or alternative approaches to the C language I strongly recommend that you have a browse through the materials identified by this site. Copyright This Hypermedia Document is copyrighted, 1994, 1995, by Barry McMullin http://www.eeng.dcu.ie/7Emcmullin/home.html. Permission is hereby granted to access, copy, or store this work, in whole or in part, for purposes of individual private study only. The work may not be accessed or copied, in whole or in part, for commercial purposes, except with the prior written permission of the author.