490 likes | 502 Views
This presentation explores the organization and case study of a software system in the field of Human Machine Interaction. It discusses the challenges faced and the goals achieved through this practical, real-life project.
E N D
A Students Project in the Field of “Human Machine Interaction in Realtime“ Klaus Bothe 8th Workshop “Software Engineering Education and Reverse Engineering” Durres, Albania, 8th – 13rd September 2008
Presentation addresses two issues: • Organisation of educational project work with a real-life software system • Introduction to this case study of a software system
Background: Organisational issues • Winter semester 2007/08: project seminar for students • Students project: 24 students 8 teams • Joint project seminar of Institute of Psychology (Prof. H. Wandke, Engineering Psychologie) and Institute of Informatics (K. Bothe) • Participants from staff (presenters, organisation): - Informatik: Klaus Bothe, Uli Sacklowski, Nicolas Niestroj, Jochen Heyden (students) • - Psychology: Hartmut Wandke, Knut Polkehn, Jens Nachtwei, Achim Warning (PhD students)
Background: History and goals • Pratice-oriented real-life projects: supported by our curriculum at HU • Students profit from that: real customer, new application area ... • Existing software system ATEO developed by staff from psychology and informatics students • Used in experimental psychology for research • ATEO with several drawbacks, e.g. missing documents like requirements specification, too complicated software architecture …
HMI software ATEO in our DAAD project? HMI = Human Machine Interaction • Another case study for software projects (after SemOrg, XCTL …) • Example of introducing real-life projects in education, e.g. by giving working task for students • Invitation for reuse, reimplementation, extension
ATEO: a nice comprehensible case study in the application area of psychology
ATEO system:Software controls experiments (1) Observer Sequence of experiments One subject Two subjects Baseline experiment 1 Baseline experiment 2 Central experiment
Working place as a photograph: drivers – observer Camera Wall Drivers: by joystick determine velocity and direction Observer: view of drivers, street with car -> give commands (visual, acustical)
Input buttons of the observer Activates a prepared mp3 file E.g “faster” Observer: select driver Observer: give commands (visual, acustical) to the selcted driver
ATEO system:Background are automated assistence systems In perspective: automated assistance system In this experiment: human Observer Sequence of experiments One subject Two subjects E.g. pilot and co-pilot in a plane E.g. driver in a car Baseline experiment 1 Baseline experiment 2 Central experiment
Reverse engineering project: Existing software to be documented and assessed Requirements specification ATEO:Smalltalk Software architecture: components … • SW quality criteria: Modifyability, Reusability of components (Structure of SW ok?) Test cases User handbook
Additional students activities Team-work Interdisciplinary work ATEO:Smalltalk Understand a new application field Learn a new object-oriented programming language: Smalltalk Software in interdisciplinary projects of our group:- Institute of Physics at HU (XCTL): C++- Leipniz Institute: Fortran 70, 90, 95- Hahn-Meitner-Institute: Turbo Pascal LabView (visual programming language) - Siemens (Diploma theses): C#
Overview of tasks • Task 1: 7. November 2007: Develop a use case diagram and a requirements specification of the ATEO system (external behaviour) • Task 2: 29. November 2007: ATEO program: Understand and document the implementation (each team only one class) • Task 3: 19. December 2007: Find and assess the real software architecture of the ATEO-System; make a proposal for a better one • Task 4: 23./30. January 2008- Extend the requirements specification according to user wishes
AnalysisandDefinition Design Implementation Test Maintenance Waterfall model:documents considered in the project External behaviour:Requirementsspecification... Structure of softwareSoftware Architecture Program code:commented ... Test cases …
Task 1: Develop a use case diagram and a requirements specification
Task 1: Develop a use case diagram and … • Use cases:completely different solutions from different groups;not decidable: which is the best solution? • Use cases – main errors:- not suitable use cases - too detailed use cases - actors with wrong rights
Use case diagram of ATEO: final result of discussion Drive the car <<include>> Write protocol file Pair of object persons (drivers) Give navigationshints <<include>> Operateur (observer) <<include>> Prepare and supervise the experiment Evaluateprotocol file Experiment leader Switch on the camera Scientiest(Psychologist) Built-upconvenientparcours
Task 1: Develop … a requirements specification • Requirements specification:sources were some verbal text in a students manuscript, the externally observable behaviour, questioning of psychologists • Requirements specification:results very promising, functional and non-functional requirements addressed, couples of open questions fixed Summary: Students very motivated by that application area
Task 1: Develop … a requirements specification Result: see File
Task 2: Understand and document the ATEO implementation
Task 2: Understand and document the ATEO implementation Subtasks: • Learn fundamentals of Smalltalk: Motivation: Java well-known: on that basis, learn a new oo language Smalltalk: one of the 7 most known OO languages (Java, C++, C#, Delphi, Eiffel, Simula 67) Smalltalk: innovative concepts have been introduced (Extreme Programming, Refactoring, SUnit ...) • Work with Squeak as a programming environment for Smalltalk;Modern programming environment: • Syntax-directed browser • integrated debugging • integrated versioning (like: cvs) • Interpretation (virtual code like Java JVM) combined with automated incremental compilation (thus, compilation not visible)
Differences between Smalltalk and Java Smalltalk: New concepts compared with Java - type-less language (dynamic typing) - visibility: all methods visible, all variables hidden - global variables (contradiction to OO) - Strong object-oriented language: even elementary data types are classes - no difference between class and object (classes are objects, too) - different syntax: x:=1, parameter passing ...
Task 3: Find and assess the real software architecture of the ATEO-System; make a proposal for a better one
Task 3: Find and assess the real software architecture of the ATEO-System; make a proposal for a better one. • Documented as a UML class diagram • Developed by open source UML tools: ArgoUML, Dia • SW architecture not atomatically derived by the tool (Smalltalk) manual and semi-automatic derivation • Rather good solutions, including assessment of the architecture: see later • Initial motivation by the staff useful: see next two slides
Software architecture: the project may fail Motivation “The Importance of Software Architecture • Software architecture forms the backbone for any successful software-intensive system. An architecture is the primary carrier of a software system's quality attributes such as performance or reliability. The right architecture - correctly designed to meet its quality attribute requirements, clearly documented, and conscientiously evaluated - is the linchpin for software project success. The wrong one is a recipe for guaranteed disaster.” (Website: Software Engineering Institute (SEI), Carnegie Mellon University)
Real architecture of XCTL (Inst. Physics) Motivation SW Architecture: Influences quality features: - comprehensibility - Re-usability of components in another environment - Maintainablity - Security - testability - ... Source: Kay Schützler, Dissertation
Task 3: a) Find … the real software architecture …
Relations between ATEO classes, morphs, global variabls Group 6
Gruppe 1 Relations between the 8 core ATEO classes …
Relations between the 8 core ATEO classes: without attributes and operations Gruppe 8
Task 3: b) Assess … the real software architecture …
Relations between the 8 core ATEO classes: architecture problems Group 8 End node class End node class*) cycle in three steps Direktcycle • Conclusion: • 5 classes are connected by cycles, i.e. they cannot be understood , re-used, modified, and separetly tested as independent components(ATEOTastaturabfragen,ATEOrealJoystickstepping, ATEOPar …) • can be handled only as a set of classes *) but not quite sure: global variables may cause additional relations between classes
Smalltalk (global variables)CarID AnteilMB1 u.a. Global variables: cohesion and coupling Globals considered harmful: . (E. Klimas …: Smalltalk with Style)
Task 3: c) make a proposal for a better software architecture
Group 1 Hierarchical layered architecture Layer 2: user interface MorphConfig MorphFahrzeug MorphStrecke Layer 1: functionality Versuchs-konfiguration Logdatei Versuchsablauf-steuerung Layer 0: data and hardware Tastatur, Joystick Steuerhard-warezugriff Dateizugriff
Group8 Hierarchical layered architecture
Task 4: Extend the requirements specification according to user wishes
Task 4: Extend the requirements specification according to user wishes Measures: • Teams connected to some of the use cases • Consultations between students and psychologists
Groups assigned to the use cases(2) Group 1 Drive the car <<include>> Group 6 Write protocol file Pair of experiment persons (drivers) Group 2 Give navigationshints <<include>> Group 8 Group 7 Operateur (observer) Group 5 <<include>> Prepare and supervise the experiment Evaluateprotocol file Experiment leader Switch on the camera Kamera- übertragung einschalten Group 4 Group 3 Scientiest(Psychologist) Built-upconvenientparcours
Task 4: Extend the requirements specification according to user wishes Results: • Teams present their solutions in a seminar followed by a discussion • Extended requirements form the basis for current diploma theses
Suitability of the ATEO system in education • ATEO isaconvenient case study in an application area: comprehensible also for informatics students • ATEO: motivating application area for the students • ATEO: like many systems in practice: most serious problem is the bad software architecture; hard to repair; certainly a reimplementation necessary; possibly also refactoring is applicable (Fowler, 2000) • Smalltalk is a mature OO language; Java would be better for our students (1st language)
ATEO: Main problems and what to do? • SW architecture: - some parts well-defined; however, many others chaotic- bad for maintenance and extension- the hardest challenge of the system: the bottleneck of the whole system • Smalltalk: A comparable Java solution would be valuable • Open: test case selection, automatization of regression testing • Some diploma thesis under work, e.g.- new working place for the operateur - network version (three working places for three actors) - evaluation of protocol files
ATEO: System demonstration on the basis of Smalltalk and Squeak