A comparison between Procedural and Object Orientated Programming for Communication links between a PC and a POS (Point Of Sale) System

Acknowledgements

I'd like to thank Colin Simm of Source Computing Ltd. and Alan Usher of Valid Link Ltd. for their help and guidance in setting up the Gilbarco TMS-15 and for it's loan in the first place. Without them, nothing would have been possible but the phone bill might have been cheaper!

Source Computing Ltd. are the producers of "Forecourt Plus", a back office system for independent petrol stations. "Forecourt Plus" is an accounting, wet and dry stock control system that enables the forecourt operator to access wet stock reporting and analysis including up to the minute stock reports and loss analysis. This occurs by way of software links to the Point Of Sale (POS). Colin Simm is the principal developer of this back office system and has been involved in this sector for over 10 years.

Valid Link Ltd. took over the support and development for the Gilbarco TMS-15 when Gilbarco Ltd. ended their support and development. The Gilbarco TMS-15 is an POS and pump controller that controls the petrol pumps on a garage forecourt and also acts as a till. Alan Usher is an ex-Gilbarco engineer who is now solely responsible for all implementations of new changes to the TMS-15 POS.

Colin Simm is Managing Director of both these companies.

I would also like to thank Pete Granby for the gift of one Java book and the loan of another, as well as the time he gave to listen to my whinges and the pointers in the right direction that he gave.

Thank you to Linda Hole for the time spent looking at statistics, especially knowing that she likes them as much as I do!

Finally I would like to thank Ian Bray for all the help he gave as my project tutor it was truly appreciated.

Abstract

The aim of this project was to develop an object-orientated programmed link between a PC and a Gilbarco TMS-15 Electronic Point of Sale (POS). This link uses the serial port rather than a special communications card within the P.C. The link was developed using Java™ and the additional CommAPI from Sun.

The object-orientated Link in Java™ was then compared to the existing structured programming link, between the Gilbarco TMS-15 and the PC. Six Software Engineers of varying abilities made comparisons of a section of code of both Java™ and QuickBasic™ for ease of understandability, maintainability and code reuse. The evaluation studied how well both object-orientated programming and structured programming produce maintainable, easy to understand, reusable code.

A recommendation to Source Computing Ltd. was then made, outlining whether Java™ should be the programming language used for a new version of their back office software. Alternative options were also described.

A comparison between Procedural and Object Orientated Programming for Communication links between a PC and a POS (Point Of Sale) System

Introduction

Symantec's Visual Café Version 3 Database Edition was used to write and compile all the software; TMS15 (the front-end software), Till_Link (the redirection to & from the Comm ports) and the CommTest (software used to check if the Till_Link software was sending and receiving through the Comm ports). Visual Café used Java™ 1.1.6 and Sun Microsystems' Java™ Communications API Version 2.0. The Java™ Communications API is an additional API which doesn't come as standard with Java™.

Visual Café was used instead of IBM's VisualAge™ for Java™ (as originally planned) because of difficulties in placing the additional API's files in the required areas. Also, although Java™ 1.2 (or 2.0 as it is officially known) was available, Java™ Communications API Version 2.0 had not been thoroughly tested with it by Sun Microsystems, and it was safer to use a version of Java™ that had been tested with Java™ Communications API Version 2.0.

Contents

Chapter One - The Project

1.0 Introduction
1.1 The Project Aims
1.2 Overview of Structured Programming
1.3 Overview of QuickBasic™
1.4 Overview of OO Programming
1.5 Overview of Java™

Chapter Two - Design issues

2.0 Introduction
2.1 High Level Architecture
2.2 Design of structured till link
2.3 Design of OO till link

Chapter Three - Building the till link

3.0 Introduction
3.1 The Till Link software
3.2 Problems and Solutions
3.3 The Front End software
3.4 Problems and Solutions
3.5 Conclusions

Chapter Four - Project Management

4.0 Introduction
4.1 Project Management within the project.
4.2 Conclusions

Chapter Five - Using the till link software

5.0 Introduction
5.1 Setting up the software
5.2 Running the software

Chapter Six - Evaluation of the Structured and Object Orientated approaches

6.0 Introduction
6.1 Background to the tests
6.2 The Tests
6.3 The Graphical Test
6.4 The Wilcoxon Signed-Ratings test
6.5 Conclusions

Chapter Seven - Recommendations for Source Computing Ltd.

7.0 Introduction
7.1 Is Java™ the best way forward?
7.2 Conclusions

References and Bibliography

References
Bibliography

Appendix A Java Code for Till_Link

Till_Link
SerialConnection
SerialConnectionException
SerialParameters
PortRequestedDialog
AlertDialog

Appendix B Java Code for TMS-15

TMS15_Frame
TMS15_AboutDialog
TMS15_QuitDialog

Appendix C Java Code for CommTest

CommTest

Appendix D Project Schedule

Project Plan Version 1.3


Back to Contents


logo - Valid XHTML 1.0!Valid CSS!Best viewed inMozilla FirefoxMozilla Firefox