24.01.2015 Views

CoDeSys on CCP XS for Bromma Conquip - Research

CoDeSys on CCP XS for Bromma Conquip - Research

CoDeSys on CCP XS for Bromma Conquip - Research

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Student<br />

Joel Ek<br />

Supervisor at CC-Systems<br />

Fredrik Löwenhielm<br />

Dok Nr<br />

1.0<br />

Date<br />

2006-08-08<br />

Rev<br />

PA1<br />

Säk klass<br />

F<br />

Filname<br />

Thesis.doc<br />

CODESYS ON <strong>CCP</strong> <strong>XS</strong> FOR BROMMA CONQUIP<br />

The sec<strong>on</strong>d way to heighten the effectiveness is to collect all available knowledge about porting<br />

and also use the tools available. Ten different guidelines and tools are presented and the uses of<br />

them are estimated to decrease the workload in man-hours by 40%. The tools described are tools<br />

<strong>for</strong>: porting compatibility checking, portability evaluati<strong>on</strong>, generating system calling routines,<br />

program structure viewing, OS emulator and test support [5].<br />

In “Strategies <strong>for</strong> Porting Software between Microsoft Windows and Apple MacOs” William<br />

Edward Woody describes the process of porting applicati<strong>on</strong>s between two of the most comm<strong>on</strong><br />

operating system plat<strong>for</strong>ms. In his paper he outlines three main strategies when porting software<br />

from Microsoft Windows and Apple Macintosh:<br />

1. Factoring the user interface: A strategy suitable <strong>for</strong> applicati<strong>on</strong>s that do not rely <strong>on</strong><br />

underlying Windows API 4 calls. Steps that need to be taken are: find the interfacing to<br />

user interface, port the code and then recreate the user interface in Macintosh. If the user<br />

interface is a large part of the applicati<strong>on</strong> this strategy is not cost effective.<br />

2. CView 5 translati<strong>on</strong> Layer: A Strategy <strong>for</strong> applicati<strong>on</strong>s that rely <strong>on</strong> the user interface (<strong>for</strong><br />

example the Microsoft Foundati<strong>on</strong> classes (MFC)). Steps that need to be taken are: find<br />

the interfacing to user interface and CView, port the code, create a “translati<strong>on</strong> layer” that<br />

c<strong>on</strong>verts the MFC events and methods to the target framework counterpart and then<br />

recreate the user interface in Macintosh.<br />

3. API Translati<strong>on</strong> Layer: A Strategy <strong>for</strong> applicati<strong>on</strong>s that use the Win32 6 API. Steps that<br />

need to be taken are: find the interfacing to Win32 API, port the code, create a<br />

“translati<strong>on</strong> layer” that c<strong>on</strong>verts the Win32 API events and methods to the target<br />

framework counterpart and then recreate the user interface in Macintosh.<br />

To find the best strategy <strong>for</strong> each applicati<strong>on</strong> can also be a problem and many times there is not<br />

<strong>on</strong>ly <strong>on</strong>e strategy that solves the whole porting, instead a mix of different approaches is<br />

necessary [6].<br />

The research <strong>on</strong> increasing the software portability made during the years c<strong>on</strong>cludes in the<br />

following strategies: c<strong>on</strong>trol the interfaces, isolate dependencies and to think portable.<br />

The measurement <strong>for</strong> when to port existing code instead of redevelop is an estimati<strong>on</strong> of cost.<br />

When software porting has been chosen as the best alternative a porting document is ideally<br />

created, the implementati<strong>on</strong> adaptati<strong>on</strong> should be kept to a limited subset of the program, this<br />

decrease the possibility to introduce new errors in the code. The program still needs to be tested<br />

to see if the entrance to new envir<strong>on</strong>ment itself has resulted in new errors [7].<br />

In our case the ef<strong>for</strong>t <strong>for</strong> porting in stead of redevelop is predicted, primary <strong>for</strong> the direct cost<br />

being lower when porting the code but also reas<strong>on</strong> that additi<strong>on</strong>al costs <strong>for</strong> testing the software<br />

will be smaller.<br />

4<br />

Applicati<strong>on</strong> Programmatic Interface, provides services <strong>for</strong> computer programs.<br />

5<br />

CView is a MFC base class providing functi<strong>on</strong>ality <strong>for</strong> user defined view classes<br />

6<br />

Win32 is an API to program in windows, it mainly c<strong>on</strong>sist of C –code functi<strong>on</strong>s<br />

10 (55)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!