Home

AppCOE User Manual

image

Contents

1. MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 16 On ANSI Mapping configuration tab choose whether to use ANSI mapping as shown in Figure 6_22 If the ANSI mapping is checked the application will use MapuSoft s malloc Figure 6_22 ANSI Mapping Tab Optimized Target Code Generator This wizard optimizes target specific source code E Map ANSI 1 0 API Z Map ANSI VO Formatting API MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on ANSI Mapping tab are as follows Table 6_12 Field descriptions on ANSI Mapping tab Field Description Your Action Map ANSI Memory API Specifies you want to map ANSI malloc and free to OS Abstractor Interface equivalent functions To map ANSI to OS Abstractor Interface equivalent functions select the check box Note By default this feature is enabled Map ANSI I O API Specifies if you want to map ANSI device I O functions like open close read write ioctl J etc to OS Abstractor Interface equivalent functions To map ANSI I O functions to OS Abstractor Interface equivalent functions select the check box Note By default this feature is disabled MAP ANSI I O Formatting API Specifies if you want to map ANSI printf and sprintf to OS Abstractor Interface equivalent functions To map ANSI I O formatting functions
2. your application The marked Adabgen options are already added in Ada C C Changer Do not add these in your additional options tab If you add these options it will break Message Options m msg kind This suppresses the display of any messages of msg kind m msg kind This enables the display of any messages of msg kind mrmsg kind This suppresses the display of any messages of msg kind for the current invocation of the compiler and for any recursive invocation of the compiler mrmsg kind This enables the display of any messages of msg kind for the current invocation of the compiler and for any recursive invocation of the compiler The valid values for msg kind are i a all messages except that m a does not suppress error messages ii d implementation dependent messages iii e error messages iv i information messages v n not yet implemented messages vi Ww warning messages vii r redundant messages By default all messages except information and redundant messages are displayed for the current invocation of the compiler For recursive invocations no messages are displayed by default For convenience m a will suppress all messages except errors Adacgen Options Table 8 2 adacgen Options Options Description 0 The O option identifies the version number of the executable That s a zero not an oh a If the
3. MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL You can view the AppCOE generated optimized code in Figure 6 26 Figure 6_26 AppCOE Generated Example 8 demo cross os File Edit View Favorites Tools Help Q Back gt d P Search iz Folders E o Folder Sync Address D Ytargetcodeldemo cross os er UNS File and Folder Tasks M include c optimized interface Qd Make a new Folder Publish this folder to the Web source E2 Share this folder Other Places O targetcode My Documents gg Shared Documents y My Computer E My Network Places Details O bytes 3 My Computer MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Generating Project Files for your Target NOTE This feature requires a target license Click http mapusoft com contact to senda request to receive licenses and documentation AppCOE provides the ability to generate project files for project files for the following targets e Wind River s Workbench 2 6 3 1 3 3 e LynxOS Luminocity 3 0 5 e MQX Code Warrior 10 x QNX s Momentics 4 x Sun Micro system s Sun Studio Visual Studio NET 2005 Micro Soft s Visual Studio 2006 Micro Soft s Visual Studio Net 2008 Micro Soft s Visual Studio Net 2012 e Eclipse s CDT 4 x e Makefiles After Generating Optimized Target Code select the check box next to Generate a Project File and choose your IDE as shown in Figure 6_27
4. APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL AppCOE Architecture Figure 3 2 AppCOE Architecture Output es ee REPE JTTA Cross OS Development Platform Interfaces OS Changer Porting Kit Interfaces OS Abstractor Linux POSIX Windows PITRON VxWorks Linux POSIX Nucleus In house abstraction uITRON ThreadX in house OS Abstractor NS f Target Specific Simulation and Testing Target Specific Full Package Code Generator di id Host Platform Windows or Linux P Profiler Data Target Platform Target Hardware MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL OS Simulator AppCOE simulates various OS interfaces such as VxWorks pSOS POSIX LINUX Windows ThreadX and Nucleus on host development environments so users can develop embedded code with preferred OS APIs and without the target hardware AppCOE s state of the art Eclipse based IDE offers seamless integration into existing development flows With Application Common Operating Environment AppCOE you can easily port abstract and optimize your code on a host machine and run the application on different target platforms AppCOE leverages the existing OS Changer and OS Abstractor technologies while adding advanced code optimization capacities on multiple OS environments AppCOE provides users an easy to use graphical user interface that is integrated with the Eclipse based CDT environment Target operating
5. MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Import Ada Source files to project 7 On Import Ada Files page enter the Ada source directories using the Browse button as shown in Figure 9_5 Figure 9 5 Import Ada Source files to project 2 Ada C Changer Wizard Import Ada files Select the directory containing your Ada files Ada Source Directories D Examples ADA_App MultiLevelTC1 MultiLevel2 D Examples ADA_App MultiLevelTC2 Main Ada procedure all Enter Ada file extensions used in your Ada project Specify option file MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions for Import Ada Files page are as follows Table 9_1 Field Descriptions for Import Ada Files Field Description Your Action Ada Source Directories The Ada source directories contains Ada source files all object modules and info files created by the Ada Changer and stored in AppCOE Projects Select the Browse Button to add your Ada source directories Select the Remove button to remove any of the Ada Source directories Note To add or remove the source directories after creating the projects go to Project gt Properties gt Ada Changer Main Ada procedure Specifies the main procedure name of the project the user imports that is converted to the main C function that will be started as thread in OS Abstract
6. Options for Maintainers The following options are provided for use by maintainers of the compiler Table 8_3 Options For Maintainers Options Description b The b option causes the message file created by the front end to be retained normally it is deleted as its contents are cryptic The f option forces the generation of intermediate files even if the compiler finds errors The ke option specifies that intermediate files which are normally deleted are to be kept Keep the information file generated by the compiler The information file is generated by default except when the a or c option is used or if the compilation terminates without generating an object module file The ne option specifies that the adacgen process will not be restarted on failure If the ne option is not specified the adacgen process will restart upon severe internal error such as a segment violation bus error or assertion failure The process will restart with the file that was being processed when the failure occurred If the file causes a severe error again adacgen will restart with the next file to prevent infinite reprocessing of that file The nl option specifies that the adacgen process will be restarted with the next file after the file that was being processed when the failure occurred The default behavior without nl is to restart with the file that caused the failure See also ne The nonr option specifies that the compiler
7. Refer to the sample demo applications provided with OS Abstractor as a reference point to start your application Please review the target processor and development tools documentation for additional information including specific details on how to use the compiler assembler and linker MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 6 Using Cross OS Development platform Cross OS Development Platform provides you a robust and industry standard OS interface architecture for flexible application development while allowing the user to protect the software from being locked to one OS Cross OS Development Platform makes your application adapt to multiple operating system reduces cost associated with code maintenance need for learning multiple operating systems and eliminates the risk associated with the OS selection process This chapter contains the following topics About Cross OS Development Platform About OS Abstractor Interfaces Available for OS Abstractor Developing OS Abstractor or Cross OS Application Full Library Package Generator Optimized Target Code Generator Generating Project Files for your Target Inserting Application Code to Run only on Target OS Environment Running AppCOE Generated Code on your Target MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL About Cross OS Development Platform There are three interfaces in the OS Abstractor Interface options providi
8. os init windows c These functions are the various entry functions for the different operating systems This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Windows you could do it here before calling OS Main When optimizing you will need to write an equivalent function for your target operating system os init android c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on android you could do it here before calling OS Main OS init ucos c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on uCOS you could do it here before calling OS Main OS init netbsd c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on NetBSD you could do it here before calling OS Main os application start c This function is the first OS agnostic function and should be the start point for the application development os library init c This function initializes the required Interface products and creates the entry threads for each product os main c
9. I Problems E Console 23 E Properties 5 Debug No consoles to display at this time 6 items selected MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Building Your Project NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Creating an AppCOE C C Project 2 Adding Source Code Files to AppCOE C C Project 3 Select a project under C C Projects pane right click and select Build Project as shown in Figure 4_21 Figure 4_21 Building Your Project New Environment AppCOE ay Is Run Window Help o Into P 0 Q 9 Open in New Window Tools Index Copyright c 2013 M Build Configurations Make Targets Build Project Clean Project os target h Copy Paste Delete Move s kernel functions Rename Import Export Refresh Close Project Run As Debug As Profile As E 0 Entry UNSIGNED arg Validate Convert To E Tesm Console amp E Properties Compare With Restore from Local History Run C C Code Analysis Configure Properties Alt Enter Resource Configurations MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 4 You can view how the binary files are built in Figure 4 22 Figure 4_22 Output for Building Binary Files for a Project Efe Edn Source Refactor Navignie Sepch Bun Project Jools Window Help ri
10. Source Folder Name source MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 6 On Select Configurations window select the platforms and configurations for deployment and click Next as shown in Figure 4_4 Figure 4_4 Configurations Window 2 AppCOE C Project Wizard Select Configurations Select platforms and configurations you wish to deploy on Project type Executable Toolchains MinGW GCC Configurations 4 Release Deselect all Advanced settings Use Advanced settings button to edit project s properties Additional configurations can be added after project creation Use Manage configurations buttons either on toolbar or on property pages MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 7 On Select APIs Interface window select the required AppCOE development APIs and click Finish as shown in Figure 4_5 Figure 4_5 Select APIs Window AppCOE C Project Wizard Select APIs List of API sets available Interfaces Host Library Configuration OS Abstractor Interface APIs will automatically be included for AppCOE C C Projects Select additional development API s used by your application Include OS Abstractor Interface API s F Include POSIX Interface API s Include VxWorks Interface API s Include pSOS Interface API s _ Include Nucleus Interface API s Include ThreadX Interface API s Include
11. The Ada C C Changer output also includes files generated by the compiler or program builder These include e Object module files o or obj and information files info for Ada source files in the program library e Executable files exe for main units in the program library e Optional listing files 1st e Optional cross reference files for use by the cross reference compiler option e Other intermediate files if kept see the ke option Ada C C Changer Library Interaction The Ada C C Changer uses the program library to locate the source files needed to handle semantic dependencies during compilation of a specified source file Some of the situations in which this may occur are the following e To locate a with ed unit or the parent unit for a separate clause or child unit e To locate the library unit specification if any when a library unit body is being compiled To locate the body of a generic if any when the generic is instantiated To locate the body of a subprogram in another library unit to which pragma Inline applies e To locate the body of a stub contained in a subprogram This requires a method for locating a source file from a unit name during compilation This is only required if the needed unit is in a source file that has not yet been analyzed in the current invocation of the compiler Locating the Source File The order of the search for locating a unit during compilation is as follows e First
12. 05 nit works c C OnE windows host Ot jni windowse fj 0i Mir jna e ma j os minc 5 OSPAL win an ad 2 st m a 3547c26 d766b232c45 n a c 25 items selected You have successfully imported your VxWorks application to AppCOE To know more about the project template files go to AppCOE C C Project Template Files MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Method 2 Porting VxWorks Legacy C Code This section explains Porting VxWorks Legacy Applications using AppCOE Porting Plug in A sample porting of VxWorks Legacy application using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Select Tools gt Porting gt VxWorks gt Import Legacy C Code as shown in Figure 5_10 You can also click on the Porting icon from the task bar Figure 5_10 Importing VxWorks Legacy C Code in AppCOE EI Projects Application Common Operating Environment AppC OE File Edit Source Refactor Plevigete Segrch Project Toch Run Window Help A amp 6 0 Qq 5 c E impor Workbench C Project port Legacy C Code 3On nnns DON MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are considering importing a application
13. AppCOE provides users an easy to use graphical user interface that is integrated with the Eclipse based CDT environment Target operating systems supported can be found here http mapusoft com products Full Source Library Package Generator chapter includes the following topics e Generating Full Library Packages e How to Use Libraries With Your Application For more information on full source library package generator refer to Full Library Package Generator Optimized Target Code Generator With Application Common Operating Environment AppCOE you can easily port abstract and optimize your code on a host machine and run the application on different target platforms AppCOE leverages the existing OS Changer and OS Abstractor technologies while adding advanced code optimization capacities on multiple OS environments AppCOE provides users an easy to use graphical user interface that is integrated with the Eclipse based CDT environment Target operating systems supported can be found here http mapusoft com products AppCOE reads application source code to determine the services used by your application and produces OS specific interface code optimized for your specific application and for each target OS platform AppCOE gives you the ability to support multiple OS It is also easily expandable to generate code for your proprietary OS Optimized Target Code Generator chapter includes the following topics e Generating Targ
14. Creating Ada C Changer project Ada C Changer converts Ada 83 or Ada 95 Programs to C Source Code and keeps the C Source Code in Projects From AppCOE main window select any project under C C Projects tab on the left pane 2 Select New gt Ada C Changer Project as shown in Figure 8_2 Figure 8 2 Ada C Changer project Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help EX GOW o0 0 q 59 E Projects New C AppCOE C Project Gi C C Projects 23 AppCOE C Project Ada C Changer Project Ada C Changer Project New Ada C Project New Ada C Project Project Go Into fll demo ada to c Open in New Window C demo cross os Index C demo nucleus Build Configurations C demo posix Make Targets C demo psos Build Project C demo threadx Clean Project C demo uitron D demo vxworks d ind E demo windows See NewAdaC C Sample AppCO nem Example 7 zH Rename 2 amp LB BB Ex Ii sudoku Other Ctrl N import 4 Export Source Folder Folder Source File Header File File from Template Class 3 Copy Paste QLBRRR 1mm mE Refresh Close Project Run As Debug As Profile As Validate Convert To Team Compare With Restore from Local History Run C C Code Analysis NewAdaC Configure Note 1 win32 and gnat compatibility are not supported under
15. Figure 5 3 Importing a VxWorks Workbench C Project in AppCOE Figure 5 4 AppCOE Import Window Figure 5 5 Application Startup Files Window Figure 5 6 Provide Inputs for Projects Window Figure 5 7 Porting Reports Page Figure 5 8 Porting Reports Page Guidelines Figure 5 9 Project Perspective of the Ported Projects Figure 5 10 Importing VxWorks Legacy C Code in AppCOE Figure 5 11 Import Legacy Code Window Figure 5 12 Porting POSIX LINUX Legacy C Code in AppCOE Figure 5 13 Import POSIX LINUX Legacy Code Window Figure 5 14 Importing POSIX LINUX Legacy Code Output Figure 5 15 Porting Nucleus PLUS Applications Figure 5 16 Importing Nucleus Legacy C Code in AppCOE Figure 5 17 Import Nucleus Legacy Code Window Figure 5 18 Importing Nucleus Code Output Figure 5 19 Importing ThreadX Legacy C Code in AppCOE Figure 5 20 Import Threadx Legacy Code Window Figure 5 21 Importing Threadx Code Output Figure 5 22 Importing pSOS Legacy C Code in AppCOE Figure 5 23 Import pSOS Legacy Code Window Figure 5 24 Importing pSOS Legacy Code Output Figure 5 25 Importing micro ITRON Legacy C Code in AppCOE Figure 5 26 Import micro ITRON Legacy Code Window Figure 5 27 Importing micro ITRON Legacy Code Output Figure 5 28 Importing Windows Legacy C Code in AppCOE Figure 5 29 Import Windows Legacy Code Figure 5 30 Importing Windows Legacy Code Output Figure 6 1 Cross OS Development P
16. Figure 6_27 Generating Project Files Optimized Target Code Generator This wizard optimizes target specific source code Target Version SMP UP Kernel Mode User Mode Architecture 32 bit Load settings from Previous V Generate a Project File Project makefile Destination Path c tmp Optimized_code 1 MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Inserting Application Code to Run only on Target OS Environment The user configuration is done by setting up the appropriate value to the pre processor defines found in the cross_os_usr h NOTE Make sure the OS Abstractor libraries are re compiled and newly built whenever configuration changes are made to the cross_os_usr h when you build your application In order to re build the library you would actually require the full source code product version not the evaluation version of OS Abstractor Applications can use a different output device as standard output by modifying the appropriate functions defines in os_target_usr h along with modifying os_setup_serial_port c module if they choose to use the format Input output calls provided by the OS Abstractor You can add some application code or target specific things such as memory allocations such as Heap Size and Shared memory which are specific to target environments Target OS Selection Based on the OS you want the application to be built set t
17. Module Description demo c Contains a sample demo application Building OS Changer ThreadX Interface Before building the OS Changer ThreadX Interface library and or application ensure that the flag INCLUDE OS ThreadX is set to OS TRUE in the cross os usr h configuration file Building OS Changer ThreadX Interface Library The ThreadX Interface library is located at mapusoft ThreadX_interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for ThreadX OS using Eclipse tools and for x86 target then the make file location will be at specific ThreadX lt OS gt x86 eclipse directory Building OS Changer ThreadX Interface Demo Application The demo application is located at the mapusoft demo ThreadX directory location From this location you will find the make files or project files at the appropriate specific OS tools target directory For instance if you need the demo application to be built for ThreadX OS using Eclipse tools and for x86 target then the make file location will be at specific ThreadX lt OS gt x86 eclipse directory OS Changer pSOS Interface The pSOS Interface library contains the following modules Table 5 9 pSOS Interface Header File Module Description psos interface h This header file is required in all of the pSOS source
18. Note Default value is 100 Maximum Protection System Handles Specifies the total number of System handles required by the application Enter the maximum number System Handles Note Default value is 100 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 14 On Debug tab configure the options to your specifications as shown in Figure 6 20 The application will be checked for API usage errors by selecting the check box next to Enable Error Checking Disabling error checking will increase the application performance and reduce your code size Figure 6 20 Debug Tab o Optimized Target Code Generator This wizard optimizes target specific source code Task Process Memory Other Resources Debug Output Devices ANSI Mapping Device I O Interface Enable Debug Output OS DEBUG MINIMAL Ignore Fatal Errors MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Debug tab are as follows Table 6_10 Field descriptions on Debug tab Field Description Your Action Enable Debug Output Specifies if you want to enable the debug output Select the debug output from the dropdown menu OS_DEBUG_VERBOSE print debug info fatal and compliance errors OS DEBUG MINIMUM print minimum amount of debug info OS_DEBUG_VERBOSE Note The default value is OS_DEBUG_VERBOSE
19. Projects Select additional development API s used by your application Include OS Abstractor Interface API s F Include POSIX Interface API s v Include VxWorks Interface API s Include pSOS Interface API s Include ThreadX Interface API s E Include micro ITRON Interface API s E Include Windows Interface API s 8 On Select Host Library Configuration window select OS Abstractor Process Mode if the created application runs in multiple processes as shown in Figure 4_14 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_14 Select Host Library Configuration Window AppCOE C Project Wizard ol els Select APIs im List of API sets available Interfaces Host Library Configuration Select the optional OS Abstractor features to include with your application OS Abstractor Process Mode Enabled t 1 MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL You can see the output as shown in Figure 4_15 Figure 4_15 A Project with multiple Interfaces Output D Projects Application Common Operating E De ft jouce dedu ijeigse Sapch Project pen oc grow jsp ce OX B 6 H O a t3 DD Projects 2 Prote a demo ads to c D derme_cross_os demo D deme C demo D meos C demo mn ows a sa mele aes project 4 HB dudes C Mapuseft ApgCOE einig incluse O C Mapuscft ApgCOL minge Ha gcc mngel2 4 5 2 mchude i9 CMapuseft
20. Specifies if OS Changer Nucleus Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your OS Changer Nucleus Interface APIs MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 7 On Application Functions Profiling tab you can also perform profiling for your specific APIs as shown in Figure 6_14 Figure 6_14 Application Function Profiling Optimized Target Code Generator This wizard optimizes target specific source code Profiler Configuration Platform API Profiling Application Functions Profiling Enter Application Function e g function 1 or function 1 Remove MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Application Functions Profiling tab are as follows Table 6_4 Field descriptions on Application Functions Profiling tab Field Description Your Action Enable Application Specifies if the Select the check box Functions Profiling Application Functions to enable Application Profiling feature is Functions profiling enabled or disabled This profiling is used for User APIs profiling Enter Application Specifies the name of the Enter the name of Function Application Function for the application profiling function NOTE This field is case sensitive Specifies if you want to To add any add any app
21. T Properties Property Valus Average Funchon execution time 6 334 751 601 Nano Seconds Furcticn with the longert exwcubon tme OS Get Current Tak Id Function with the shortest execution time OS Delete Queue Number of Functions called applicabon 3 On the bottom of the window as highlighted the function properties are displayed such as e Average Function execution time e Function with the longest execution time e Function with the shortest execution time Number of Functions called in application MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On the left pane expand the Functions tab It displays the following information as shown in Figure 7_6 e Platform APIs e Application Functions Figure 7_6 Platform APIs and Application Functions Profiter dema cron os zgercel ax init windows hoste Agplicatio Cperatiy Ete Ede Source Refactor Navigate Sepech Project Bue Toots Window Hele nm amp BRE Qa 7 ete TS Debug Projects L3 Profe 9 Profder Data Explorer so Prefer View E profder data 12710343210 System Functions Platform APIS OD Application Functions Threads Function Iterations EFTS Platform APIs Called In Application 244 292 906 Nano Seconds umen Tank 1d Y5 Delete Queue Platform APIs These are all the OS Abstractor Interface functions called in the application On the x axis all the functions are displayed On the y axis all functions iterations are dis
22. and this project becomes a project of that IDE Select the project from the drop down list Destinatio n Path Specifies the path to place the generated optimized target code Click Browse and select the folder to place the generated code MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL If you select an application project AppCOE checks if the application project has any linked in libraries and queries the workspace for any matching library projects If AppCOE finds any libraries then it will install the available libraries on the page as shown in Figure 6_11 All the libraries are selected by default and you can select or deselect any all libraries to export library sources along with the application during code generation process Select the libraries and click Next Figure 6_11 Select the linked in Libraries g This wizard optimizes target specific source code y Optimized Target Code Generator al E2 This application project depends on the following libraries within the current workspace and as such will also be exported along with the application during the code generation process H you prefer not to export any specific library then unselect them Libranes 7 C AppCot_vx libproj Cancel NOTE When you export AppCOE libraries it will skip API Optimization Target Code Generator will contain the following folders files e Application project sources and project mak
23. tp For the changes to take effect Would you like to restart now 10 Check the new features installed correctly from the AppCOE installed directory gt plugins as shown in Figure 2 12 Figure 2 12 Confirmation of new features installed amp plugins File Edit View Favorites Tools Help Q sxx Q amp Search E Folders E B Folder Sync Address CAMapuSoft AppCOE 82 plugins S E Ai Name Size File and Folder Tasks 4 mapusoft appcoe ada 1 3 9 jar 147 KB E Rename this file pss RU i 2 747 KB i mapusoft appcoe generation 1 3 9 jar 460 KB E Move this file a mapusoft appcoe license_1 3 9 jar 30 KB D Copy this file al mapusoft appcoe profiler_1 3 9 jar 463 KB 2 Publish this file to the mapusoft appcoe startup_1 3 9 jar 63KB Web E mapusoft appcoe targe ja 34 689 KB C E mail this file E mapusoft appcoe target 1 3 9 jar 34 689 KB XK Delete this file a net sourceforge lpg lpgjavaruntime_1 1 0 v201004271650 jar 97 KB 4i org apache batik bridge 1 6 0 v201011041432 jar 521 KB 4 org apache batik css 1 6 0 v201011041432 jar 260 KB Other Places es org apache batik dom svg 1 6 0 v201011041432 jar 471KB org apache batik dom 1 6 0 v201011041432 jar 113KB org apache batik ext awt_1 6 0 v20101 1041432 jar 401 KB org apache batik parser_1 6 0 v20101 1041432 jar 61 KB Shared Documents 3i org apache batik pdF_1 6 0 v201105071520 jar 511 KB E My Computer ii org apache batik svggen 1 6
24. Enable Error Checking Specifies if you want to enable the error checking To enable error checking select the check box Use this option to increase performance and reduce code size Note By default this feature is enabled Ignore Fatal Errors Specifies if you want to enable the feature to ignore fatal errors To enable the feature to ignore fatal errors select the check box Note By default this feature is disabled MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 15 On Output Devices configuration tab select your output device from the drop drown list as shown in Figure 6_21 Figure 6_21 Output Devices Tab o Optimized Target Code Generator This wizard optimizes target specific source code Console Output Device MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Output Devices tab are as follows Table 6_11 Field descriptions on Output Devices tab Field Description Your Action Console Output Specifies the console Select the output device from the Device output device for the dropdown menu application OS WIN CONSOLE print to console OS SERIAL PORT print to serial NOTE The default value is OS WIN CONSOLE User can print to other devices by modifying the appropriate functions within usr h and use OS Abstractor Interface s format I O calls
25. If either of these situations arises during source file registration the source files are said to conflict and one of the source files and its units overrides the other depending on whether the registration is explicit or automatic Explicit registration of a source file either by compiling or by the source registration tool overrides any previously registered source files with which it conflicts When a registered source file is overridden it remains in the UNIT MAP but its units are marked as Invalid Source Registration Tool Outputs The source registration tool modifies the UNIT MAP file in the current directory All source registration tool messages are written to standard MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Adacgen The Ada Compiler translates Ada 95 source programs into relocatable object modules and records dependency information for use by the program builder It optionally generates source listing assembly listing and debugger information for use by the symbolic debugger The Ada C C Changer consists of two phases the front end and the back end The front end performs syntactic and semantic analysis It generates C source files as input to the back end The back end of the Ada C C Changer is an ISO ANSIC compiler It performs code generation applies optimizations and generates a relocatable object module Compiler Inputs Invocation adacgen option file The adacgen command invok
26. Import Export Ketresh Close Project Run As Debug As Profile As bperties Validate Convert To Resource Path Location Type Team Compare With Restore from Local History demo cross os W Run C C Code Analysis MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 On AppCOE C C Project Wizard window type a project name and give a location next to Project Name text box 4 Under Project Types expand the Executable menu Select AppCOE Template Project and click Next as shown in Figure 4_2 Figure 4_2 AppCOE C Project Wizard Window AppCOE C Project Wizard Creates AppCOE C Project Project name Sample AppCOE Project V Use default location D MapuSoft appcoe AppCOE_Winx32_Beta2 workspace Sample_A Project type Toolchains 4 Executable MinGW GCC Empty Project AppCOE Template Project Shared Library Static Library Show project types and toolchains only if they are supported on the platform MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 5 On Basic Settings window define the basic properties of your project and click Next as shown in Figure 4_3 Figure 4_3 Basic Settings Window AppCOE C Project Wizard Basic Settings Basic properties of a project Application Name MyApr Application Prefix Author Name Copyright notice Application Copyright Notice Greeting Message Application Welcome Message
27. MapuSoft AppCOE_ 32 workspace demo_cross_os Debug demo_cross_os exi 4 ic os init windows host c 23 a Outline 25 if OS_TARGET OS WINDOWS amp amp OS_HOST OS TRUE ol E DE os application start h main int LPSTR int FUNCTION OS Application Start DESCRIPTION e are the various e d MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL To resume debugging click the resume icon on the debugging window as shown in the Figure 4_37 File Edit Source Refactor Navigate Search Project Run x i i x j E 2 Projects 2 Profiler E Debug f d C 69 Variables 23 9o Breakpoints ro Registers E Modules 4 ad demo cross os exe AppCOE Local C C Application amp st E E 4 AppCOE Supplied GDB 11 11 13 6 39 PM p Thread 1 Running pal C MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 6 39 PM bal C MapuSoft AppCOE_ 32 workspace demo_cross_os Debug demo_cross_os ex 4 A os init windows host c 23 Cl B Outline 32 if OS_TARGET OS WINDOWS amp amp 0S HOST OS TRUE S14 Rwe J os application start h 9 main int LPSTR int FUNCTION OS Application Start DESCRIPTION These are the ur operating add a signal handler n E Console X A Tasks 2i Problems 3 Executables J Memory i En B8 BS ea mi rr emo cross os exe AppCOE Local C C Application C Ma
28. This function initializes the OS Abstractor Interface layer and calls OS Application Wait For End which will suspend until OS Application Free or OS Delete Process is called It also spawns the first OS Independents thread which is the true entry point for OS Abstractor Interface MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The application code starts in the os_library_init c file the user defined entry function and name of the application for OS Abstractor Interface can be specified in define OS ABSTRACTOR BASE ENTRY FUNCTION define OS APPLICATION START TASK NAME For VxWorks Interface the user defined entry function and stack size can be specified in define VXWORKS ENTRY FUNCTION define VXWORKS ENTRY FUNCTION STACK SIZE Similarly this is how it works for all the remaining changers abstractors You can insert code that is only included when they use AppCOE host in the following way For windows host you can insert code in __os_init_windows_host c inside main function before calling OS MAIN that is only included in AppCOE windows host For Linux host you can insert code in os init linux host c inside main function before calling OS MAIN that is only included in AppCOE Linux host You can insert code that is specific to a target OS inside main function before calling OS MAIN in the following way For LynxOS target insertin os init lynxos c For mqx target inser
29. application Task pooling feature enhances the performances and reliability of application If you enable the task pooling feature applications can create OS Abstractor Interface tasks during initialization To enable task pooling feature select the check box MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Description Your Action and be able to re use the task envelope repeatedly To configure task pooling set the following pre processor flag as follows INCLUDE_OS_TASK_ POOLING Default Task Specifies the default Enter the default Task pool Time pool Time Task pool Time slice slice slice NOTE The default value is OS_DEFAULT_TSLICE Default Task Specifies the default Enter the default Task pool pool Timeout Task pool timeout timeout value Value value NOTE The default value is OS_TIME_TICK_PER_SEC 6 11 On Process configuration tab configure the options to your specifications as shown in Figure 6 17 Select the check box next to Enable OS Abstractor Interface Process Feature to allocate the memory from a shared memory region to allow applications to communicate across multiple processes By disabling this option the memory will be allocated from the individual application process specific pool which is created during the OS Application Init function call Figure 6 17 Process Tab Optimized Target Code Generator C t Li This wiz
30. check the UNIT MAP of the program library e Then check the UNIT MAP of each linked library in the order of the library search list Ada Program Builder Library Interaction The Ada program builder uses the Ada program library to locate the object module file and the information file for each unit needed in the main procedure Since the names of these files are based on the source file name the unit to source correlation is required The method used to determine this is similar to that used by the compiler Locating the Information File and Object Module To determine the name of the source file the program builder checks to see if a unit is registered in the program library or any linked library Thus the effective order of the search by the program builder is e First check the UNIT MAP of the program library e Then check the UNIT MAP of each linked library in the order of the library search list Once the source file name is found it may be that the corresponding information and object module files do not exist because the source was never compiled or they are out of date because the source file or some source file on which it depends has changed If the missing or out of date object module belongs to a source file in one of the linked libraries the program build will fail because linked libraries are read only Otherwise the program builder implicitly invokes the Ada C C Changer to create the needed object module and information f
31. s products it will run on the new OS To view the generated full library package a Open the folder created by AppCOE b Click on the folder to view the files included in the package as shown in Figure 6_8 which include A sample application Libraries containing the MapuSoft products needed to run their application on the new OS Figure 6_8 Full Library Package Generation Folder K amp Computer th New Volume C Ea New Volume D gs New Volume E xal Dk F 3 Make sure if your application is built for 32bit architecture OS CPU 64BIT is set as OS FALSE as a command line option Generating Binary Packages NOTE If you want to build a library as a Shared Library use the makefile named makefile s under cross os xxxx specific x86 gnu makefile MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Optimized Target Code Generator AppCOE s Optimized Target Code Generator generates porting and OS Abstractor Interface source code optimized for your application This allows you to create project files This also includes the system settings you chose in the GUI based Wizard Note Before you begin refer to MapuSoft System Configuration Guide This section contains the following topics Generating Optimized Target Code Generating Project Files for your Target Inserting Application Code to Run only on Target OS Environment Running AppCOE Generated Code on your Target Error Reference source not f
32. 0 v201011041432 jar 194 KB 3 My Network Places ai org apache batik transcoder_1 6 0 v201011041432 jar 86 KB 4i org apache batik util gui 1 6 0 v201011041432 jar 161 KB a org apache batik util 1 6 0 v201011041432 jar 99 KB Details A org apache batik xml 1 6 0 v201011041432 jar 41KB org apache commons codec 1 3 0 201101211617 jar 54 KB mapusoft appcoe target E org apache commons httpelient_3 1 0 v201012070820 jar 315 KB Executable Jar File a org apache commons logging 1 0 4 v201101211617 jar 45 KB Date Modified Today ll nrn anarhe Felix nnna rnmmanrd n 8 0 v201108120815 iar szkn November 08 2013 5 30 vs gt Type Executable Jar File Date Modified 11 8 2013 5 30 PM Size 33 8 MB 33 8 MB My Computer D APPCOE Winx32 Final iL My Documents MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Updating Software Using Local Update Site 1 From AppCOE main window select Help gt Check for Updates as shown in Figure 2_13 Figure 2_13 Software Updates Using Local Site stion Comman Operating tavironment AppCOt Fie Edt Sowce Relator Mangete Search Projet Took Run Widow E DW 5 F Help Contents j Search Omya Help Key Aene Ties ond treks Chew Sheets Cresa Support Ticket bad Wew Softw tbat aggin Common Operating Erwironment Appo 2 Check the Available Updates windows that you wish to install and click Next as shown in Figure 2 1 MAPUS ZfFT APP
33. 4 2 sudoku ads 3 SuGola_testadb config pragmas ada m ADALIS UNIT MAP AP 7 items selected MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada Changer project files The Ada Changer project has the following files e Includes This folder contains the header file paths of your project e Ada2CC This folder contains all the files generated by Ada tools Ada Changer Project name This folder contains the Ada Changer project related files e Include This folder contains the Ada Include folder e Info This folder contains information file subdirectory of the program library directory where information files for the object modules are placed e Source This folder contains the converted C C source files If OS Abstractor is integrated then you get a folder init which contains the AppCOE template files NOTE For more information on the Template files refer to AppCOE C C Project Template Files Section in this manual e xref This folder contains the cross referenced files which are generated by the Ada tools adaRoot This folder contains the Ada sources added during your project creation In case you need to add or additional sources you can do so in Project gt Property page gt Ada Source tab of the respective project ADA LIB This contains information describing the configuration of the Ada library UNIT MAP This contains a unit to source mapping for use by the compiler and program
34. 4_11 Figure 4_11 Basic Settings Window n a 2 AppCOE C Project Wizard Basic Settings Basic properties of a project Application Name MyApp Application Prefix Author Name Copyright notice Application Copyright Notice Greeting Message Application Welcome Message Source Folder Name source MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 6 On Select Configurations window select the platforms and configurations for deployment and click Next as shown in Figure 4_12 Figure 4_12 Configurations Window II Select Configurations Select platforms and configurations you wish to deploy on Project type Executable Toolchains MinGW GCC Configurations 8S Debug B5 Release Deselect all Use Advanced settings button to edit project s properties Additional configurations can be added after project creation Use Manage configurations buttons either on toolbar or on property pages amp TTE MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 7 On Select APIs window select the required check box In this example we have shown Nucleus and VxWorks Interfaces API s selected click Finish as shown in Figure 4_13 Figure 4_13 Select APIs Window n 2 AppCOE C Project Wizard A E p o ee Select APIs List of API sets available OS Abstractor Interface APIs will automatically be included for AppCOE C C
35. 64 bit AppCOE Build MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Creating New Ada C Template project New Ada C Template Hello World project converts a Hello World Ada Program to C Source Code and keeps the C Source Code in Projects From AppCOE main window select any project under C C Projects tab on the left pane Select New gt New Ada C Project as shown in Figure 8 3 Figure 8 3 Create Ada C Template Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help tiv a RvB or 0 Q 4 E Projects Profiler Gq C C Projects 3 m ag fW demo ada to c C demo cross os C demo nucleus C demo posix C demo psos C demo threadx Import C demo uitron Export CE demo vxworks C demo windows E Sampie AercOE Pj sudoku Oem a aman AppCOE C Project AppCOE C Project Ada C Changer Project Ada C Changer Project New Ada C Project New Ada C Project Project New Resource Configurations Fl Problems amp Console 2 E Properties CDT Build Console NewAdaC Source Folder Folder Source File Header File File from Template Class 2 Oe Qr Example r 3 73 Other Ctrl N APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Creating Ada C Template project Ada C Template Hello World project converts a Hello World Ada Pro
36. API timing report and Timing comparison report e Platform API Profiling System specific API profiling e Application Profiling User specific API profiling Platforms Supported for App Platform Profiler e VxWorks 6x and VxWorks 5x e Linux 2 4 and Linux 2 6 e LynxOS and LynxOS SE Solaris Unix Windows CE e Windows XP Window 7 amp Windows 8 e QNX For more information on Profiling refer to App Platform Profiler MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 4 Using OS Simulator This chapter contains the following topics List of Available OS Simulators Host Development Environment Creating an AppCOE C C Project AppCOE C C Project Template Files Host System Configuration Creating AppCOE C C Project with Multiple Interfaces Adding Source Code Files to AppCOE C C Project Building Your Project Executing Binary Files Debugging the Demos Supplied by MapuSoft Debugging Using External Console Terminal Inserting Application Code to Run only on Host Environment Updating Project Settings MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL List of Available OS Simulators The following is the list of available OS Simulators e VxWorks e pSOS e Nucleus e POSIX LINUX Linux e uITRON e Windows e ThreadX Host Development Environment Host development needs a proper environment to run and build embedded programs To develop an environment you need the
37. Ada 83 and allows more aggressive inlining N check Suppresses numeric checks The check can be one of e division check e overflow check These checks are described in the RM Using N reduces the size of the code and increases its speed Note that there is a related adacgen option s to suppress all checks for a compilation The noeo option disables optimizations that are performed by the front end The noxr option disables generation of cross reference information by the compiler for use by a browser This is the default Olevel The O option that s an oh not a zero controls the optimizations that are performed by the compiler back end The accepted values for level are none all debug 1 2 and 3 These have the following effect e None disable all optimizer options e All same as O3 e Debug disable optimizations that substantially interfere with debugging No optimizations are specified for the C compiler back end e 1 pass O1 to C compiler back end e 2 pass O2 to C compiler back end e 3 pass O3 to C compiler back end If the O option is not specified Olis passed to the C compiler back end e g gcc of file The of option causes the compiler to read options and file names from the specified file These are processed as though the contents of the file were on the command line pB BE options The pB option passes the specified BE opti
38. Application c C C Attach to Application Mai TEES E C C Postmortem Debugger an bacdiibrnes c C C Remote Application GDB command file gdbinit Browse 9 n Warning Some commands in this file may interfere with the startup operation of the kj Eclipse Data Tools debugger for example run Ej Java Applet Protocol Default v DT Java Application JU JUnit JU JUnit Plug in Test Bi Launch Group OSGi Framework eal Remote Java Application 8 Report Filter matched 17 of 17 items Debugger Options 4 You can change any of the options here and click Apply MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Click Debug to execute debugging using the external console or Terminal You can view the debugging process in your console as shown in Figure 4_36 Figure 4_36 Debugging Output Using External Console Terminal Debug demo cross os source os init windows host c Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Run Window Help WM wav rzAeecwyzR 0 QqQ hs vj Ej Projects Profiler 35 Debug i Y F 69 Variables 3 99 Breakpoints tt Registers E Modules s B Value 2 0x011b2d00 Name 692 argc 4 a Thread 1 Suspended Breakpoint hit 9v argv zai main os init windows host c 85 0x00402f23 ri C MapuSoft AppCOE_x32 mingw bin gdb exe 11 11 13 6 39 PM bal C
39. LIB and UNIT MAP An Ada Changer tools contains two files ADA LIB and UNIT MAP These two files which are located in the project are automatically created the first time the Ada C C Changer is invoked ADA LIB contains information describing the configuration of the library UNIT MAP contains a unit to source mapping for use by the compiler and program builder When the program library is created if a UNIT MAP file already exists in the current directory it will be used for the new program library s UNIT MAP Source Files The Ada source files in the program library include e All Ada source files in the program library directory MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL All Ada source files in directories specified in the program library s source directory list Any other source files which have been registered in the UNIT MAP To be automatically recognized as Ada source files the files in a directory must have one of the following file extensions a ada adb ads bdy dat spc sub You can also use any new extensions of user choice as shown in Figure 9 2 There is no naming restriction for source files explicitly registered Source files in the UNIT MAP of linked libraries are not contained in the current program library but they are visible for read only reference by the compiler and program builder MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Generated Files
40. Location Type l os_library_init c amp Warnings 11 items i 0s main c i Infos 2 items Sample AppCOE Project MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL AppCOE C C Project Template Files To view the AppCOE C C project template files expand the project folder you have just created by clicking on the sign beside the Project name as shown in Figure 4 8 Figure 4_8 AppCOE C C Project Template Files Application Common Opersting E Ele Edk Source Refactor Navigate Segech Bun Project Jools Window Help mie r w 6 H 9 O Q 97 TY O Debug D Projects O Pretter fis C Ce v Projects 1 E demo coss o5 j 02 Wit androide os wet bnux hoste c eu imet bnux c 08 irit lyros int main int argc LPSTR argv 05 init mgcc OS Main os init netbsd c o m pa wt nuckeus c return OS SUCCESS Os init qnc 9 3 A o 2 T pendit os iret thesis u init ucote os init utron c 2 Problems Console Properties Debug Os irt vows or irit windows host c L0 init windowst 905 apphicabon start os Kby inte ca mam c You can view the following template files for your project on the left pane of the window os init linux host c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Linux host y
41. Pipe_ HGFEDCBA Start UNSIGNED argc Task 2 Itera nss 9 Task 8 Iterations 2 Define the name function for the Cr S APIs Nalue read from Queue_ 12345678 define CROSS OS ENTRY FUNCTION OS Application Start Value read from Pipe 0 ABCDEFGH Ure T x Task 2 Iterations 3 s Task 1 Iterations 2 the name of the app on start task Walue read from Queue_ 87654321 define OS_APPLICATION_START_TASK_NAME APPSTART Walue read from Pipe 8 HGFEDCBA Task 2 Iterations 4 Task Iterations 3 2 Nalue read from Queue_ 12345678 OS TASK os application start task id Value read from Pipe_ ABCDEFGH Task 2 Iterati tid of the OS EJ Console 33 4 Tasks ft Problems Executables 0 Memory demo cross os exe AppCOE Local C C Application C MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 8 41 PM Switching to Thread 4068 xe2c New Thread 4068 0x1074 New Thread 4068 xc8c New Thread 4068 xe6c Writable Smart Insert MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Inserting Application Code to Run only on Host Environment The below defines are the system settings used by the OS_Application_Init function Use these to modify the settings when running on the host A value of 1 for any of these will use the default values located in cross_os_usr h When you optimize for the target side code the wizard will create a custom cross_os_usr h using the settings you specify at that time so th
42. Profiler Opening App Platform Profiler Perspective Components on the App Platform Profiler Window Viewing App Platform Profiler Data Generating API Timing Report Generating Timing Comparison Report MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL About App Platform Profiler NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license The App Platform Profiler is an add on to the established AppCOE Eclipse based code migration and API optimization technology and is designed to enable data collection App Platform Profiler offers the following e The data collected by the Profiler provides feedback concerning the utilization of MapuSoft s APIs in the project The reports allow for performance impact analysis by detailing specific API execution time during a particular time period as well as the average and total API execution times It enables you to collect data pertaining to the MapuSoft API s Platform API profiling and profiling user specific functions Application Profiling Users can analyze the data with the included App Platform Profiler graphical viewer which offers area bar line pie and scatter charts as shown in Figure 7_1 Profiler enables you to generate a Timing report to view the performance report for each API App Platform Profiler now enables you to generate Timing Comparison Report This compares two dif
43. Project Template Files Figure 4 9 Creating a Project with Multiple Interfaces Figure 4 10 AppCOE C Project Wizard Window Figure 4 11 Basic Settings Window Figure 4 12 Configurations Window Figure 13 gt Select APIs Windows acie ie beu s Ud pasen a in E d duas a ose E 62 Figure 4 15 A Project with multiple Interfaces Output Figure 4 16 Adding Source Code Files Figure 4 17 Importing Files from Local File System Figure 4 18 Importing Source Code Files from Directory Figure 4 19 Selecting Source Code Files for Importing Figure 4 20 Importing Source Code Files Output Figure 4 21 Building Your Project MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_22 Output for Building Binary Files for a Project Figure 4_23 Executing the Binary File Figure 4 24 Binary Output Figure 4 25 Debugging the Demo Application Figure 4 29 Resume Debugging process Figure 4 30 Debug Demo Application Perspective Figure 4 31 Debug Demo Application Output Figure 4 32 Debug Demo Application Using AppCOE Figure 4 33 Resume Debugging process Figure 4 34 Open Debug Dialog Figure 4 35 Debug Configuration Window Figure 4 36 Debugging Output Using External Console Terminal Figure 4 37 Resume Debugging Using External Console Terminal Figure 4 38 Debugging in Progress Figure 4 39 Updating Project Settings Figure 4 40 AppCOE C C Project Updates Figure 5 1 About OS Changer Figure 5 2 OS Changer Flow Diagram
44. QUEUES 1 define HOST MAX PARTITION MEM POOLS 1 define HOST MAX DYNAMIC MEM POOLS 1 define HOST MAX EVENT GROUPS 1 define HOST MAX SEMAPHORES 1 define HOST USER SHARED REGIONI SIZE 1 OS HOST This flag is used only in AppCOE environment It is not used in the target environment Host mode defines can be modified in os main c file For example modify maximum tasks under host environment in HOST MAX TASKS NOTE You can manually change the values in the Optimized Target Code Generator Wizard Refer to Generating Optimized Target Code chapter in the manual MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Creating AppCOE C C Project with Multiple Interfaces NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license To create AppCOE C C project with multiple interfaces From AppCOE main window select any project under C C Projects tab on the left pane Select New gt AppCOE C C Project as shown in Figure 4 9 Figure 4 9 Creating a Project with Multiple Interfaces File Edit Source Refactor Navigate Search Project Tools Run Window Help m New AppCOE C Project G Projects a E AppCOE C Project Aa Go Into Ada C Changer Project Open in New Window Ada C Changer Project Tools New Ada C Project PE demo ada to xen New Ada C Project E demo cross o Index j Project demo nuxteus Build Configurat
45. Refactor Navigate Search Project Run Tools Window Help Ei BME eo Grvreeror FY Debug 2 Projects Profiler Data Explorer 3 E Profiler View 33 Omma E a profiler_data_1210343810 E System 4 Functions 4 Platform APIS OS Create Event Group 2400000 OS Get Current Task Jd Q Os Frotect 2400000 1800000 Os Set Task Priority OS Get Event Group Jd e OS Get Events OS Create Semaphore OS sleep Task OS Toke semaphore OS Get Semaphore Count OS Give Semaphore OS Delete Semaphore OS Set Events zn E EORI NIROS LISENSER IPERE IIO SIAII AINI LI VOIRIE IIAEO IROL EIEIO ERII IRETE IRIEL RIISIN IEROSIN OS Delete Task OS Create Partition Pool 0 amp OS_Allocate_Partition OS Deallocate Parfition OS_Delete_Parfifion_Poo Os create Queve Instances of OS Create Event Group Function amp Os suspend Tosk X axis shows Api Iteration Thread Name OS Resume Tosk OS Get Queue Jd OS Get Task Id Ed Properties 25 OS Receive From Queue OS_Send_To_Queue Property Value e OS Delete Queue Average execution time 0 002 037 130 Nano Seconds OS Application Free Instance with the longest execution time 1 Task 1 t Application Functions Instance with the shortest execution time 1 Task 1 43 Threads Total number of times function was called 1 1500000 1200000 900000 Time Nano S
46. Remove VxWorks header file references Use the following header files instead of the VxWorks header files include os target h include vxworks_interface h 2 If your application uses any VxWorks APIs that are un supported by Interface then manually port your code using OS Abstractor Interface APIs 3 If your application have a main function then move the necessary code from your main to the the main provided by OS Abstractor Interface in os main c 4 If your application have any assembly code then manually port them to the new OS platform 5 If your application have any interrupt handler code manually port them to the new OS platforms MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 11 In AppCOE C C projects perspective the ported projects are displayed as shown in Figure 5_9 Figure 5_9 Project Perspective of the Ported Projects ris T O0wW 6 NHN 0 Q 97 t 9 Debug 5 Pesects Profiler Hu CCrm Prejects ooo application c os iit windows hoste Cc demo_nucieus demo posa C derno_witron Bn demo viworks D demo windows M eene l sample ada Sample Appl OF Proyect 08 ni adroid c 0s jne linux host Sinclode os car DRE nunc include os t _ ch in lynezs c iro j OLIN mqsc 05 in amp netisd c Ont nuclease eiin qnec riable mot set using default based om executable p ind _ucose r A asta T5512 Ada windows bin Vadabgen exe Bini uitron c
47. Selecting the pal File Extension to Analyze Figure 7 12 Selecting the API to view the Profiler Data Figure 7 13 Generate Timing Report Figure 7 14 Saving the Timing Report Figure 7 15 Generate Timing Comparison Report Figure 7 16 Import PAL File Figure 7 17 Selecting the APIs Figure 7 18 Saving Timing Comparison Report Figure 7 19 Generated Timing Comparison Report Figure 8 1 Ada C Changer project Figure 8 2 Ada C Changer project Figure 8 3 Create Ada C Template Figure 8 4 Create Ada C Template Figure 8 5 Import Ada Files Figure 9 1 Creating Ada C Changer Project Figure 9 2 Ada C C Changer Wizard Figure 9 3 Basic Settings Window for Ada C C Changer Project Figure 9 4 Select Ada C C Changer build configurations Figure 9 5 Import Ada Source files to project MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 9_6 C C Output Page Figure 9_7 Ada Listings Tab Figure 9_8 Ada Messages Tab Figure 9_9 Ada Drivers Tab Figure 9_10 Additional Options Tab Figure 9_11 OS Abstractor Integration Page Figure 9_12 Ada C Project Report Page Figure 9_13 Output for Ada C C Changer Figure 9 14 Build Project Figure 9 15 Building Ada C C Changer project Figure 9 16 Generated exe File Figure 9 17 Ada C C Changer Properties Figure 9 18 Ada C C Changer Property Page MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL List of Tables Table 1_1 Not
48. The GNU Debugger usually called just GDB and named gdb as an executable file is the standard debugger for the GNU software system It is a portable debugger that runs on many Unix like systems and works for many programming languages While working on AppCOE you must use MapuSoft s GNU Debugger called as AppCOE Supplied GDB MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Creating an AppCOE C C Project NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license To create an AppCOE C C project From AppCOE main window select any project under C C Projects tab on the left pane Select New gt AppCOE C C Project as shown in Figure 4_1 Figure 4_1 Creating an AppCOE C Project Los A File Edit Source Refactor Navigate Search Project Toots Run Window Help g r5 gt New AppCOE C Project AppCOE C Project Ada C Changer Project Open in New Window Ada C Changer Project Proj PE demo ada t Toots mulio a PA demo ada to New Ada C Project C demo cross o Index 1 Project C demo_nucteus Build Configurations i E demn_posix Make Targets C demo so Build Project d Clean Project C devo Svenda ean Projec Header File demo uitron Copy File from Template demo vxworkt 1 5 Jste Class D demo window Delete B C C Projects Source Folder Folder Source File txampie Move Rename Other
49. USER MANUAL 10 On Task configuration tab configure the options to your specifications as shown in Figure 6_16 Applications can create OS Abstractor Interface tasks during initialization and will be able to re use the task envelope repeatedly by selecting the check box next to Enable Task Pooling Feature Figure 6_16 Task Tab Optimized Target Code Generator This wizard optimizes target specific source code Task Process Memory Other Resources Debug Output Devices ANSI Mapping Device VO Interface Maximum Task Control Blocks 100 System Time Resolution OS TIME TICK PER SEC 10 Default Timeslice for Standard Tasks OS DEFAULT TSLICE OS TIME TICK PER SEC 10 V Enable Task Pooling Feature Default Taskpool Timeslice OS_DEFAULT_TSLICE Default Taskpool Timeout Value OS_TIME_TICK_PER_SEC 6 NOTE In the current release Task Pooling feature is not supported in ThreadX and Nucleus targets MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Task tab are as follows Table 6_6 Field descriptions on Task tab Field Description Your Action Maximum Task Control Blocks Specifies the total number of tasks required by the application Enter a value NOTE The default value is 100 One control block will be used by the OS_Application_Init function when the INCLUDE_OS_PROCESS option is true System Time Resolution
50. a option is specified compilation will stop after semantic analysis No output is generated C If the c option is specified compilation will stop after the front end No output is generated discard names This option has the same effect as using pragma Discard Names e count The e count option causes the compiler to report only the first count errors The default is 100 eo The eo option enables optimizations that are performed by the front end This is the default ga Generate Ada oriented debugging information The ga option causes the compiler to generate the appropriate code and data for operation with the C debugger but in a way that should cause it to display the Ada source code rather than the C source code Generate C oriented debugging information The gc option causes the compiler to generate the appropriate code and data for operation with the C debugger This MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Options Description option also causes the intermediate C source files to be saved for use as program source files for the debugger providing C source level debugging help or h The help option shows the different options that can be used with the adacgen command late_inlines The late inlines option allows pragma Inline to be specified after a spec less subprogram body This option provides compatibility with
51. confirm the updates Name Version Id a amp Application Common Operating Environment AppCOE 1 3 9 201311081714 mapusoft appcoe 42 AppCOE Host Target Feature 1 3 9 1 mapusoft appcoe host target feature Feature group Size Unknown Details 6 On Available Updates window select the radio button next to I accept the terms in the license agreements and click Finish as shown in Figure 2 18 Figure 2 18 Remote Update Host Target Feature License Available Updates Review Licenses Licenses must be reviewed and accepted before the software can be installed License text For AppCOE Host Target Feature 1 3 9 1 PLEASE READ CAREFULLY THE USE OF SOFTWARE IS SUBJECT TO THE TERMS AND CONDITIONS THAT FOLLOW IF YOU AGREE TO THESE TERMS PLEASE CONTINUE BY PRESSING I AGREE End User License Agreement PLEASE READ CAREFLILLY BEFORE INSTALLING AND USING THE SOFTWARE This End User license Agreement EULA is a legal agreement between you the end user as an authorized representative of the company acquiring the license Licensee and Mapusoft Technologies Inc MTI that governs the use of any MT Software made available by Mapusoft Technologies Inc that is not otherwise subject to a separate physically signed license agreement between Licensee and Mapusoft Technologies Inc The term MT Software means computer software and may include associated media printed materials and documentation RIGHTS IN THE SOFTWARE P
52. file control block structure Note One control block is used when the OS Abstractor Interface driver is opened These settings do not impact the OS setting for max number of files Enter the maximum number of files that can be opened simultaneously Note Default value is 30 Maximum File Name Length Specifies the maximum length of the file name Enter the maximum number of files that can be opened simultaneously Note Default value is Maximum File Path Length 1 Maximum File Path Length Specifies the maximum length of the directory path name including the file name for OS Abstractor Interface use excluding the null char termination Enter the maximum length of the file path Note Default value is 255 This setting does not impact the OS setting for the max path file name Internally Used System Name Path Specifies the temporary directory of the file path Enter the temporary directory of the file path Note Default value is tmp Internal Name Padding Specifies the padding for the internal name Enter the padding for the internal name Note Default value is 20 MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 18 If your project uses pSOS Interface in Interface configuration tab assign the number of unsigned arrays used to store the task s data as shown in Figure 6_24 Figure 6_24 Interface Tab e Optimi
53. files created by the compiler are stored in the AppCOE Projects Since no intermediate compilation form is saved the Ada C C Changer performs a semantic analysis of the appropriate source files as necessary to handle any separate compilation requirements Figure 8 5 Import Ada Files Ada C Changer Wizard Import Ada files Select the directory containing your Ada files Ada Source Directories D Examples ADA_App MultiLevelTC1 MultiLevel2 D Examples ADA_App MultiLevelTC2 Remove Main Ada procedure all Enter Ada file extensions used in your Ada project Specify option file Cancel This source based program library model simplifies the use of the Ada C C Changer and program builder e There are no compilation order requirements for compiling Ada source As long as the Ada source for depended upon units is available it is not necessary to compile them first There are no constraints on the user s approach to file organization or configuration management There are no significant disk storage requirements for the program library beyond that required for the source and object modules MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada Source Directory In Ada Source directory you inform the library of the location of the Ada source for the program The source can be in one directory in multiple directories or in multiple program libraries Once this information is prov
54. for single or multi application development Process Feature support Full Source Library Package generation Generation of project files for your IDE Generated target code is optimized to contain only the APIs used by the application o Allows for further optimization by in lining user selected API s o Enables to convert Ada source code into C C code e Target selection and configuration tabs to optimize the target code specific for your application o Target OS selection o Profiler configuration o Task configuration including a task pooling feature Process configuration including a process feature Memory configuration Resource configuration Debug configuration Output configuration including the ability to output to a console or serial port ANSI Mapping configuration Device I O configuration MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL MapuSoft provides an illustration to describe all the components of AppCOE AppCOE leverages the existing OS Changer and OS Abstractor technologies while adding advanced code optimization capacities on multiple OS environments They are all interlinked and work closely as shown in Figure 3_1 Figure 3_1 AppCOE Components OS Changer Porting Kit OS Simulator Cross OS Development Platform App Platform Cross OS Profiler A p p CO E py Hypervisor Application Common Operating Environment A Linux OK Ada C C Changer MAPUS QJFT
55. front end may release any heap memory to the current heap The nz option initializes all heap memory used by the compiler front end to a nonzero value In hex the nonzero value is BADIBAD1so it is easy to spot in the debugger and causes a Bus Error on a Sparc when it is dereferenced pL L options The pL option passes the specified L options to the lister t The t option generates a trace message as each declaration and statement is passed to the emitter phase of the front end xB exe path The xB option overrides the default back end and uses exe path instead xddir path The xd option overrides the default ADA MAGIC environment variable and uses dir path instead XL exe path The xL option overrides the default lister and uses exe path instead bw This displays all warning messages generated by the Ada C C Changer back end e g by GCC MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Options Description The marked options are already added in Ada C C Changer Do not add these in your additional options tab If you add these options it will break your application Compiler Output Files Files produced by compilations are Table 8_4 Compiler Output Files Output Files Description file info Information recorded during compilation of a source file which is used by the program builder to determine if the object modul
56. in bytes OS MIN STACK SIZE Host Library Configuration OS Abstractor Process Mode Enabled Enter the project name for which you want to import the legacy code in the Project Name text box as shown in the Figure 5_29 Enter the root task prototype like int win_main int argc next to Root Task Prototype text box as shown in the Figure 5_29 Enter the root task stack size next to the Root Task Stack Size text box as shown in the Figure 5_29 The value should be in bytes MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Click Finish to complete the importing of legacy code into AppCOE You can see Windows legacy C code you have imported as shown in Figure 5_30 Figure 5 30 Importing Windows Legacy Code Output File Edit Source Refactor Navigate Search Run Project Tools Window Help ri D OOR BO M 0 Q7i v Ej Debug BD Projects 2 Profiler B C C Projects 3 e al demo_ada_to_c C demo_cross_os C demo_nucleus C demo_posix C demo_psos n demo uitron ed demo vxworks E demo windows C nucleus_legacy ed posix legacy E psos legacy C uitron_legacy 4 C win_Legacy fs Includes iz include 4 G source init 4 source 6 events c l mutex c l os_application_start c ile wait c Problems I Console E Properties 5 Debug 5 10 items selected You have successfully imported Windows legacy code and a project with you
57. located at mapusoft nucleus_interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to MAPUS fFT 119 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL be built for Nucleus OS using Eclipse tools and for x86 targets then the make file location will be at specific nucleus lt OS gt x86 eclipse directory Building OS Changer Nucleus Interface Demo Application The demo application is located at the mapusoft demo_nucleus directory location From this location you will find the make files or project files at the appropriate specific lt OS gt lt tools gt lt target gt directory For instance if you need the demo application to be built for Nucleus OS using Eclipse tools and for x86 targets then the make file location will be at specific nucleus lt OS gt x86 eclipse directory OS Changer ThreadX Interface The OS Changer ThreadX Interface library contains the following modules Table 5 7 ThreadX Interface Header File Module Description threadx interface h This header file is required in all of the ThreadX source modules This header file provides the translation layer between the ThreadX defines APIs and parameters to OS Abstraction The OS Changer ThreadX Interface demo contains the following modules Table 5 8 Nucleus Interface Demo Application File
58. menu To resolve the errors 1 Right click the Project then Select Project gt Properties gt C C General gt Indexer 2 Click Enable Project Specific Settings check box and click Enable Indexer check box Click Apply and OK Optimized Target Code Generation for Ada Projects AppCOE allows Optimized Target Code Generation for Ada C C Changer Projects when the projects are created with OS Abstractor Integration NOTE 1 The project file generated to QNX Momentics 4 x IDE using optimized target does not enable the build variant so you need to manually enable the build variant after importing in the QNX IDE To enable the Build Variant e Select the project and go to Project Properties gt C C General gt QNX C C Project e Select Build variant tab e To enable the build variant select the X86 check box NOTE 2 Check if the Indexer is enabled Generating Optimized Target Code will not work if Indexer is OFF NOTE 3 For all Optimized Target Code Generation the preprocessor OS_HOST flag is set to OS_FALSE If the user intends to do the host development on the optimized target code they need to change this preprocessor flag to OS_TRUE manually NOTE 4 The QNX Momentics IDE has an issue where relative path names are not updated unless there is a modification to the project settings This will cause the initial build of the Full Source version of OS Abstractor to fail since the project files were created in a different location
59. micro ITRON Interface API s E Include Windows Interface API s 8 On Select Host Library Configuration window select OS Abstractor Process Mode if the created application runs in multiple process as shown in Figure 4_6 MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_6 Select Host Library Configuration Window AppCOE C Project Wizard Select APIs List of API sets available Interfaces Host Library Configuration Select the optional OS Abstractor features to include with your application 7 OS Abstractor Process Mode Enabled MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL You can see the output as shown in Figure 4_7 Figure 4_7 Creating AppCOE C C Project Output Bie Ed Source Refactor Navigate Search Project Toots Run Window Help nm I GOR 5O O Q mM 5 Projects Profiler gy ha ed demo windows a 4 C Sample AppCOE Project S Includes B include 4 source os init android c _os init linux host c os iit linux c E C C Projects os init lynxos c osinit mqxc 2 os init netbsd c os init nucleus c os init qnx c O init solaris c os init threadx c os init ucosc os init uitron c OS init vxworks c i os init windows ho Problems Console 1 Properties D os init windows c 0 errors 11 warnings 2 others l os application start c Description s Resource
60. pplication Welcome Message Welcome to Nucleus Interface pplication Copyright Notice Author Name pplication Welcome Message Melcome to OS Abstractor Interface MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Debugging the Demos Supplied by MapuSoft Example Debugging the demo_cross_os application 1 From AppCOE main window select demo_cross_os project Right click on the project and select Debug as gt Local AppCOE C C Application or click on debugging icon as highlighted in Figure 4_25 Figure 4_25 Debugging the Demo Application Ple Edt Source Retactoe Navigate Search Penject Run ook Window Heip rie OX PGCO H 8 O Q 1 D Proti O Protier New Go irto Open in New Window Tech hoe Basld Configurations Make Targets Basid Proact Clean Project Copy Delete Mowe Rename u bepot 3 bpon Fehr Close Project Ran Aa Debug As C 1 AppCOE Local C C Application Profile As f liec C C Application Comet To Team Comgare With Restore feom Local Hatory Propeme D crow ca NOTE If the user uses the Debug dialog to create a new configuration then they need to select AppCOE Local C C Application before creating The other option is to not use the debug dialog but instead select AppCOE Local C C Application from the Debug As menu This method will create the correct configuration automatically 3 After selected the AppCOE Local Application fo
61. started with ulITRON interface support that MapuSoft provides This guide Explains how to applications use uITRON interface port ThreadX Interface Reference Manual Provides detailed description of how to get started with ThreadX interface support that MapuSoft MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL User Guides Description provides This guide Explains how to use ThreadX interface port applications Windows Interface Reference Provides detailed description of how to get started Manual with Windows interface support that MapuSoft provides This guide e Explains how to use Windows interface port applications Release Notes Provides the updated release information about MapuSoft Technologies new products and features for the latest release This document e Gives detailed information of the new products e Gives detailed information of the new features added into this release and their limitations if required Requesting Support Technical support is available through the MapuSoft Technologies Support Centre If you are a customer with an active MapuSoft support contract or covered under warranty and need post sales technical support you can access our tools and resources online or open a ticket at http www mapusoft com support Registering a New Account To register From http www mapusoft com main page select Support Select Regi
62. this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for WINDOWS OS using Eclipse tools and for x86 target then the make file location will be at specific windows lt OS gt x86 eclipse directory Building OS Changer Windows Interface Demo Application The demo application is located at the mapusoft demo_windows directory location From this location you will find the make files or project files at the appropriate specific OS tools target directory For instance if you need the demo application to be built for Windows OS using Eclipse tools and for x86 target then the make file location will be at specific vywindowsV OS XVx86 Veclipse directory We need to have the OS Abstractor Interface Library It has to be included in all the Interface demos Building Application with Multiple Interface Components MapuSoft provides a feature to build application with multiple interfaces For example you can build an application with both Nucleus and VxWorks interfaces Building Application with Multiple Interfaces Before building the multiple Interface library and or application ensure that the corresponding flags are set to OS TRUE in the cross os usr h configuration file For instance If you want to build an application with both Nucleus and VxWorks interfaces set INCLUDE OS NUCLEUS and INCLU
63. to OS Abstractor Interface equivalent functions select the check box Note By default this feature is disabled MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 17 On Device I O configuration tab configure the options to your specifications as shown in Figure 6_23 Figure 6_23 Device Input or Output Tab lo Optimized Target Code Generator This wizard optimizes target specific source code ask Process Memory Other Resources Debug Output Devices ANSI Mapping Device VO interface Maximum Number of Device Drivers 20 Maximum Number of Files 30 Maximum File Name Length EMAXPATH 1 Maximum File Path Length 255 Internally Used System Name Path tmp Internal Name Padding 20 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Device I O tab are as follows Table 6_13 Field descriptions on Device I O tab Field Description Your Action Maximum Number of Device Drivers Specifies the maximum number of drivers allowed in the OS Abstractor Interface driver table structure Note This excludes the native drivers the system since they do not use the OS Abstractor Interface driver table structure Enter the maximum number of device drivers Note Default value is 20 Maximum Number of Files Specifies the maximum number of files that can be opened simultaneously using the OS Abstractor Interface
64. to Threadx sections Changes to Ada C C Project Creation 1 3 9 1 0 1 Changed the Release Number Copyright 2014 MapuSoft Technologies Inc All Rights Reserved The information contained herein is subject to change without notice The materials located on the Mapusoft MapuSoft web site are protected by copyright trademark and other forms of proprietary rights and are owned or controlled by MapuSoft or the party credited as the provider of the information MapuSoft retains all copyrights and other property rights in all text graphic images and software owned by MapuSoft and hereby authorizes you to electronically copy documents published herein solely for the purpose of reviewing the information You may not alter any files in this document for advertisement or print the information contained herein without prior written permission from MapuSoft MapuSoft assumes no responsibility for errors or omissions in this publication or other documents which are referenced by or linked to this publication This publication could include technical or other inaccuracies and not all products or services referenced herein are available in all areas MapuSoft assumes no responsibility to you or any third party for the consequences of an error or omissions The information on this web site is periodically updated and may change without notice This product includes the software with the following trademarks MS DOS is a
65. trademark of Microsoft Corporation UNIX is a trademark of X Open IBM PC is a trademark of International Business Machines Inc Nucleus PLUS and Nucleus NET are registered trademarks of Mentor Graphics Corporation Linux is a registered trademark of Linus Torvald VxWorks and pSOS are registered trademarks of Wind River Systems MAPUS QJFT
66. unsigned content The authenticity or validity of this software cannot be established Do you want to continue with the installation After press ok Installation Continue as shown in Figure 2_10 Figure 2_10 Updating Software b Projects Application Common Operating Environment Imm EY Projects 2 Profiler ESSLI E 2 Hic C C Projects 25 rz N demo ada to c a C demo_cross_os S C demo_nucleus E C demo_posix DL demo psos C demo_threadx B C demo_uitron E C demo_vxworks E C demo_windows Updating Software i Updating Software Downloading mapusoft appcoe root win32 win32 x86 Always run in background Run in Background Cancel Details gt gt 8 Problems El console 23 E Properties No consoles to display at this time Updating Software 40 Once all the features and plug ins have been downloaded successfully and their files installed into the product on the local computer a new configuration that incorporates these features amp plug ins will be formulated Click yes when asked to exit and restart the Workbench for the changes to take effect as shown in Figure 2_11 You have now successfully installed new feature updates to your AppCOE using the Remote Update Site MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 2_11 Restart AppCOE Software Updates You will need to restart Application Common Operating Environment AppCOE
67. will get a project file for the Eclipse IDE and on Linux you will get both Eclipse and make files For all other targets and toolsets you will need to create an RTL library project An application project will be created for the target but it will require some manual modifications to build The modifications which need to be made to the application project are as follows Header Inclusion Add include paths for the Ada RTL component lt target dir gt rtl target dir rtl src target dir rtl IL Add include path for any other C library that you need for your application if your Ada project is integrated with OS Abstractor you will need to add the following target dir include include target dir cross os target include MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada C C Changer Property Page Ada C C Changer Property Page enables you to change or modify the configuration options you have set for your project To go to the property page 1 On AppCOE Projects pane select the Ada C C Changer project you have created Right click on it and select Properties and shown in the Figure 9_17 Figure 9 17 Ada C C Changer Properties L ran Common Operabng Environment Mom d mme n me Fie Edit Sowce Refactor Navigate Search Project Run Too Window Help ri D 090 50 H 5 0 q 9 F3 W Debug 2 Projects 2 Profiler noce i 34 4 ada Come Gh Bi Nen S Incl E 4 s ada Go I
68. z Instances of OS_Get_Current_Task_id called by Task 2 Thread a u ms Property Value Average execution time 0 000 154 892 Nanc Seconds etance with the longest execution bre 6 Inctance with the shortest execution time 12 Thread ID Tesk 2 Total number of times function was called 12 MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Opening App Platform Profiler Perspective From AppCOE main menu click App Platform Profiler perspective button as highlighted Or On AppCOE main menu select Window gt Open Perspective gt Other gt Profiler as shown in Figure 7_2 Figure 7 2 Opening App Platform Profiler Perspective urce os init windows host Application Common Operatin File Edit Source Refactor Navigate Search Project Run Tools Help ri D BRE amp eey New Window Profiler Data Explorer 15 Ej Debug Projects 4 profiler_data_1210343810 o System 4 Functions Platform APIs Q Application Functions El Profiler View 23 New Editor Open Perspective gt Projects Show View Customize Perspective Save Perspective As Reset Perspective 4 Threads Task 1 Task 2 4 Task 3 Platform APIs QO Application m Close Perspective Close All Perspectives Navigation n Preferences Task 4 Task 5 Task 6 Task 7 Function Iterations N w o Ip p Id protect OS Get Events OS Create Tas
69. 1 ioma 280000 4 Platform APIs OS Set Task Prio OS Create Task Qoca a Os Protec Line Chart OS Unprot Bar Chart os Get EV i Area Chart OS Sleep Scatter Chart OS Applic e OS Get EN BA Load Profiler Data File Set d enerate Report os setEv G Rep 6 ba OS Delete IE Generate Comparison Report Task 3 gt Task 4 Task 5 o D e amp Task 6 3 5 1 pL gt amp Task 7 Instances of OS Get Current Task Id called by Task 2 Thread 240000 I lt E Properties 3 Ed ris Property Value Average execution time 0 000 184 892 Nano Seconds Instance with the longest execution time 6 Instance with the shortest execution time 12 Thread ID Task 2 Total number of times function was called 12 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Generating API Timing Report NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license AppCOE now provides you a new feature to view the performance report for each API To generate API Timing Report 1 From the AppCOE main menu go to Profiler perspective and select any Profiler Data on your left pane to generate the report 2 Select Tools gt Generate Report You can also click on Generate Report button ug on the AppCOE Tool bar as shown in Figure 7_13 Figure 7_13 Generate Timing Report P
70. 1011041432 jar Bj org apache batik css 1 6 0 v201011041432 jar org apache batik dom svg_1 6 0 20101 1041432 jar a org apache batik dom 1 6 0 v201011041432 jar a org apache batik ext awt 1 6 0 v201011041432 jar Bj org apache batik parser 1 6 0 v201011041432 jar i org apache batik pdf_1 6 0 201105071520 jar P org apache batik syqgen_1 6 0 201011041432 jar a org apache batik transcoder_1 6 0 v201011041432 jar i org apache batik util qui_1 6 0 v201011041432 jar a org apache batik util_1 6 0 v20101 1041432 jar a org apache batik xml_1 6 0 201011041432 jar Bi org apache commons codec 1 3 0 v201101211617 jar i org apache commons httpclient 3 1 0 v201012070820 jar i org apache commons logging_1 0 4 201101211617 jar ll nra anarhe Felix nnnn rnmmanrd n 8 0 v201108120518 iar BARS 147 KB 2 747 KB 460KB 30KB 463KB 63KB 34 689 KB 34 689 KB 97 KB 521 KB 260 KB 471 KB 113KB 401 KB 61 KB 511 KB 194 KB 86 KB 161 KB 99 KB 41 KB 54 KB 315KB 45 KB 57 KR gt MAPUS ZfFT Type Executable Jar File Date Modified 11 8 2013 5 30 PM Size 33 8 MB My Computer APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 3 AppCOE Components This chapter introduces all the AppCOE components They are as follows Introduction to AppCOE Components AppCOE Architecture OS Simulator OS Changer Porting kit Cross OS development Platform Error Reference so
71. 5 27 Importing micro ITRON Legacy Code Output File Edit Source Refactor Navigate Search Run Project Tools Window Help ri hi wW 505 H 0 Qq 90 Ej Debug BD Projects 2 Profiler Search Ba C C Projects E e al demo_ada_to_c C demo_cross_os C demo_nucleus C demo_posix C demo_psos n demo uitron ed demo vxworks E demo windows C nucleus_legacy C posix_legacy E psos legacy 4 uitron legacy 5j Includes i include 4 source include init 4 source application c Le console c c os application start Problems I Console E Properties 5 Debug 7 10 items selected 10 You have successfully imported micro ITRON legacy C code and a project with your given project name is created in the current workspace MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting Windows Legacy C Code This section explains porting of Windows Legacy Applications using AppCOE Porting Plug in A sample porting of Windows Legacy applications using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Select Tools gt Porting gt Windows gt Import Legacy C Code as shown in Figure 5_28 You can also click on the Porting icon from the task bar Figure 5 28 Importing Windows Legacy C Code i
72. 9494 94 94 9 349949 Suspending Tasks and 1 2 949 949494494 94 94 4394 4 94 9 9 CC CC MCCC Setting the system clock back to zero This has been done 16 times 3 3 ECOCOE ECCE 39 39 39 39 39 39 39 39 9E 3E 9E ECCE Delete and Restart task 2 Note If the user not use the Debug Perspective by click No button from Debug Perspective windows as shown in a Figure 4_26 Debugging the Demo application from AppCOE only as shown in the Figure 4_32 and Figure 4_33 Note Best ways is user should use the Debug Perspective for debugging the demo application because its only helps to views for displaying the debug stack variables breakpoint management MAPUS ZIFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_32 Debug Demo Application Using AppCOE Projects demo_cross_os source _os_init_windows_host c Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help GOQA DO PIBN 0 Q Y Y 7 E C Projects Profiler ie C C Projects 2 Cl os init windows host c 25 zn SHf OS TARGET OS WINDOWS amp amp OS HOST OS TRUE AA demo_ada_to_c C demo cross os demo nucleus LE demo posix LE demo psos C demo threadx D demo uitron LE demo vxworks C demo_windows int main int argc LPSTR argv 0S Main return OS SUCCESS endif 8 Problems EJ Console E Properties Debug 2 4 d demo cross o
73. AL Uninstalling AppCOE To uninstall AppCOE 1 Browse to the installed AppCOE directory and start the Uninstall application For Windows only You can also uninstall AppCOE by selecting Control Panel gt Add Remove Programs Select AppCOE and click Remove There is a possibility of user generated modified files to be left on your AppCOE installation directory If not necessary delete the files manually to remove the files Supported Host Platforms AppCOE supports the following host platforms e Windows XP 7 8 e Linux Supported Development APIs Cross OS OS Abstractor Interface supports Windows 2000 Windows XP Windows CE Windows Vista Android Linux MQX NetBSD Nucleus PLUS QNX Solaris ThreadX amp uCOS micro ITRON VxWorks ecos T Kernel LynxOS LynxOS QNX UCOS target operating systems Cross OS OS Abstractor POSIX LINUX Interface Cross OS OS Abstractor UITRON Interface OS Changer Nucleus Interface OS Changer pSOS Interface 1 4 Revision amp 2 x Revision OS Changer ThreadX Interface OS Changer VxWorks Interface OS Changer Windows Interface For a list of AppCOE supported target operating systems click here www mapusoft com Getting a License for AppCOE AppCOE is licensed by the following host and target licenses A 30 day advanced evaluation license is available for the host licenses Click www mapusoft com downloads to request an evaluation license MAPUS fFT APP
74. ANUAL Generating Timing Comparison Report NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license AppCOE now provides you a new feature to view the comparison of two different performance reports for the APIs You can generate a timing comparison report only when the following preconditions are met e Both the PAL files must have the same project name e Both the PAL files must have a profiling time less than 5 minutes Note Do not generate PAL files within 60 seconds To generate Timing Comparison Report From the AppCOE main menu go to Profiler perspective and select any Profiler Data on your left pane to generate the report Select Tools gt Generate Comparison Report You can also click on Generate Comparison Report button on the AppCOE Tool bar as shown in Figure 7_15 Figure 7_15 Generate Timing Comparison Report ile Edit Navigate Search Project Run Took Window Help Cis m E 9 Projects Profiler Profiler Data Explorer 5 3 lal 4 profiler data 20131112116 System 4 5 Functions 4 D Platform APIs Q OS Create Task OS Get Current Task Id OS Aquire Protection OS Release Protection OS Get Current Process Ic OS Create Semaphore OS Get Events OS Create Pipe OS Create Queue OS Create Event Group INT OS Get Semaphore Id INI OS Get Queue Id INI OS Get Pipe Id OS T
75. ApsCOE eine Waco mnge12 4 5 2 nclude fined D C Mapuscft App COE glugims mapuncft appccehost 1 33 mclude cross ot wndowi nclude iS C Mapuseft ApgCOE glugies mapusoft appooe hot 1 lude nciude Qt Cu Mapuscft ApgCOE plugins mapunctt appece hort 1 3 mclude cucean intedace nciude LS C Mapusoft ApgCOE glugins mapusoft appcoeost 1 3 7 wcludesveworts mterface wclude werple_sbi_project incude O sure Q9 include f Problems D Corsote C Properties No consoles to display at this time 2 term selected MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Adding Source Code Files to AppCOE C C Project NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license To add source code files 1 Select a project under C C Projects pane 2 Right click on it and select Import as shown in Figure 4 16 Figure 4 16 Adding Source Code Files e Projects demo cross i tin ai DER a DRM rr ai jr aid iN S AMA C1 r A ec Bep criait File Edit Source Refactor Newigate Search Fun Project Toots Window Hep Cts OX 9O M O Q S7 Tj Debug 13 Projects O Protter ss CIC Proyocts c apelication c es nit wndows hoste New Ge inte Open im New Window Tools ides Buld Configurations Make Targets Build Project Clean Project Copy Delete Move Rename Properties T Debug y impot 5 bport Refresh Close Project Run As D
76. Build Selected File s Team Compare With Replace With Properties Alt Enter MAPUS ZfFT Default Binary File Editor Text Editor System Editor In Place Editor Default Editor Other nsole 23 E Properties tS Debug 4 F 3I L8 I5 Alea m 0 roject sage length 0 m32 osourceV os init qnx o source _os_init_qnx c 1 3 8 BuildTemp 22May2012 plugins mapusoft appcoe host 1 3 7 1ib windows abs project exe source os main o source os library init o ication start o sourceV os init windows host o sourceNV os init windows o it vxworks o sourceN os init uitron o sourceM os init ucos o it threadx o source __os init solaris Pre source __os init qnx 0 it nucleus o source _os_init_netbsd o source _ os init_mqx o it lynxos o SourceNV os init linux host 0 source __os init linux o it android o lvxworks interface lnucleus interface lcross os lwinmm for project sample abs project k 17366 ms APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 This approach always will fork a terminal to view the output as shown in Figure 4 24 Figure 4_24 Binary Output CENT a CAMapusoft AppCOE Workspace Vsample abs projectiDebug sample abs pmjetee 00 6s Application Copyright Notice Author Name Application Welcome Message Welcome to OS Abstractor Interface Application Copyright Notice Author Name Application Welcome Message Welcome to UxMorks Interface pplication Copyright Notice Author Name
77. C C Changer project with the default all option for the Main Ada Procedure Name To do Ada C C Changer Build do the following steps To generate the corresponding executable right click on the project you have created on the projects pane and select Build Project in project or from the main menu select Projects gt Build project as shown in Figure 9 14 Figure 9 14 Build Project LI Projects Application Co PD Proje Applicat a File Edit Source Refactor Navigate Search Project Run Tools Window Help m amp 90W 900o0 HB 0O QqQ Ej Debug DB Projects 2 Profiler E C C Projects 3 nm les 4 A Ada Su7 fe Inch New 4 amp ada Go Into 4i Open in New Window al Tools Index Build Configurations Make Targets l Build Project 4 Gm ada Clean Project Sip Co e Py e Paste fa ADA X Delete j UNI Move demo R ename C demo C demo_t g Import demo 1A Export C demo FS demo_ Refresh C demo_ Close Project C demo C nucleus Run As C posix_le Debug As D psos_le Profile As le 22 E Properties Debug Bsn eer C win Lei Team n 4 020 1994 2010 SofCheck Inc All Rights Reserved Compare With E Tools Ada windows bin adacgen exe key 89185fda16d923abce377034e56b4750 Restore from Local History E Tools Ada windows bin adacgen exe key 89185fda16d923abce377034e56b4750 E Tools Ada windows bin adacgen exe key 89185fdai16d923abce377034e56b4750 Prop
78. C library Services used inside your application software are extracted from the OS Abstractor libraries and are combined with the other application objects to produce the complete image OS Changer is graphically represented in the follow as shown in Figure 3_3 Figure 3_3 OS Changer Porting kit Your Application 2SCHANGER OS Abstractor Porting Kit your OS For more information on the host development refer to OS Changer MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Cross OS development Platform Developing a solid software architecture that can run on multiple operating systems requires considerable planning development and testing as well as upfront costs associated with the purchase of various OS and tools to validate your software MapuSoft s OS Abstractor is an effective and economical software abstraction alternative for your embedded programming By using OS Abstractor your embedded application can run on many real time RTOS and non real time operating systems to negate any porting issues in the future when your platform changes Target operating systems supported can be found here http mapusoft com products OS Abstractor interface provides you a robust and standard OS interface architecture for flexible application development and portability while eliminating the risks associated with selecting an OS and dependency on a single vendor OS Abstractor makes your application adapt to multipl
79. Changer POSIX LINUX Interface The OS Changer POSIX LINUX Interface library contains the following modules MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Table 5 3 Posix Interface Header File Module Description posix interface h This header file is required in all of the POSIX LINUX source modules This header file provides the translation layer between the POSIX LINUX defines APIs and parameters to OS Abstraction The POSIX LINUX Interface demo contains the following modules Table 5 4 POSIX LINUX Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer POSIX LINUX Interface Before building the POSIX LINUX Interface library and or application ensure that the flags INCLUDE OS POSIX is set to OS TRUE in the cross os usr h configuration file Building OS Changer POSIX LINUX Interface Library The OS Changer POSIX LINUX Interface library is located at mapusoft posix_interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for POSIX LINUX OS using Eclipse tools and for x86 targets then the make file location will be at specific posix lt OS gt x86 elipse directory Building OS Changer POSIX LINUX Interface Demo Application The demo application is located at t
80. DE OS VXWORKS as OS TRUE Developing Applications with Multiple Interfaces The steps for developing applications on host targets are described as follows 1 Include os target h in all your application source files 2 Set the appropriate compiler switches within the project build files to indicate the target OS and other target configurations Initialize the OS Abstractor library by calling OS Application Init function If you are also using POSIX LINUX Interface then also use OS Posix Init function call to initialize the POSIX LINUX component as well For instance to develop an application with both Nucleus and VxWorks application development go to os library init c and give your appropriate entry function in NUCLEUS ENTRY FUNCTION Define the name of the Nucleus entry task The MAPUS fFT 122 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL default entry task is NU_ROOT Give your appropriate entry function in VXWORKS_ENTRY_FUNCTION You also have to give the appropriate stack size for your entry function in VXWORKS_ENTRY_FUNCTION_STACK_SIZE The default stack size given by MapuSoft is OS_MIN_STACK_SIZE In the main thread call OS_Application_Wait_For_End function to suspend the main thread and wait for application re start or termination requests 4 Compile and link your application using development tools provided by Mapusoft 5 Download the complete application image to the target system and let it run
81. E Default value is Oxffffffff Bytes Stack Size for the Main Process in kilobytes Specifies the stack size for the main process in Kilobytes Enter the stack size for the main process NOTE Default value is 1024 200 Kilobytes Heap Size for the Main Process in kilobytes Specifies the heap size for the main process in Kilobytes Enter the heap size for the main process NOTE Default value is 1024 400 Kilobytes Task priority for the Main Process Specifies the task priority for the main process Enter the task priority for the mail process NOTE Default value is O Task Preemption Mode for the Main Process Specifies the preemption status of this task Enter the task preemption status of the task NOTE The parameters are OS PREEMPT Task can be pre empted by the system OS NO PREEMPT Task cannot be pre empted valid MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 12 On Memory configuration tab configure the options to your specifications as shown in Figure 6_18 Figure 6_18 Memory Tab n Optimized Target Code Generator This wizard optimizes target specific source code Task Process Memory Other Resources Debug Output Devices ANSI Mapping Device O Interface Maximum Variable Memory Pool Control Blocks 100 Maximum Fixed Memory Pool Control Blocks 100 Maximum Tiered Memor
82. ER MANUAL Porting Applications from Nucleus PLUS Legacy Code to Target OS In most applications using Nucleus OS Changer is straightforward The effort required in porting is mostly at the underlying driver layer Since we do not have specific information about your application it will be hard to tell how much work is required However we want you to be fully aware of the surrounding issues upfront so that necessary steps could be taken for a successful and timely porting This section provides porting guidelines in a flow chart format This covers issues relating with Nucleus OS Changer device drivers interrupt service routines etc It is possible that we have not addressed all your application specific issues in the flow chart so for further information contact MapuSoft Technologies Figure 5_15 Porting Nucleus PLUS Applications Porting Nucleus PLUS Applications to Linux Guidelines Chart A Kernel APIs interrupts and device drivers g N START M 7 CHECK 1 s P Ru mplement the your application uses kernel APIs that unsupported APIs are un supported in Yes i Nucleus PLUS OS Changer mr No p E dii CHEK 6s your application uses kernel APIs that__ Modify your are partially supported by gt Yes application to Nucleus PLUS OS Changer ue icio pe AA E es your application configure the tar Modify the target OS hardware differently than default setup in Yes BSPs to the desired Te Nucleus
83. GO o0 HN 9 0O qQ TS Debug Proyects Protiter L Ade sudotu C demo conss os demo nucleus demo poro D derno_psos C demo uitron demo veworks demo windows 4 sample abs project 2 bisis 39 sample abs project ese 36 le sj Inchades D inckode source i Debug 1 Problems E Comole 7 T Properties Debug ema C Buid zamole abs project Wall c tressage length 0 JJ omcurce os init qnx o scurce te o3 init linux o rface icross cos lwiremm sample abs project Debug sample abs peorect exe MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Executing Binary Files To execute the binary in Windows host Select Project that you have created Select the Binary file right click and select Open With gt System in Figure 4_23 Editor as shown Figure 4_23 Executing the Binary File ication File Edit Source Refactor Navigate Search Run Project Tools Window Help wi lm 99W 95 HM 0 q E Debug B Projects o Profiler ice Projects 3 I 5 Ada Sudoku E demo cross os C demo_nucleus E demo posix C demo_psos E demo uitron C demo_vxworks C demo_windows 4 C sample abs p 4 gt Binaries 35 sample fa Includes include source Debug New Open Open With Tools Make Targets Copy Paste Delete Move Rename Import Export Refresh Add Bookmark Run As Debug As Profile As Clean Selected File s
84. Indicates a situation that might result in loss of data or software damage Table 1_2 defines the Text and Syntax conventions used in this manual Table 1_2 Text and Syntax Conventions Convention Description Courier New Identifies Program listings and Program examples Italic text like this Introduces important new terms Identifies book names Identifies Internet draft titles COURIER NEW ALL CAPS Identifies File names Courier New Bold Identifies Interactive Command lines MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL MapuSoft Technologies and Related Documentation Reference manuals can be provided under NDA Click http mapusoft com contact to request for a reference manual The document description table lists MapuSoft Technologies manuals Table 1_3 Document Description Table User Guides Description System Configuration Guide Provides detailed description on the system configuration to work with MapuSoft products This guide e Describes the system requirements and configurations to get started with MapuSoft Technologies products AppCOE Quick Start Guide Provides detailed description on how to become familiar with AppCOE product and use it with ease This guide Explains how to quickly set up AppCOE on Windows Linux Host and run the demos that came along AppCOE OS Abstractor Reference Manu
85. Is and parameters to OS Abstraction The OS Changer VxWorks Interface OS Changer OS Changer VxWorks Interface demo contains the following modules Table 5 2 VxWorks Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer VxWorks Interface Before building the VxWorks Interface library and or application ensure that the flag INCLUDE OS VxWorks is set to OS TRUE in the cross os usr h configuration file Building OS Changer VxWorks Interface Library The VxWorksInterface library is located at mapusoft vxworks interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for VxWorks OS using Eclipse tools and for x86 targets then the make file location will be at specific vxworks lt OS gt x86 eclipse directory Building OS Changer VxWorks Interface Demo Application The demo application is located at the mapusoft demo vxworks directory location From this location you will find the make files or project files at the appropriate specific OS tools target directory For instance if you need the demo application to be built for VxWorks OS using Eclipse tools and for x86 targets then the make file location will be at specific vxworks_interface lt OS gt x86 eclipse directory OS
86. LICATION COMMON OPERATING ENVIRONMENT USER MANUAL Installing License for AppCOE MapuSoft provides a license key to the customers Once the customers provide the Mac Address of their system MapuSoft Technologies provides a License key for that particular system This establishes security for the license To install the license Save the license file given to you by MapuSoft On AppCOE main menu click the down arrow next to Key button and select Install License as shown in Figure 2_1 Figure 2_1 Importing License Proyects Application Common Operating Enst File Edi Source Refactor Navigate Search Run Project Tecls Window Help HE t 50 9 0 q fj SF Debug C Projects O Prof Get License Instead Leene f Problems O Console 7 Properties Debug MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 Browse to the location of the saved license file click Open as shown in Figure 2_2 The license key is installed and now you can work on AppCOE Figure 2_2 Selecting the Saved License File Choose lic extension file to import Look in O license E license _20090320_12_39_00 lic File name bcense_20090320_12_33_00 My Network Files of type k MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Updating APPCOE Getting Updates for AppCOE NOTE This feature requires AppCOE Host License Click http www mapusoft com contact to send a request to receive licenses and documentation
87. LICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 2 14 AppCOE Software Updates Available Updates Available Updat Df vailable Updates 4 Check the updates that you wish to install 5 Name version Id St Application Common Operating E 1 3 9 201311081714 mapusoft appcoe Select All Deselect All Details On Updates sites to visit window select Add and browse for the folder provided by MapuSoft named as mapusoft AppCOE updatesite and click OK as shown in Figure 2 15 NOTE If the system does not allow you to give the same site name select the previous update site folder from the list and click Remove Or you can also save the Update site folder in any other location on your local disk Figure 2 15 Installing Updates by Using Local Update Site An dhe uero dre pn Ce ekigwers iot Decr MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On Edit Local Site pop up window next to Name text box provide a different name and click OK The name can be any name that is not already present on the list as shown in Figure 2_16 and click OK Figure 2 16 Available Software Sites Preferences Available Software Sites General i Ant E C C Data Management Help 5 Install Update Automatic Updates Available Software Stes if Java if Plug in Development i Report Design amp Run Debug Team Validation d XML type filter text i Location AppCOE U
88. MAPUS QFT APPLICATION COMMON OPERATING ENVIRONMENT APPCOE USER MANUAL Release 1 3 9 1 Copyright c 2014 MapuSoft Technologies 1301 Azalea Road Mobile AL 36693 www mapusoft com APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Table of Contents Chapter 1 About this Guide Objectives Audience How to Use This Manual MapuSoft Technologies and Related Documentation Requesting Support Registering a New Account Submitting a Ticket Live Support Offline Documentation Feedback Chapter 2 Introduction to AppCOE About AppCOE Installing AppCOE Uninstalling AppCOE Supported Host Platforms Getting a License for AppCOE Installing License for AppCOE Updating APPCOE Getting Updates for AppCOE Updating Software Using Remote Update Site Updating Software Using Local Update Site Chapter 3 AppCOE Components Introduction to AppCOE Components AppCOE Architecture OS Simulator Cross OS development Platform Full Library Package Generator Optimized Target Code Generator Ada C C Changer App Platform Profiler Chapter 4 Using OS Simulator List of Available OS Simulators Host Development Environment Creating an AppCOE C C Project AppCOE C C Project Template Files Host System Configuration Creating AppCOE C C Project with Multiple Interfaces Adding Source Code Files to AppCOE C C Project Building Your Project Executing Binary Files Debugging the Demos Supplied by MapuSoft Debugging Using External Console Terminal Insertin
89. NT USER MANUAL You can do any one of the following e To suppress all checks in generated C code select the radio button Specifies if you Note By default this is enabled Checks want to select the To suppress numeric overflow checks in corresponding generated C code select the radio checks needed button To include all run time checks in generated C code select the radio button Limit on Specifies the length the length of the line in the of the generated C Source generated files C Source You can change the Line length as required Enter a value to specify the length of the line in the generated C Source files Note The default value is 80 8 On Ada Listings tab set your listing options as shown in the Figure 9 7 Figure 9 7 Ada Listings Tab Ada C Changer Wizard Configuration options Set your configurations for Ada C C Changer tool C C output Ada listings Ada messages Ada drivers Additional Source listing D Source listing only if errors Always produce source listing Source listing format Pagination Continuous source listing Paginated source listing Page length 66 Page width 80 Cross reference listing No cross reference listing Produce cross reference listing mimm MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Ada Listings tab are as follows Table 9_3 Field Descriptions fo
90. NVIRONMENT USER MANUAL Porting POSIX LINUX Legacy C Code This section explains Porting POSIX LINUX Legacy Applications using AppCOE Porting Plugin A sample porting of POSIX LINUX Legacy applications using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license To port a sample POSIX LINUX legacy application 1 Select Tools gt Porting gt POSIX LINUX gt Import Legacy C Code as shown in Figure 5_12 You can also click on the Porting icon from the task bar Figure 5 12 Porting POSIX LINUX Legacy C Code in AppCOE O Projects Application Common Opersting Environment ApeCOE Ete fet Source Refector Newgate Search Project Toots Bun R gt p a aje 228 aan 3 t C C E p C E C MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5_13 Figure 5 13 Import POSIX LINUX Legacy Code Window Import Posix Legacy Code Select a Directory to Import Posix Legacy Code into AppCOE 9 Import Application Project Import Libr
91. OMMON OPERATING ENVIRONMENT USER MANUAL 3 Browse to your saved profiler data file and click Open as shown in Figure 7_11 Figure 7_11 Selecting the pal File Extension to Analyze Choose the pal extension file to analyze R f gO amp gt Computer New Volume C b Organize New folder mame WW Favorites 4 MapuSoft 3 Libraries 4s mgc 4 MinGW amp Computer MSOCache fi New Volume c d PerfLogs gx New Volume D 4 profileData is New Volume E d Program Files x Local Disk F 4 Program Files x86 Es Work H ProgramData Es backup E d Users ex MAPUSOFT 86 Ji Windows profiler data 1210343810 pal th Network ws n Filename profiler data 1210343810 pa pal Open M MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 4 Select an API to view the data and right click on Profiler Data Explorer tab to view the different graph options as shown in 5 Figure 7_12 NOTE You can select an appropriate graphical viewer to view your profiler data You can view the profiler data in a line chart bar chart area chart or a scatter chart Figure 7_12 Selecting the API to view the Profiler Data pplication Common Operating Environment AppCOE File Edit Navigate Search Project Run Tools Window Help ri BD BENE arier x EO Project Profiler Data Explorer 25 Profiler View 3 4 profiler data 12103431 System lt gt Functions 4 gt Threads Q Task
92. ON COMMON OPERATING ENVIRONMENT USER MANUAL Components on the App Platform Profiler Window App Platform Profiler window contains two panes The left pane has three Profiler components listed and on the right pane you can view the respective details and information in a graphical view The three main components of App Platform Profiler are Profiler Data File This is the generated profiler data file You can view the performance report of each API A profiler data file is saved as a pal file extension It has the following three components 1 System This displays the system details of your application as shown in Figure 7 4 If you select System tab you have the following details which are displayed on the right pane as shown in Figure 7 4 e Application Info Application property values e Profiler Configuration Profiling Application values Figure 7 4 App Platform Profiler System Details Dreier dema on cs soeroti on in windows hotte Application Common Operstin Efe Edk Source Refactor Navigate Sech Project Bue Tools Window Help ri BAB a Dp T Debug A Projects fe Profiler ke Protter Data Explorer i T Properties 4 profder data 1710343210 fucet Valve System a Application Info Functions ANSI format 10 Destied 3 Threads Dnstied Task 1 A Enabled p Task 2 D i on lew Enabled Platform APIs S Enabled Tesk 3 Enabled Task 4 wx 4 ce Dinabled O Task 5 imum memory pool segm
93. OS Interface micro ITRON Interface Windows Interface MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL d Select the destination path to save the generated package and click Finish as shown in Figure 6_6 Figure 6_6 Select Destination Path Full Library Package Generator Choose a destination path and select finish to generate your package Destination Path D Full_Lib MAPUS FT e APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The successful library package generation is shown in Figure 6 7 Figure 6 7 Full Library Package Generation Verification Report D Porting Report Displays the Information about different activities in Standalone Generation Create Target Directory Status SUCCESS Description Creation of D Full_Lib target directory was successful Windows OS Abstractor Generation Status SUCCESS Description Standalones Generated for Target OS Windows Successfully Posix Generation Status SUCCESS Description Posix Source Generated for Target OS Windows Successfully Nucleus Generation Status SUCCESS Description Nucleus Source Generated for Target OS Windows Successfully MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Show the Full Library Package Created by AppCOE The full library package includes libraries with full source code to manually link into the applications Once the application is recompiled with MapuSoft
94. OS_TIME_TI CK_PER_SEC Specifies the system clock ticks not hardware clock tick For example when you call OS_Task_Sleep 5 you are suspending task for a period S OS_TIME_RESOLUTI ON Enter a value NOTE The default value is 10000 micro second 10milli sec This value is derived from the target OS If you cannot derive the value refer to the target OS reference manual and set the correct per clock tick value NOTE Since the system clock tick resolution may vary across different OS under different target it is recommended that the application use the macro OS_TIME_TICK_PER_SEC to derive the timing requirement instead of using the raw system tick value in order to keep the application portable across multiple OS Default Time slice for Standard Tasks OS_DEFAUL T_TSLICE Specifies the default time slice scheduling window width among the same priority pre emptable threads when they are all in ready state Enter a default time slice for standard tasks NOTE The default value is 10 ms If system tick is 10ms then the threads will be scheduled round robin at the rate of every 100ms NOTE On Linux operating system the time slice cannot be modified per thread OS Abstractor Interface ignores this setting and only uses the system default time slice configured for the Linux kernel Enable Task Pooling Feature Specifies if the Task pooling feature is enabled for this
95. Other Resources tab Field Description Your Action Maximum Pipe Control Blocks Specifies the total number of pipes for message passing required by the application Enter the maximum number pipe control blocks NOTE Default value is 100 Maximum Queue Control Blocks Specifies the total number of queues for message passing required by the application Enter the maximum number queue control blocks NOTE Default value is 100 Maximum Mutex Control Blocks Specifies the total number of mutex semaphores required by the application Enter the maximum number mutex control blocks NOTE Default value is 100 Maximum Semaphore Control Blocks Specifies the total number of regular binary count semaphores required by the application Enter the maximum number semaphore control blocks NOTE Default value is 100 Maximum Event Group Control Blocks Specifies the total number of event groups required by the application Enter the maximum number event group control blocks NOTE Default value is 100 Maximum Timer Control Blocks Specifies the total number of application timers required by the application Enter the maximum number timer control blocks NOTE Default value is 100 Maximum Protection Control Blocks Specifies the total number of Protection Control blocks required by the application Enter the maximum number Protection control blocks
96. PLUS target configuration No p CHECK 4 Se Port the device driver E m using Nucleus PLUS based routines to target OS or esas modify application to use i device drivers inc target OS drivers instead CHECK 5 sm using interrupt service routines t are not part of the Nucleus PLUS based device drivers Make changes if needed to make them to work under target OS n TN Happy Portin H Ppy g MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting Nucleus Legacy C Code This section explains Porting Nucleus Legacy Applications using AppCOE Porting Plugin A sample porting of Nucleus Legacy application using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Select Tools gt Porting gt Nucleus gt Import Legacy C Code as shown in Figure 5 16 You can also click on the Porting icon amp from the task bar Figure 5 16 Importing Nucleus Legacy C Code in AppCOE LI Projects Application Common Operating Environment amp pp COE Eile Edit Source Refactor Mavegete Search Project I 1 p w 05285583 nO90 0000 4 n 3 MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are
97. Project MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 5 Using OS Changer Porting Kit This chapter contains the following topics About OS Changer Interfaces Available for OS Changer Using OS Changer Error Handling Porting VxWorks Applications Porting a WindRiver Workbench C Project Porting VxWorks Legacy C Code Manually Porting Legacy Applications using Import Feature Porting POSIX LINUX Legacy C Code Porting Applications from Nucleus PLUS Legacy Code to Target OS Porting Nucleus Legacy C Code Porting Threadx Legacy C Code Porting pSOS Legacy C Code Porting micro ITRON Legacy C Code Porting Windows Legacy C Code Building OS Abstractor Interface Library OS Changer VxWorks Interface OS Changer POSIX LINUX Interface OS Changer Nucleus Interface OS Changer ThreadX Interface OS Changer pSOS Interface OS Changer micro ITRON Interface OS Changer Windows Interface Building Application with Multiple Interface Components MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL About OS Changer OS Changer allows you to reuse the code on any new OS without having to rewrite or port your code This saves time and money by reducing the porting effort OS Changer provides extensive support to various common proprietary libraries widely used by the application developers Further developers can use the native TARGET OS interface as we
98. Projects with the Real time OS Abstractor Scheduling will include OS Abstractor Features Note 1 If Real time OS Abstractor Scheduling option is selected then proceed to next step Note 2 If Ada C C Scheduling option is selected then skip step 5 On Basic Settings window define the basic properties of your project and click Next as shown in Figure 9_3 MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 9 3 Basic Settings Window for Ada C C Changer Project 2 Ada C Changer Wizard Basic Settings Basic properties of a project Application Name Sudoku Application Prefix Author Name Copyright notice Application Copyright Notice Greeting Message Application Welcome Message Cancel Select Ada C C Changer build configurations 6 On Select Configurations window select the platforms and configurations for deployment and click Next as shown in Figure 9 4 Figure 9 4 Select Ada C C Changer build configurations Dynan oars aod e e TET Y Select Configurations A Select platforms and configurations you wish to deploy on Project type Executable Toolchains MinGW GCC Configurations iv Debug Select all v amp Release Deselect all Advanced settings Use Advanced settings button to edit project s properties Additional configurations can be added after project creation Use Manage configurations buttons either on toolbar or on property pages i in
99. RODUCT ARE OFFERED ONLY ON THE CONDITION accept the terms of the license agreement O1 do not accept the terms of the license agreement Next Finish Cancel 7 During the Updating Software Window you can view the new plug ins being downloaded as shown in Figure 2 19 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 2_19 Remote Updates Download Z Projects Application Common Operating Environment AppCOE ES Projects 2 Profiler Sm Updating Software i Updating Software COCCI Downloading mapusoft appcoe target always run in background Run in Background Cancel Details gt gt Problems EI console 33 E Properties No consoles to display at this time Updating Software 23 Com 8 Security Warning in between the Installation as shown in Figure 2_20 Figure 2 20 Security Warning Security Warning authenticity or validity of this software cannot be established Do you want to AN Warning You are installing software that contains unsigned content The continue with the installation 9 Once all the features and plug ins have been downloaded successfully and their files installed into the product on the local computer a new configuration that incorporates these features and plug ins will be formulated Click Yes when asked to exit and restart the Workbench for the changes to take effect as shown in Figure 2 2T 10 You have now successfully in
100. Report Generating Timing Comparison Report Chapter 8 Introduction to Ada C C Changer Ada C C Changer in AppCOE Creating Ada C C Changer Projects Creating Ada C Changer project Creating Ada C Changer project Creating New Ada C Template project cee eecsecesseeeseeeneecneecaeceaeceaeceaeesseeeaeesseeeseeeseeeees 194 Creating Ada C Template project 0 0 cee eeeescssceeeseeeseeeeeeseecsaecaecsaecsaeesseesseesseeeseesseeees 195 Ada Source Directory Configuration with Linked Libraries Specifying the Configuration ADA LIB and UNIT MAP Program Library Options Tool adaopts Source Registration Tool adareg Adacgen Compiler Output Files Adabgen Program Builder Processing Adabgen Inputs Ada C C Changer Outputs Chapter 9 Working with Ada Changer Ada C Changer Projects with Ada C C Scheduling Working with Ada C C Changer Projects Ada C Changer Projects with Ada C C Scheduling Ada C Changer Projects with Real time OS Abstractor Scheduling Select Ada C C Changer build configurations Import Ada Source files to project ADA C C Changer Configuration Options Target Code Generation for Ada C C Changer Projects Ada C C Changer Property Page ADA C C Changer Additional Information s Additional Ada C C Changer tools aeterni vacedantevedepusacuaasecveleuntasneesanemudadeleds 234 Revision History MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL List Of Figures Figure 1_1 Create a Support T
101. SIZE Host Library Configuration F OS Abstractor Process Mode Enabled Einish Enter the project name for which you want to import the legacy code in the Project Name text box Enter the root task as a tx kernel enter prototype next to Root Task Prototype text box Enter the root task stack size next to the Root Task Stack Size text box The value should be in bytes Enter the root task name next to Root Task Name text box MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 9 Click Finish to complete the importing of legacy code into AppCOE You can see the output as shown in Figure 5_21 Figure 5 21 Importing Threadx Code Output 10 You have successfully imported ThreadX legacy C code and a project with your given project name is created in the current workspace MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting pSOS Legacy C Code This section describes the sample porting of pSOS Legacy Applications using AppCOE Porting Plug in A description for porting pSOS Legacy applications using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Select Tools gt Porting gt pSOS gt Import Legacy C Code as shown in Figure 5_22 you can also click on the Porting icon from the task bar Figure 5 22 Importing pSOS Legacy C Cod
102. Settings 2 Turn off User Access Control e On Windows 7 8 1 Go to Start gt Control Panel User Accounts and Family Safety User Accounts 2 Set the notification to Never Notify Refer to the sample demo applications provided with OS Abstractor as a reference point to start your application Please review the target processor and appropriate development tools documentation for additional information including specific details on how to use the compiler assembler and linker MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Full Library Package Generator MapuSoft enables you to generate a full library code package to create libraries and develop applications using your own IDE You can manually scale and configure the product by modifying the user configuration file Note Before you begin refer to MapuSoft System Configuration Guide This section contains the following topics Generating Full Library Packages Generating Binary Packages Generating Full Library Packages NOTE This feature requires a Library Package generation license Click http mapusoft com contact to send a request to receive licenses and documentation AppCOE can also create full library packages to complete the porting and development outside of AppCOE with your own tools and environment NOTE To generate full library package on Windows Interface ensure that the flag INCLUDE_OS_PROCESS is set to OS_TRUE in the cross_os_usr h configuratio
103. You can do any one of the following required mode for reporting the compiler actions e To select the verbose mode select the radio button To select the normal mode select the radio button Note By default this is enabled To select the quiet mode select the radio button MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 11 On Additional Options tab set your miscellaneous options You can also select the multiple Ada source directories and click Next as shown in Figure 9_10 Figure 9_10 Additional Options Tab 2 Ada C Changer Wizard Configuration options Set your configurations for Ada C C Changer tool C C output Ada listings Ada messages Ada drivers Additional Additional options Add GNAT Compatibility Add POSIX Compatibility Cancel The field descriptions for additional options tab are as follows Table 9 6 Field Descriptions for Additional Options tab Field Description Your Action Additional Specifies if you To specify additional options select the Options want to include any check box and enter a value in the text other additional box options such as custom or optional Add GNAT Specifies if you To add GNAT compatibility select the Compatibility want to add GNAT check box Compatibility POR INDE nee a ou This feature is disabled on Windows want toa pn On Linux to add POSIX LINUX Pompanbiity PONIA E i compatibility s
104. You can get latest AppCOE updates from http www mapusoft com using the following two options e Remote Update By using Remote Update Site the system will automatically contact http www mapusoft com website and search for the latest updates You need internet connectivity for this to work Local Update By using Local Update Site you can do AppCOE updates without connecting to the Internet For this to work you need to get the updated files from http www mapusoft com by e mail or CD MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Updating Software Using Remote Update Site To update software using Remote update site 1 From AppCOE main menu select Help gt Check for Updates as shown in Figure 2 3 Figure 2 3 Software Updates Using Remote Site MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 2 Check the Available Updates that you wish to install as shown in Figure 2_4 Figure 2_4 Check the Available Updates Available Updates Available Updates Check the updates that you wish to install Name Version Lo Application Common Operating E 1 3 9 201311081714 mapusoft appcoe Select All Deselect All Details 3 Contacting Software Sites for Updates as shown in Figure 2_5 MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 2_5 Contacting Software Sites for Updates i wr Wer Por pfe orn on r natga pem LII No oct ho eagl
105. _start h main int LPSTR int nal handler 5 The debugging resumes as shown in Figure 4 30 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_30 Debug Demo Application Perspective T Debug demo xross os source os init windows host c Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Run Window Help v s x M PRR 0 QqQ 5 5 E3 9 Projects Profiler 35 Debug i Debug i 00 Variables o Breakpoints Ii Registers m Modules 4 O demo cross_os exe AppCOE Local C C Application 5 t z a GB AppCOE Supplied GDB 11 11 13 6 39 PM p Thread 1 Running b C MapuSoft AppCOE_x32 mingw bin gdb exe 11 11 13 6 39 PM Bj CAMapuScftAppCOE x32 Workspaceldemo cross osi Debugldemo cross os ex os init windows host c B Outline sif OS TARGET OS WINDOWS amp amp OS HOST OS TRUE a SARV MJ os application start h main int LPSTR J Console 53 Tasks i Problems Executables J Memory B Hemo_cross_os exe AppCOE Local C C Application C MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 6 39 PM New Thread 948 8xe2c New Thread 948 0xeb8 New Thread 948 0x988 New Thread 948 0x474 You can see the debugging on the console as shown in Figure 4 31 Figure 4 31 Debug Demo Application Output n 8 C AMapusoft AppCOE workspace demo_cross_os Debug demo_cross_os exe EXIIT System time is 1994 1 94 9944
106. abled Simple Name is Unique means it retains the original simple name Case Sensitivity Specifies if you want to select case sensitivity You can do any one of the following If As Is selected then it preserves the original upper lower case of the Ada identifier Identifier Capitalized option means the following depending on the Variable Naming selection If Full Unique Name option is selected then the first letter of the names of each identifier and also the package is capitalized with rest of the letters in lower case If Simple Name is Unique option is selected then the first letter of the name of each identifier is capitalized with rest of the letters in lower case Note By default this is enabled All Lower generates a C name that is all lower case Remove Name Tables Specifies if you want to select remove name tables Remove name tables means omit tables necessary for lt enum_type gt Image and enum type Value to work properly as well as full displayable names for exceptions and object tags Association Specifies the association constructs You can do any one of the following To place and on same line as associated construct select the radio button Note By default this is enabled To place f and on its own line select the radio button MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONME
107. ake Semaphore OS Send To Queve OS Send To Pipe INT OS Get Event Group X OS Receive From Queue INT OS Get Task Jd OS Create Timer OS Sleep Task OS Receive From Pipe OS Give Semaphore OS Suspend Task OS Delete Task OS Resume Task 5 Threads MAPUS fFT 2 m El q EA Load Profiler Data File zi Generate Report Generate Comparison Report epe oT 5000000000 4000000000 000000000 000000000 2 ra aes eos i L 1000000000 Time Nano Seconds N wo 0 4 1 OS_ROOT 2 7 Task_3 m E Properties 23 Property Average execution time Instance with the longest execution time Instance with the shortest execution time Total number of times function was called H 013 358 812 959 249 478 873 399 834 960 990 613 445 870 604 ti 3 B Task 4 4 8 Task 4 5 7 Task 3 8 B Task 4 7 B Task 4 Instances of OS Get Events Function X axis shows Api Iteration Thread Name Value 2 798 629 443 Nano Seconds 3 8 Task 4 9 8 Task 4 9 mE US 1 553 805 i2 eo e N 8 7 Task 3 1 5 e and 9 B Task 4 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 An Import PAL file window is displayed Select the PAL file by clicking on the Browse button or entering the second PAL file path in the text box A Profiler Categorization Dialog box is displayed NOTE If you comparing the two PAL files for the first
108. al Interface Provides detailed description of how to use OS Abstraction This guide e Explains how to develop code independent of the underlying OS e Explains how to make your software easily support multiple OS platforms VxWorks Interface Reference Manual Provides detailed description of how to get started with VxWorks interface support that MapuSoft provides This guide e Explains how to use VxWorks applications interface port POSIX Interface Reference manual Provides detailed description of how to get started with POSIX interface support that MapuSoft provides This guide e Explains how applications to use POSIX interface port pSosS Manual Interface Reference Provides detailed description of how to get started with pSOS interface support that MapuSoft provides This guide e Explains how to applications use pSOS interface port pSOS Classic Reference Manual Interface Provides detailed description of how to get started with pSOS Classic interface support that MapuSoft provides This guide e Explains how to use pSOS Classic interface port applications Nucleus Interface Reference Manual Provides detailed description of how to get started with Nucleus interface support that MapuSoft provides This guide e Explains how to use Nucleus applications interface port Micro ITRON Reference Manual Interface Provides detailed description of how to get
109. ard optimizes target specific source code Process Memory Other Resources Debug Output Devices ANSI Mapping Device VO Interface Enable OS Abstractor Interface Process Feature Maximum Process Control Blocks Process Memory Pool Minenum Size in Bytes Process Memory Pool Maximum Sae in Bytes Stack Size for the Main Process KiloBytes Heap Size for the Main Process in KiloBytes Task Prionty for the Main Process Task Preemption Mode for the Main Process MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Process tab are as follows Table 6_7 Field descriptions on Process tab Field Description Your Action Enable OS Abstractor Interface Process Feature Specifies ifthe OS Abstractor Interface process feature is enabled or disabled Select the check box to enable this feature Maximum Process Control Blocks Specifies the total number of processes required by the application Enter the maximum number of process control blocks for the application NOTE Default value is 100 Process Memory Pool Minimum Size in Bytes Specifies the minimum size of the process memory pool in Bytes Enter the minimum size of the process memory pool NOTE Default value is 1024 Bytes Process Memory Pool Maximum Size in Bytes Specifies the maximum size of the process memory pool in Bytes Enter the maximum size of the process memory pool NOT
110. ary Project Root Directory EX Examples LegacyDemos Legacy Posix App Project Name posix_legacy Root Task Prototype int px main int argc char argv Root Task Stack Size in bytes OS MIN STACK SIZE Host Library Configuration 7 OS Abstractor Process Mode Enabled ere Enter the project name for which you want to import the legacy code in the Project Name text box Enter the root task prototype as int px_main int argc char argv next to Root Task Prototype text box Enter the root task stack size next to the Root Task Stack Size text box The value should be in bytes MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Click Finish to complete the importing of legacy code into AppCOE You can see POSIX LINUX legacy code you have imported as shown in Figure 5_14 Figure 5 14 Importing POSIX LINUX Legacy Code Output P cation Cor nmon Opera ng Ervororement ad E gt Die Edt Source Refactor Nasgate Seach Bun Project Toot Window ely amp PO H 0O Qq fj 9 Debug 12 Projects 2 Profiler 1 oo demo_uitrom C deme _voworks demo windows 4 posu legecy p bhedes io mhe LC application c os apphcation sterte 1 Problems Console 7 Properties 9 Debug You have successfully imported the POSIX LINUX legacy C code and a project with your given project name is created in the current workspace MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT US
111. ask pooling feature is enabled for this application ANSI Memory Specifies if you want to map ANSI malloc and free to OS Abstractor Interface equivalent functions ANSI format IO Specifies if you want to map ANSI printf and sprintf to OS Abstractor Interface equivalent functions Debug Information level Specifies if you want to enable the debug output Error checking Specifies if you want to enable the error checking Fatal Error Specifies if you want to enable the feature to ignore fatal errors 3 Profiler Configuration When you perform profiling on AppCOE APIs the report displays the following profiling application values e File name Specifies the name of the pal file generated by OS Abstractor Interface Project name Specifies the name of your project Target name Specifies the target OS you have selected for profiling File size Specifies the size of the file to be profiled Profiler XML format Specifies the version of the XML used for profiling Process name and ID Specifies the process name and the ID User Data Specifies the information provided by the user Profiling start time Specifies the starting time of profiling Profiling stop time Specifies the end time of profiling Total time profiled Specifies the total time taken for profiling Number of profiling messages Specifies the number of profiler messages MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER M
112. aste Delete Move Rename Import Export Refresh Add Bookmark Run As Debug As Profile As Clean Selected File s Build Selected File s Team Compare With Replace With Properties When onpimizing you will need to write an e Eget operating system RRR RRR RRR RRR RRR RRR RRR gc LPSTR argv gc argc gv argv UCCESS m E Properties Debug 32 isl Lu S BY ple_abs_project exe AppCOE Local C C Application AppCOE Supplied GDB 5 31 12 5 57 PM Exited Exit code 0 I Bs DOCS MM 2012Nmii C 1 AppCOE Local C C Application emp 22N E 2Local C C Application gt Debug Configurations Alt Enter MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On Debug Configuration window you can set your options for debugging as shown in the Figure 4_35 NOTE You must use MapuSoft Supplied GDB to execute debugging NOTE AppCOE does not support Cygwin tools and its use is not recommended Figure 4_35 Debug Configuration Window Debug Configurations Create manage and run configurations 2 ES Name type filter text 4 iq AppCOE Local C C Application d demo cross os Debug E Main 69 Arguments I Environment 35 Debugger Ey Source Debugger AppCOE Supplied GDB X d demo cross os exe V ICDebuggerTab Stop at main on startup main ICDebuggerTab Advanced E C C
113. bed in the following generic form 1 Include os target h in all your application source files 2 Set the appropriate compiler switches within the project build files to indicate the target OS and other target configurations 3 Configure the pre processor defines found in the cross os usr h header file under each target OS folder to applications requirements Initialize the OS Abstractor library by calling OS Application Init function If you are also using POSIX LINUX Interface then also use OS Posix Init function call to initialize the POSIX LINUX component as well If you use OS Changer s you may need to call other appropriate initialization functions as well After initialization create your initial application resources and start the application s first task After this and within the main thread call OS Application Wait For End function to suspend the main thread and wait for application re start or termination requests Compile and link your application using appropriate development tools Download the complete application image to the target system and let it run NOTE Make sure to disable User Account Control UAC in order to have administration permission in Windows Vista and Windows Turning Off UAC In order to run our products successfully users need to turn off the User Access Control UAC To turn off UAC e On Windows Vista 1 Go to Start gt Control Panel gt Security Center gt Other Security
114. box is displayed on your screen to ask if you want to port the project If you want to port click OK You can see the porting processing results as shown in Figure 5 6 After the porting is successfully done the porting report page is displayed as shown in Figure 5 7 Click Done to complete the process Figure 5 7 Porting Reports Page o Porting Report 3 Displays the Information about different activities involved in Porting Inputs Provided Status SUCCESS Description Input Values Provided for Project simple vxworks app Project Porting Status SUCCESS Description simple vxworks app Project Ported Successfully Guidelines Status WARNING Description Status Require Application Code Modification Porting steps completed successfully In order to successfully compile your application the following manual code changes may be recutiredt MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 10 In order to successfully compile your application follow the guidelines highlighted as shown in Figure 5 8 Figure 5 8 Porting Reports Page Guidelines Porting Report Displays the Information about different activities involved in Porting Guidelines Status WARNING Description Status Require Application Code Modification Porting steps completed successfully In order to successfully compile your application the following manual code changes may be required 1
115. bug Ex bol G8 CE f Pt BH r 8 demo cross os exe AppCOE Local C C Application C MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 8 10 PM New Thread 3588 0xf44 New Thread 3588 0x788 New Thread 3588 0xd88 New Thread 3588 0x1008 New Thread 3588 xc14 New Thread 3588 xcb4 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Debugging Using External Console Terminal Debugging can be done using an external console or terminal in the following way From AppCOE main window select the demo_cross_os project Right click on the project and select Debug as gt Debug Configuration as shown in Figure 4 34 Figure 4 34 Open Debug Dialog Projects DXOSPAL V n File Edit Source Refactor Navigate Search Run Project Tools Window Help wm O OXR BPO M O Q Debug e Profiler jv gr D 4 gt include Ada_Sudoku demo_cross_os demo_nucleus demo_posix demo_psos demo_uitron demo_vxworks demo_windows EFI os init windows host c 22 Le OS Application Start DESCRIPTION These are the various entry functions for th systems This is where you should put any o specific code For instance if you wanted on Linux you could do it here before callin sample abs project P Binaries 5 sample abs ip Includes GS source Debug sample abs p New Open Open With Tools Make Targets Copy P
116. builder options This contains the list of options with which Ada Changer Project or executable is created This is a hidden file You can view this in Navigator view To view select Window gt Show View gt Other gt General gt Navigator NOTE Host Libraries and include paths are automatically added during project creation For viewing this information select Ada Changer Project gt Properties gt C C Build gt Settings MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Building Ada C C Changer Projects Ada C C Changer enables you to build an existing project This feature enables you to either do an incremental full build or just a C C Changer Build on your Ada 95 sources e The Build process will incrementally compile the Ada files that have been modified or added since the last build NOTE To do an incremental build you should not do Clean If any new Ada source files are added removed or modified in the project and want to generate the c sources again you can do a full build by first calling Clean and then Build Clean will delete all your info files which will result in a full build You cannot re build if new directories are created or new files are added with differing extension than what was provided during the project creation If you have new directories and new extensions then you must recreate the Ada C C Changer project You will get a build error when you create an Ada
117. considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5_17 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5_17 Import Nucleus Legacy Code Window amp Import Import Nucleus Legacy Code Select a Directory to Import Nucleus Legacy Code into AppCOE Import Application Project Import Library Project Root Directory E Examples LegacyDemos Legacy_Nucleus_App Browse Project Name nucleus_legacy Root Task Prototype VOID NucleusRoot UNSIGNED argv VOID argc Root Task Stack Size in bytes OS MIN STACK SIZE Root Task Name NU_ROOT Host Library Configuration 7 OS Abstractor Process Mode Enabled ma Enter the project name for which you want to import the legacy code in the Project Name text box Enter the root task prototype as VOID NucleusRoot UNSIGNED argv VOID argc next to Root Task Prototype text box Enter the root task stack size next to the Root Task Stack Size text box The value should be in bytes Enter the root task name next to Root Task Name text box MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 9 Click Finish to complete the importing of legacy code into AppCOE You can see the output as shown in Figure 5_18 Fi
118. de in AppCOE Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help RRO 07r riveree E LO Projects Profiler f B r D r i ThreadX gt E Import Legacy C Code r D VxWorks m PES SOS c C Projects 2 P Nucleus y t demo cross os POSIX C demo_nucleus micro ITRON L demo posix Windows C demo_psos n demo threadx C demo_uitron C demo_windows 11 Problems EJ Console 23 E Properties MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5_20 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5_20 Import Threadx Legacy Code Window Import Import ThreadX Legacy Code Select a Directory to Import Posix Legacy Code into AppCOE Import Application Project Import Library Project Root Directory E Examples LegacyDemos Legacy_ThreadX_App Project Name threadx_legacy Root Task Prototype tx kernel enter Root Task Stack Size in bytes OS MIN STACK
119. e files e OS Abstractor Interfaces the ones that are included in the project e Library sources without project files MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 5 On Profiler Configuration tab define your profiler data specifications as shown in Figure 6_12 Figure 6_12 Profiler Configuration Optimized Target Code Generator This wizard optimizes target specific source code Profiler Configuration Platform API Profiling Application Functions Profiling Description Cross OS VxWorks project Profiler Task Priority 200 File Path To Store Profiled Data e g c profiledData OR home userl Number of Data in Memory Before Each Write 3000 Maximum Profiler Data to Collect 30000 Finish MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Profiler Configuration tab are as follows Table 6_2 Field descriptions on Profiler Configuration tab Field Description Your Action Description Specifies the description for Type description the OS Abstractor for the OS Interface project Abstractor Interface project Profiler Task Priority Specifies the priority level Enter a priority of the profiler thread level for the profiler thread The value can be between 0 through 225 The default value is set to 200 File Path to Store Specifies the directory Enter a data file Profiled Data location where the profiler path fil
120. e in AppCOE Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help XY or RY RP O HBr Or Qr wr VxWorks ES 3 Projects Profiler a S 51 tL y C C c or C C Projects 34 E psos Import Legacy Code n Nucleus ThreadX POSIX s micro ITRON C demo_posix Windows C demo_psos rn demo threadx C demo uitron oO demo vxworks C demo windows Problems El Console 23 E Properties MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown Figure 5_23 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5_23 Import pSOS Legacy Code Window amp Import Import pSOS Legacy Code Select a Directory to Import pSOS Legacy Code into AppCOE Import Application Project Import Library Project Root Directory E Examples LegacyDemos Legacy_Psos_App Browse Project Name psos legacy Root Task Prototype VOID Function Rect ULONG argument Root Task Stack Size in bytes OS MIN STACK SIZE Host L
121. e is valid file o or file obj Relocatable object module files one for each source file in the compilation These output files are placed according to the program library parameters Also produced are various intermediate files these are usually deleted as a matter of course unless the ke option is specified Additional files that may be produced by a compilation are Table 8 5 Additional Compiler Output Files Output Files Description file lst Source listing if any of the lp lc or lr options are specified file xlst Cross reference listing if the lx option is specified file xref Cross reference information in a binary format This is for use by a browser and the cross reference lister Compile Time Messages All compiler messages are written to AppCOE Console View When error messages are printed processing does not proceed beyond the front end No intermediate files or object code files are produced Warning and other informational messages do not prevent further processing The back end i e C compiler may print error messages as well however these will be error messages related to problems internal to the compiler itself The option m a can be used to suppress all warning and informational messages generated by the compiler If there is an internal error in the compiler the options v and or t and or mr a can be used to help determine what part of the compiler contains the
122. e occurrence MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting VxWorks Applications Porting applications into the AppCOE host environment can be done in three different ways 1 Porting a WindRiver Workbench project 2 Porting a Legacy application 3 Manual porting using AppCOE Method 1 Porting a WindRiver Workbench C Project NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 From AppCOE main window select any project under C C Projects tab on the left pane 2 Select Tools gt Porting gt VxWorks gt Import Workbench C Project as shown in Figure 5_3 You can also click on the Porting icon from the task bar Figure 5_3 Importing a VxWorks Workbench C Project in AppCOE Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help ri lm R MO wr OvGar vr X Vx Works E Import Workbench C Project E Projects 2 Profiler Fig C C Projects 23 B p505 Import Legacy C Code f Sas Nucleus L ThreadX e demo c x POSIX C demo nu S micro ITRON C demo_posix C demo_psos nr demo threadx B demo uitron C demo vxworks C demo_windows S Problems Ed Console 23 E Properties MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import window select a workspace direct
123. e operating system platforms with a standard OS interface thereby reducing cost associated with code maintenance and learning multiple operating systems OS Abstractor is designed for use as a fully scalable C library Services used inside your application software are extracted from the OS Abstractor libraries and are combined with the other application objects to produce the complete image This image may be downloaded to the target platform or placed in ROM on the target platform Application developers need to specify the OS for the application and also include the required OS Abstractor libraries while building the application Application developers can also select the individual OS Abstractor components that are needed and exclude the ones that are not required OS Abstractor is graphically represented in the follow as shown in Figure 3_4 Figure 3 4 Cross OS development Platform Cross OS Development Platform ET Modula P Linux POSIX Your Applications OS Abstractor In house abstraction For more information on the host development refer to Cross OS development Platform MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Full Library Package Generator With Application Common Operating Environment AppCOE you can easily generate a source code package to create libraries and develop application using your own IDE You can manually scale and configure the product by modifying the user configuration file
124. e will be created The default location set is root on Unix based machines and c on MS Windows machine Number of Data in Specifies the depth of the Enter the number Memory Before Each profiler queue of data in memory Write before each write The default value is set to 3000 Maximum Profiler Specifies the maximum Enter the number Data to Collect records collected in the of profiler XML file messages The default value is set to 30000 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 6 On Platform API Profiling tab select the check box to enable your appropriate Interface API Profiling as shown in Figure 6_13 Figure 6_13 Platform API Profiling Optimized Target Code Generator This wizard optimizes target specific source code Profiler Configuration Platform API Profiling Application Functions Profiling Enable POSIX Interface API Profiling Enable micro ITRON Interface API Profiling Enable Windows Interface API Profiling Enable VxWorks Interface API Profiling Enable pSOS Interface API Profiling E Enable Nucleus Interface API Profiling MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Platform API Profiling tab are as follows Table 6_3 Field descriptions on Platform API Profiling tab Field Description Your Action Enable OS Abstractor Interface API Pr
125. e y the tine wA wv Are Kes Ht 4 On Available Updates Search Results window select the features under the AppCOE Update Site tree parent and click Next as shown in Figure 2 6 Figure 2 6 Review and Confirm the Updates Available Updates Update Details Review and confirm the updates Name Version Id a Application Common Operating Environment AppCOE 1 3 9 201311081714 mapusoft appcoe ft AppCOE Host Target Feature 1 3 9 1 mapusoft appcoe host target feature feature group Size Unknown Details ema Ces MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 5 On Review License window select the radio button next to I accept the terms in the license agreements and click Finish as shown in Figure 2_7 Figure 2_7 Remote Update Host Target Feature License Available Updates Review Licenses Licenses must be reviewed and accepted before the software can be installed License text For AppCOE Host Target Feature 1 3 9 1 PLEASE READ CAREFULLY THE USE OF SOFTWARE IS SUBJECT TO THE TERMS AND CONDITIONS THAT FOLLOW IF YOLI AGREE TO THESE TERMS PLEASE CONTINUE BY PRESSING I AGREE End User License Agreement PLEASE READ CAREFULLY BEFORE INSTALLING AND USING THE SOFTWARE This End User license Agreement EULA is a legal agreement between you the end user as an authorized representative of the company acquiring the license Licensee and Mapusoft Technologies Inc MTI that govern
126. ebug As Protte As Convert To Team Compare Wah Restore trom Local Mistery MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 Select your import source and click Next as shown in Figure 4_17 Figure 4_17 Importing Files from Local File System s Import Select Import resources from the local file system into an existing project Select an import source type filter text 4 amp General 5 Archive File C Existing Projects into Workspace L File System ES Preferences E C C amp Run Debug Team MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 4 Select the directory on your local file system which contains the source code files and click OK as shown in Figure 4_18 Figure 4_18 Importing Source Code Files from Directory Import from directory Select a directory to import from 4 software 4 tech r demo_cross_os J demo threadx demo uitron Js demo vxworks d Vxworks demo port Folder Vxworks demo port Make New Folder 5 Select the check boxes corresponding to the source code files you want to import and click Finish as shown in Figure 4_19 Figure 4_19 Selecting Source Code Files for Importing Import v cH 53i File system Import resources from the local file system a From directory I tech Vxworks_demo_port V demo h V 8 init c v d os application s
127. econds 600000 1 Task 1 4 m MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Application Functions These are all the user specific functions called in the application On the x axis all the user specific functions are displayed On the y axis all functions iterations are displayed On the bottom of the window the function properties are displayed as shown in Figure 7_8 such as e Average Function execution time e Function with the longest execution time e Function with the shortest execution time e Number of times Application Functions are called in application Figure 7 8 Application Functions File Edit Source Refactor Navigate Search Project Run Tools Window Help re n M joj a ieg X X r X Ej Debug 2 Projects Profiler Data Explorer 23 EMI 2 Profiler View 55 a profiler_data_1210343810 System a Functions Platform APIs 4 Q Application Functions e OSA TEST OS Create Partitic e OSA TEST OS Allocate Parti 2800000 e OSA TEST OS Deallocate Pc e OSA TEST OS Delete Partitic 5 Threads 3200000 4 N R S S S S 2000000 1600000 1200000 Time Nano Seconds 800000 400000 0 Instances of OSA TEST OS Create Partition Pool Function X axis shows Api Iteration Thread Name 4 n E Properties 25 amp gt Property Value Average execution time 0 003 008 762 Nano Seconds Ins
128. ediately You need to select the project and refresh 1 2 times and clean the project and then do the build Note On Linux HOST Environment you may need to set View Modify permissions to the Tools folder while creating a project If the AppCOE installer did not set View Modify permissions please follow the below steps to do this To set View Modify permissions e Goto the Tools folder e Right click on the Tools folder and select Properties gt Permissions e Change the required permissions Then provide executable permissions to files under tools Ada linux bin folder before creating any Ada project Otherwise it will give an AppCOE exception while trying to convert Ada to C using Ada C C Changer Options To change executable permissions e Go to Terminal Command window e Go to the respective folder location by cd AppCOE Source directory Tools Ada linux bin Once you are in bin folder run the command like chmod 777 gt Now observe files changes color from black to green MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Revision History Document Title Application Common Operating Environment User Manual Release Number 1 3 9 1 Release Revision i Description of Change 1 3 6 0 1 New Manual 1 3 6 1 0 1 Ada sections 1 3 7 0 1 Changes to Ada C C Changer and Target Code Optimization sections 1 3 8 0 1 Changes to Target Code Optimization sections 1 3 9 0 1 Changes
129. efile for this project type is automatically created by the CDT NOTE Select the check box next to your required library or application project to be imported If you select Application project and click Finish you get Application Start up Files window as shown in Figure 5_5 Figure 5_5 Application Startup Files Window 2 Import Select a Workspace to Search for existing Workbench Projects Import Wind River Workbench Projects Projects In Workspace 4 7 Application Projects 7 simple vxworks app Library Projects If you are importing a kernel application click Yes to automatically create start up files to connect the imported application to the OS platform NOTE If you are porting a library project click No to continue with the porting If you select any application type project provide the inputs for the project and click OK as shown in Figure 5 6 If you do not want to provide the inputs you can just click Cancel MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 5_6 Provide Inputs for Projects Window Q Inputs For simple_vxworks_ app Root Task Prototype Enter prototype function definition of application s root task e g int UsrRoot int argc Root Task Stack Size in bytes OS MIN STACK SIZE Cancel NOTE If you select an application project and if it contains any referenced projects not selected by you then a Confirmation dialogue
130. elect the check box Compatibility Note This feature is not supported on Windows It is supported on Linux only MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 12 On Select APIs Page select the check box to enable the generated C Source Code use Real time OS Abstractor Scheduling along with the corresponding interface support from the available list and click Finish as shown in Figure 9_11 NOTE 1 If Real time OS Abstractor Scheduling is not chosen in the Ada C C Changer Wizard below page will be not be displayed NOTE 2 Real time OS Abstractor Scheduling allows you to migrate to multiple Operating Systems and enable OS Abstractor Integration for this project after importing to AppCOE NOTE 3 If you have enabled the OS Abstractor APIs you can any time enable the additional development APIs after importing to AppCOE Figure 9 11 OS Abstractor Integration Page 2 Ada C Changer Wizard Select APIs List of API sets available Interfaces Host Library Configuration OS Abstractor Interface APIs will automatically be included for AppCOE C C Projects Select additional development API s used by your application Include OS Abstractor Interface API s Include POSIX Interface API s _ Include VxWorks Interface API s E Include pSOS Interface API s Include Nucleus Interface API s Include ThreadX Interface API s Include micro ITRON Interface API s Incl
131. ent sue 4 Task 6 Nucleus Intetace Dust ed D Tesk 7 OS Abstractor letedace Enabled Vee intetace Disabled Windows hetece 4 Profiler Configursbon profiler data 2210343310 pal 138229 Bytes ber ot peohing messages 142 name and ID NA 65535 Ll 13 5610 Drotuing stop time 13 5 amp 3 Proyect rare ga test Target name Windows F Total time profiled 2208 513 534 Nano Seconds Jser Dats osabstractor Windows XP project MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Functions This displays all the functions called in the application and the time taken to execute these functions as shown in Figure 7_5 Figure 7_5 App Platform Profiler System Profiter dena cross on Ele Edm Source Refactor Navigate Sech Project Bum Tools Window Help me BME qQ 5 ZI TY Debug 2 Projects LT Profiles D Prof er Data Explorer 5o Poles Vw o profier data 1210343810 System Functions 4 Threads Task 1 p Task 2 Platform APIs D Task 3 Task 4 O Task 5 CD Task 6 D Task 7 22 6b come 22 561 257 e abe 2 532 900 BH 742 968 502 22 FES 22 681 22 50 L1 E 77 5 122 870 066 13 145 944 n a 1 270 250 ei Ta hase 7 pom 5 626 150 3 996 3 M Time Nano Seconds D 145 55 2 Fosi ip 501 ipt 5 1 Deubocute Partite 5 Dele Parton Fr uv Tm e Queue N De To 5 Recwen Pron Quen 6 Deto S App amp cation Free Functions In Application
132. error this might help you work around the problem The compiler may implicitly perform semantic analysis of other source files in the program library or in a linked library during an invocation in order to handle semantic dependencies on other compilation units Compile time messages generated during implicit processing are displayed only if the mr option is used Otherwise compile time messages are written only for processing of the source file s specified in the adacgen command Adabgen The Ada program builder provides the facilities for creating a load module for an Ada program It finds the object modules needed to build the executable determines the elaboration order and invokes the target linker to generate the load module In addition the program builder implicitly invokes the compiler as needed so that all object modules are up to date with respect to any source files on which they depend In fact it is not necessary for the user to invoke the compiler directly at all the entire program building process including compilation can be handled by the program builder if desired The load module generated by the program builder is in the format created by specified linker MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Program Builder Processing Program builder processing is divided into two phases prelinking and linking The prelinking phase handles those Ada 95 requirements that are processed at b
133. erties Alt Enter Ada Sudoku MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The Ada C C Changer project starts to build and generates the exe file as shown in Figure 9_15 ris Relan Maven e Search Promet fun Te nd ele OO0X 96O HM O Q F CY Debug 17 Projects Profiler z HO C C Proects IN do Sedo D Build Project o Building proyect egay eu wn Legacy Abweys run beckground Cancel Problems E Console T Properties 15 Debug C Build Ada Sudoku Build Project 16 NOTE While running any Ada project after build the project sometimes will again build the project before running the application To avoid this do the following configuration e Select Window gt Preferences gt Run Debug gt Launching e Under General Options deselect the check box for Build if required before launching flag MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 2 You can view the generated exe file under the project in the Debug Folder as shown in the Figure 9_16 Figure 9 16 Generated exe File um os m am PI E Bie fort Source Refactor Newgate Search Project Bun Took Window Help ek OX PO H 0O qQ f j 9 Debug 12 Projects Profiler a M Ade Sudobks e Bears B nchudes E dace im ada amp oct 4 Debug E ada2zCC 19 Ade Sudoku es 55 u m ADA LIB UNIT Map A demo_sda_to_c C demo cross os ed demo nuaceus D de
134. es the Ada C C Changer for one or more files If the specified source files have semantic dependencies on other units the source files for those units must be located either in the program library or in one of the linked libraries If a source file depends on a library unit not yet processed by the current invocation of the compiler the compiler will find and process that library unit through the front end only provided that the source file containing the required library unit has been registered in the program library or is in a linked library This proceeds recursively if necessary until the closure of all depended upon library units have been processed Listing Options For the listing options the compiler generates the requested listing for each file specified on the command line Table 8 1 Compiler Generates the Requested listing Options for Each File Listing Options Description c The lc option causes the compiler to generate a continuous source listing without pagination or headers Any errors or other compiler generated messages are interspersed in the listing The listing is written to file lst The le option causes the compiler to generate a source listing only if there are errors If neither lc lp or lr are specified the listing is generated without pagination or headers with interspersed error messages as if lc had been specified The listing is written to file lst lf filename When used in conjunction wi
135. ese defines will no longer be necessary You can add some application code or debug statements like printf assert which is mostly used in host environment only This line of code will be ignored by the compiler in target environment OS HOST Selection The flag has to be false for Full Source Library Package generation Table 4_1 OS HOST Selection Flag and Purpose Available Options OS_HOST This flag is set as OS_TRUE by default in To select the host operating APPCOE environment system Target 64 bit CPU Selection Based on the OS you want the application to be built set the following pre processor definition in your project setting or make files Table 4_2 Target 64 bit CPU Selection Flag and Purpose Available Options OS_CPU_64BIT The value of OS_CPU_64BIT can be any ONE of To select the target CPU the following type e OS_TRUE Target CPU is 64 bit type CPU e OS FALSE Target CPU is 32 bit type CPU NOTE In New C projects creation the flag OS CPU 64BIT will be set to OS FALSE by default and user needs to make this true if they run on a 64 bit OS MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Updating Project Settings AppCOE provides exclusive way to update the Projects Settings by just a click of a button This is very useful in any one of the following cases 1 If the user has moved his workspace to a different location 2 Ifthe project requires new
136. est of the fields on this window are disabled Generate Optimized API Interface Files Specifies if you want to generate optimized API interface files Note If the application includes AppCOE based application libraries generating optimized API interface option is disabled Select the radio button to generate optimized API interface files Note By default this option is enabled Standard Function Specifies if the APIs used in your application are standard functions Select the functions used in this application as standard functions for the target OS project You can select multiple function names at once to place them in the other list You can select all function names in a list using the select All Ctrl A action also Macro Function Specifies that a compiler inserts the complete body of the function in every place in the code where that function is used It is used to eliminate the time overhead when a function is called and execute it frequently To select a standard function into a macro function select the API and click the right arrow To select a macro function into a standard function select the API under macro function and click the left arrow Note You can use optimization for this If a function is being called repeatedly they can improve the performance by making this a macro function MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT
137. et Code e Generating Project Files for your Target e Running AppCOE Generated Code on your Target For more information on optimized target source code generator refer to Optimized Target Code Generator MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada C C Changer MapuSoft Technologies now offers the Ada C C Changer tools that converts Ada to C amp give developers the ability to automatically convert legacy software written in Ada to the C programming language This automatic code conversion process eliminates the need for a costly and tedious code re write to provide developers extensive cost and time savings Ada tool gives users peace of mind by providing an error free tool that prevents mistakes made in the error prone task of a manual rewrite Ada tool supports converting Ada 83 and Ada 95 source code and generates ANSI C output as well as certain C features while preserving the Ada code s comments files structures and variable names to ease ongoing code maintenance For more information on using Ada C C Changer App Platform Profiler AppCOE enables you to view API performance data e The App Platform Profiler feature enables API data collection e Collected data provides feedback concerning the utilization of MapuSoft s APIs in the project Reports allow for performance impact analysis by detailing API execution time Offers area bar line pie and scatter charts for data analysis Generate
138. f your application appropriately For example Application Initialize Compile and link your application using appropriate development tools Resolve all compiler and linker errors Port the underlying low level drivers to Target OS Load the complete application image to the target system and run the application Review the processor and development system documentation for additional information including specific details on how to use the compiler assembler and linker Error Handling Applications receive a run time error via the OS Fatal Error function on some occasions This happens due to e Unsupported API function call or e Unsupported parameter value or flag option in a API call or e Error occurred on the target OS for which there are no matching error codes in OS Abstractor Interface OS Changer calls OS_Fatal_Error and passes along an error code and error string The OS_Fatal_Error handling function is fully customizable to the application needs At the moment it prints the error message if the OS_DEBUG_INFO conditional compile option is set then OS_Fatal_Error does not return For more details on error handling and definition of this function refer to the OS Abstractor Interface Reference Guide The non zero value in the error code corresponds to the underlying RTOS API error Refer to the target OS documentation for a better description of the errors Error Handling section lists the errors and the reasons for th
139. ferent timing reports and compares the performance report for an API at different time and different values NOTE 1 In the current release Profiler feature is not supported in ThreadX and Nucleus targets NOTE 2 The profiler feature does not generate profiler file XXX PAL on Solaris target if you do code optimization for demo_cross_os with profiler ON As a workaround enter the following command at the prompt prior to running the demo prctl n process max msg qbytes r v 512KB i process The 512KB is the desired size of the queue and should be sufficient to run this example If the number of messages is increased in cross_os_usr h then obviously this value will need to be adjusted MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 7_1 App Platform Profiler Fie Ede huge Search Project Run Took Window Help oe BRE a a TY Debug Projects Profiler 49 Profiter Data Explorer 1 ELI di inline ii 4 profiler data 1210343810 system Functions 4 Threads Task 1 4 Task 2 5 Plattorm APIs OS e Task Priority 260000 gt oa coate mut 240000 OS Get Cumt tose 1 os frotec Line Chart OS_unprot dj Bar Chart otc lad Ares Chet OS Sieep e on o ER Scatter Chart O8_Get_E BF Load Profiler Data File canal WM Generate Report 6 Task 3 E Generate Comperson Report Task 4 80000 21 60000 Task 7 40000 20000 LI n e e o
140. following GNU tools e Eclipse IDE e MinGW e GNU Compiler e PAL Debugger Eclipse An IDE is a powerful set of tools in the Application Common Operating Environment AppCOE development suite The IDE is based on the Eclipse Platform developed by Eclipse org an open consortium of tools vendors The IDE incorporates into the Eclipse framework several AppCOE specific plugins designed for building projects for target systems running on HOST The tools suite provides a single consistent integrated environment regardless of the host platform you are using Windows or Linux Plugins from most vendors should work within the Eclipse framework in the same way NOTE For more information on Eclipse and working on Eclipse framework refer to http www eclipse org documentation MinGW MinGW a contraction of Minimalist GNU for Windows is a port of the GNU Compiler Collection GCC and GNU Binutils for use in the development of native Microsoft Windows applications Offered in easily installed binary package format for native deployment on MS Windows or user built from source for cross hosted use on UNIX or GNU Linux the suite exploits Microsoft s standard system DLLs to provide the C Runtime and Windows API It is augmented by additional function libraries for improved ISO C 99 compatibility and further by community supported add on tools and libraries many pre built many more in the form of mingw PORTS to be built by the e
141. ft s OS Abstractor is an effective and economical software abstraction alternative for your embedded programming By using OS Abstractor your embedded application can run on many real time RTOS and non real time operating systems to negate any porting issues in the future when your platform changes MAPUS ZIFI 2S ABSTRACTOR Flow Diagram STEP ONE Choose an option STEP TWO Option One Option Two Optimized Code Generation Full Source Package Generation Generated Profiler data optional View data using OS PAL Profiler Continue to STEP TWO www mapusoft com Continue to STEP TWO 1 877 MAPUSOFT Figure 6 2 OS Abstractor Flow Diagram Interfaces Available for OS Abstractor The following are the OS Abstractor products e POSIX LINUX e micro ITRON e VxWorks psOs Nucleus Windows ThreadX MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Application developers need to specify the target operating system that the application and the libraries are to be built for inside the project build scripts Application developers can also customize OS Abstractor to include only the components that are needed and exclude the ones that are not required for their application If the Application also uses Interface products additional configuration may be necessary Please refer to the individual Interface documents Developing OS Abstractor or Cross OS Application The steps for using OS Abstractor are descri
142. fully imported pSOS legacy C code and a project with your given project name is created in the current workspace MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting micro ITRON Legacy C Code This section explains porting of micro ITRON Legacy Applications using AppCOE Porting Plugin A sample porting of micro ITRON Legacy applications using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Select Tools gt Porting gt micro ITRON gt Import Legacy C Code as shown in Figure 5_25 You can also click on the Porting icon from the task bar Figure 5_25 Importing micro ITRON Legacy C Code in AppCOE I gt Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help ra Er RRP Or 0 qm 9 VxWorks E Projects 2 Profiler psOs Ss E Nucleus ThreadX 2 POSIX ed demo nucleus micro ITRON 5 Import Legacy C Code C demo_posix Windows C demo_psos m demo_threadx ed demo uitron C demo vxworks C demo_windows iy C C Projects 2 Mi Problems EJ Console 23 E Properties MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with
143. g Application Code to Run only on Host Environment Updating Project Settings Chapter 5 Using OS Changer Porting Kit About OS Changer Interfaces Available for OS Changer Using OS Changer MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Error Handling Porting VxWorks Applications Method 1 Porting a WindRiver Workbench C Project Method 2 Porting VxWorks Legacy C Code Method 3 Manually Porting Legacy Applications using Import Feature Porting POSIX LINUX Legacy C Code Porting Applications from Nucleus PLUS Legacy Code to Target OS Porting Nucleus Legacy C Code Porting micro ITRON Legacy C Code Porting Windows Legacy C Code Building OS Abstractor Interface Library Building OS Abstractor Interface Demo Application OS Changer VxWorks Interface Building OS Changer VxWorks Interface Building OS Changer VxWorks Interface Library Building OS Changer VxWorks Interface Demo Application OS Changer POSIX LINUX Interface Building OS Changer POSIX LINUX Interface Building OS Changer POSIX LINUX Interface Library Building OS Changer POSIX LINUX Interface Demo Application OS Changer Nucleus Interface Building OS Changer Nucleus Interface Building OS Changer Nucleus Interface Library Building OS Changer Nucleus Interface Demo Application OS Changer ThreadX Interface Building OS Changer ThreadX Interface Building OS Changer ThreadX Interface Library Building OS Changer ThreadX Interface Demo App
144. generated as an rtf file extension The Timing Report displays the following information 1 Timing Information The timing information gives a detailed description of the following Best Time Value Specifies the minimum time taken to perform the action on each platform API Worst Time Value Specifies the maximum time taken to perform the action on each platform API Average Time Value Specifies the average time taken to perform the action on each platform API 2 Application Information When you perform the application profiling on AppCOE the report displays the following application property values e Total system memory limit Specifies the total system memory pool limit of the application Size of the system memory pool Specifies the size of the system memory pool of the application Minimum memory pool segment size Specifies the minimum size of the memory pool segment of the application MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL OS Changer VxWorks Interface Specifies if you have enabled OS Changer VxWorks Interface pSOS Interface Specifies if you have enabled pSOS Interface POSIX LINUX Interface Specifies if you have enabled POSIX LINUX Interface OS Abstractor Interface Specifies if you have enabled the OS Abstractor Interface Process mode Specifies if the OS Abstractor Interface process feature is enabled or disabled Task pooling Specifies if the T
145. gram to C Source Code and keeps the C Source Code in Projects From AppCOE main window select any project under C C Projects tab on the left pane Select New gt New Ada C Project as shown in Figure 8_4 Figure 8 4 Create Ada C Template 4 Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help S2 7 R PE 707 Q77 Projects Profiler Gq C C Projects 3 ls ag v I demo ada to c C demo cross os C demo nudeus C demo posix C demo psos C demo threadx C demo uitron C demo vxworks C demo windows s Import E Sampie AppCOE Red ton New AppCOE C Project AppCOE C Project Ada C Changer Project Ada C Changer Project New Ada C Project New Ada C Project Project AB sudoku Resource Configurations CDT Build Console NewAdaC Ch We Ge Gee el Ka Source Folder Folder Source File Header File File from Template Class 27 Si ci 73 Le b Example Other Ctrl N Note 1 win32 and gnat compatibility are not supported under 64 bit AppCOE Build MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Using the Ada Source Directory The Ada Source directory contains all information needed to support the separate compilation requirements of Ada The primary contents of the Source directory are Ada source files all object modules and info
146. gure 5 18 Importing Nucleus Code Output Projects Application Common Operating Environment A File Edit Source Refactor Bav Search Run Project Tools Window Help ming eG 5 0 H 0 q 4 Ej Debug BD Projects 2 Profiler Fe C C Projects z B 1 demo ada to c Cc demo_cross_os C demo_nucleus C demo_posix C demo_psos n demo uitron ed demo vxworks C demo_windows 4 nucleus legacy jap Includes G include 4 G source e include init 4 source ile application c os application start c C posix_legacy El Problems EJ Console F1 Properties Debug 25 9 items selected 10 You have successfully imported Nucleus legacy C code and a project with your given project name is created in the current workspace MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Porting Threadx Legacy C Code This section explains Porting Threadx Legacy Applications using AppCOE Porting Plugin A sample porting of Threadx Legacy application using AppCOE is described with an example here NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license Select Tools gt Porting gt ThreadX gt Import Legacy C Code as shown in Figure 5_19 You can also click on the Porting icon from the task bar Figure 5_19 Importing ThreadX Legacy C Co
147. hase of the program builder is handled by the linker The linking phase uses the default C runtime library as well as the Ada run time library Adabgen Inputs Invocation adabgen option main procedure name The adabgen command creates an absolute load module for the main procedure The adabgen command must be invoked in a program library directory If the current directory is not a program library directory a program library is automatically created there The main procedure name must be a procedure for which the Ada source for all needed units is located either in the program library or in one of the linked libraries Multiple main procedures may be built in a single invocation of the builder NOTE Do not confuse the name of the source file containing the main unit e g simple ada with the main unit name e g simple MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL adabgen Options In addition to the options listed below adabgen accepts all compiler options These are applied to all invocations of the compiler that are made by the program builder Table 8_5 adabgen Options Options Description 0 The O option identifies the version number of the executable That s a zero not an oh f The f option forces linking to occur even if there are prelinker errors ga Generate Ada oriented debugging information The ga option causes the program builder to build an executable co
148. he mapusoft demo_posix directory location From this location you will find the make files or project files at the appropriate specific OS tools target directory For instance if you need the demo application to be built for POSIX LINUX OS using Eclipse tools and for x86 target then the make file location will be at specific posix lt OS gt x86 eclipse directory We need to have the OS Abstractor Interface Library It has to be included in all the Interface demos After every demo application include link in the POSIX LINUX Interface library OS Changer Nucleus Interface The OS Changer Nucleus Interface library contains the following modules Table 5 5 Nucleus Interface Header File Module Description nucleus interface h This header file is required in all of the Nucleus PLUS source modules This header file provides the translation layer between the Nucleus PLUS defines APIs and parameters to OS Abstraction The OS Changer Nucleus Interface demo contains the following modules Table 5 6 Nucleus Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer Nucleus Interface Before building the OS Changer Nucleus Interface library and or application ensure that the flag INCLUDE OS Nucleus is set to OS TRUE in the cross os usr h configuration file Building OS Changer Nucleus Interface Library The Nucleus Interface library is
149. he following pre processor definition in your project setting or make files Table 6_15 Target OS Selection Flag and Purpose Available Options OS_TARGET The value of the OS_TARGET should be for the OS To select the target Abstractor Interface product that you have purchased operating system For Example if you have purchased the license for OS NUCLEUS Nucleus PLUS from ATI OS THREADX ThreadX from Express Logic OS VXWORKS VxWorks from Wind River Systems OS ECOS eCOS standards from Red Hat OS MQX Precise MQX from ARC International OS UITRON micro ITRON standard based OS OS LINUX Open source commercial Linux distributions OS WINDOWS Windows 2000 Windows XPG Windows CE Windows Vista Windows 7 8 from Microsoft If you need to use the OS Abstractor Interface both under Windows and Windows CE platforms then you will need to purchase additional target license OS_TKERNEL Japanese T Kernel standards based OS OS LYNXOS LynxOS from LynuxWorks OS QNX QNX operating system from QNX OS LYNXOS LynxOS from LynuxWorks OS SOLARIS Solaris from SUN Microsystems OS ANDROID Mobile Operating System running on Linux Kernel OS NETBSD UNIX like Operating System OS UCOS UCOS from Micrium For example if you want to develop for ThreadX you will define this flag as follows OS TARGET OS THREADX PROPRIETARY OS If you are doing your own porting of OS Abstractor Interface to you
150. ibrary Configuration OS Abstractor Process Mode Enabled ere Enter the project name for which you want to import the legacy code in the Project Name text box as shown in the figure Enter the root task prototype as VOID Function Root ULONG argument next to Root Task Prototype text box as shown in the Figure 5_24 Enter the root task stack size next to the Root Task Stack Size text box as shown in Figure 5_24 The value should be in bytes MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 9 Click Finish to complete the importing of legacy code into AppCOE You can see POSIX LINUX legacy code you have imported as shown in Figure 5 24 Figure 5 24 Importing pSOS Legacy Code Output Projects Application Common Operating Environment h File Edit Source Refactor Navigate Search Run Project Tools Window Help rie amp OXR BG M O Q Ej Debug D Projects Profiler Fe C C Projects z B al demo_ada_to_c Cc demo_cross_os C demo_nucleus C demo_posix C demo_psos n demo uitron ed demo vxworks E demo windows 04 nucleus legacy ed posix legacy 4 Cc psos_legacy EP Includes i include 4 source include init 4 source ile application c L dvserial c c os application start c usr c El Problems E Console E Properties Debug 25 n 11 items selected 10 You have success
151. ice Icons Table 1_2 Text and Syntax Conventions Table 1_3 Document Description Table Table 4_1 OS HOST Selection Table 4_2 Target 64 bit CPU Selection Table 5_1 VxWorks Interface Header File Table 5_2 VxWorks Interface Demo Application File Table 5_3 Posix Interface Header File Table 5 4 POSIX LINUX Interface Demo Application File Table 5 5 Nucleus Interface Header File Table 5 6 Nucleus Interface Demo Application File Table 5 7 ThreadX Interface Header File Table 5 8 Nucleus Interface Demo Application File Table 5 9 pSOS Interface Header File Table 5 10 pSOS Interface Demo Application File Table 5 11 OS Changer micro ITRON Interface Header File Table 5 12 OS Changer micro ITRON Interface Demo Application File Table 5 13 OS Changer Windows Interface Header File Table 5 14 Windows Interface Demo Application File Table 6 2 Field descriptions on Profiler Configuration tab Table 6 3 Field descriptions on Platform API Profiling tab Table 6 4 Field descriptions on Application Functions Profiling tab Table 6 5 Field descriptions on API Optimization tab Table 6 6 Field descriptions on Task tab Table 6 7 Field descriptions on Process tab Table 6 8 Field descriptions on Memory tab Table 6 9 Field descriptions on Other Resources tab Table 6 10 Field descriptions on Debug tab Table 6 11 Field descriptions on Output Devices tab Table 6 12 Field descriptions on ANSI Mapping tab Table 6 13 Field descripti
152. icket from AppCOE Figure 2 1 Importing License Figure 2 2 Selecting the Saved License File Figure 2 3 Software Updates Using Remote Site Figure 2 4 Check the Available Updates Figure 2 5 Contacting Software Sites for Updates Figure 2 6 Review and Confirm the Updates Figure 2 7 Remote Update Host Target Feature License Figure 2 8 Remote Updates Download Figure 2 9 Security Warning Figure 2 10 Updating Software Figure 2 11 Restart AppCOE Figure 2 12 Confirmation of new features installed Figure 2 13 Software Updates Using Local Site Figure 2 14 AppCOE Software Updates Figure 2 15 Installing Updates by Using Local Update Site Figure 2 16 Available Software Sites Figure 2 17 Contacting Software Sites for Updates Figure 2 17 Review and confirm the Updates Figure 2 18 Remote Update Host Target Feature License Figure 2 19 Remote Updates Download Figure 2 20 Security Warning Figure 2 21 Restart AppCOE Figure 2 22 Confirmation of new features installed Figure 3 1 AppCOE Components Figure 3 2 AppCOE Architecture Figure 3 3 OS Changer Porting kit Figure 3 4 Cross OS development Platform Figure 4 1 Creating an AppCOE C Project Figure 4 2 AppCOE C Project Wizard Window Figure 4 3 Basic Settings Window Figure 4 4 Configurations Window Figure 4 5 Select APIs Window Figure 4 6 Select Host Library Configuration Window Figure 4 7 Creating AppCOE C C Project Output Figure 4 8 AppCOE C C
153. ided the Ada C C Changer and program builder can automatically locate source files containing the required units as needed The following subsections describe the program library with details about how the Ada C C Changer and program builder use this program library Two tools are provided for maintaining the program library e The program library options tool adaopts can be used to display or modify the program library parameters This creates ADA LIB The source registration tool adareg establishes which units are defined in which source files A description of the use of these tools follows the description of the program library This creates UNIT MAP An Ada program library is based in a directory called the program library directory All information about the program library and all generated files are kept in the program library directory or unspecified subdirectories The main contents of the program library are the source files and object modules There is considerable flexibility with regard to the actual location of the source files This will be evident in the examples that follow Configuration with Multiple Source Directories In a larger program the source files composing the Ada program are often located in several directories To support this source configuration the program library provides a source directory list which points to the directories containing the source In this configuration the source can be distributed
154. ile Predefined Run Time System There is C run time sources that provides I O tasking exception handling and memory management modules which are normally required by Ada 95 language for the C converted code base These are called Ada run time system RTS MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Program Library Options Tool adaopts Overview The program library options tool adaopts supports tailoring the program library to meet the needs of a particular Ada project For small Ada projects it is unlikely that this tool will be needed because the behavior of the compiler and builder are by default configured for small projects For more complex programs the user may direct the program library options tool to distribute source to multiple directories create links to existing program libraries place object modules in a separate subdirectory etc The program library options tool supports the following functions e Creating a new program library e Listing all or specific values for the program library options e Modifying the source directory list the library search list the object file subdirectory the information file subdirectory or the cross reference file subdirectory Listing the source file names or library unit names registered in the program library Program Library Options Tool Outputs The program library options tool modifies the ADA LIB file in the project directory Mes
155. ill get stored as the new option file for that project This gives you the flexibility to use the template when you create the project and also let you change if needed On C C Output tab page describe the C Source Options as shown in Figure 9 6 Figure 9 6 C C Output Page 0 2 Ada C Changer Wizard m o LL Configuration options Set your configurations for Ada C C Changer tool C C output Ada listings Ada messages Ada drivers Additional Variable Naming Full Unique Name 5 Simple Name is Unique Case Sensitivity D As Is Identifier Capitalized gt All Lower Z Remove Name Tables Association Place and on same line as associated construct Place and Y on their own line Checks Suppress all checks in generated C code Suppress numeric overflow checks in generated C code Inciude all run time checks in generated C code Limit on the length of generated C source line 80 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on C C Output tab are as follows Table 9_2 Field Descriptions for C C Output tab Field Description Your Action Variable Naming Specifies if you want to select variable naming You can do any one of the following Full Unique Name means that the first letter of each package name is capitalized as well as the first letter of the simple identifier Note By default this is en
156. in any convenient way among any number of source directories Configuration with Linked Libraries For more complex programming efforts it may be desirable to partition the source code into sub systems each of which is maintained within a separate program library To support this model the Ada program library supports linking to other existing libraries The user need not know the location of the source for a linked library just its program library directory If the linked library is itself linked to another library that library also needs to be added as a linked library for the current library The source files and object modules of a linked library may only be referenced in a read only fashion Specifying the Configuration The program library s configuration is determined by the values of program library parameters The configuration described above is the default configuration created automatically by the first invocation of the Ada C C Changer The primary difference between the multiple source directories model and the multiple linked libraries model is what happens when adabgen discovers that a source file needs to be re compiled e If the source file is part of this program library adabgen will recompile it e Ifthe source file comes from a linked library adabgen will refuse to recompile it and will give an error message Therefore the multiple source directories model is more convenient for most projects ADA
157. ion Full Source Library Package generation Contact MapuSoft to receive the components needed for using AppCOE The steps for using AppCOE are comprehensively described in the following pages MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Installing AppCOE You can download an evaluation copy from our website or install AppCOE via the evaluation CD given by MapuSoft Technologies To install AppCOE I NOTE Click on the exe or tar file from CD download and run it A welcome html page will be auto run Select Host For Windows Host l 2 For Ada C C Changer M Product download appcoe x32 exe or appcoe x64 exe into the local drive For OS Changer amp Porting Kit Cross OS Development Platform Cross OS Hypervisor Linux OK OS Simulator M App Platform Profiler OS Version UpKit M products download either appcoe x32 exe or appcoe x64 exe depending on the host machine CPU architecture Installer wil ask for a directory to install AppCOE release Browse to the directory or provide a directory name when prompted Once AppCOE is installed reboot the system AppCOE will not run properly without re boot Now Run the AppCOE exe in AppCOE lt installdir gt or launch the AppCOE application from the windows shortcut in desktop For Linux Host l 2 For Ada C C Changer M Product download app coe linux x32 tar gz into the local drive For OS Changer Porting Kit Cross OS Deve
158. ions E demo pesix Make Targets E demo so Build Project C demo threacx Clean Project E demo uitron Copy File from Template C demo vxworkt Class D demo window Delete B cC Projects Source Folder Folder Source File Header File txampie Move Rename Other import Export Ketresh Close Project Run As Debug As Profile As bperties Validate Convert To Resource Path Location Type Team Compare With Restore from Local History demo ross os W Run C C Code Analysis MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 On AppCOE C Project Wizard window type a project name and give a location next to Project Name text box 4 Under Project Types expand the Executable menu Select AppCOE Template Project and click Next as shown in Figure 4_10 Figure 4_10 AppCOE C Project Wizard Window AppCOE C Project Wizard Creates AppCOE C Project Project name Sample AppCOE Project V Use default location D MapuSoft appcoe AppCOE_Winx32_Beta2 workspace Sample_A Project type Toolchains 4 Executable MinGW GCC Empty Project AppCOE Template Project Shared Library Static Library 7 Show project types and toolchains only if they are supported on the platform MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On Basic Settings window define the basic properties of your project and click Next as shown in Figure
159. k OS Lh OS Get Current Task Id OS Create Event Grouj OS Get Event Grouj Functions m E Properties 53 Property Value Average Function execution time 3 243 023 384 Nano Seconds Instance with the longest total execution time OS_Get_Events Instance with the shortest total execution time OS Get Event Group Id Number of functions used by this thread 7 Thread ID Task 1 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL You can view App Platform Profiler Perspective as shown in Figure 7_3 Figure 7_3 App Platform Profiler Perspective n Tools Window Help ri BRB amp v zwi HN SP C din Ej Debug 2 Projects Profiler Data Explorer 23 Profiler View 23 4 profiler data 1210343810 System 5 Functions Platform APIs Q Application Functions Threads Task 1 Task 2 4 0 Task 3 Platform APIs Q Application Functions Task 4 Task 5 Task 6 Task 7 Function Iterations Ip ip Id OS Protect OS Unprotect OS Get Events OS Create Task OS Create Event Groul OS Get Current Task Id OS Get Event Grouj 4 m E Properties 25 Property Value Average Function execution time 3 243 023 384 Nano Seconds Instance with the longest total execution time OS Get Events Instance with the shortest total execution time OS Get Event Group Id Number of functions used by this thread 7 Thread ID Task 1 MAPUS fFT APPLICATI
160. latform Figure 6 2 OS Abstractor Flow Diagram Figure 6 3 Generating Library Package Figure 6 4 Select Target OS MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 6_5 Select OS Changer or OS Abstractor Products Figure 6_6 Select Destination Path Figure 6_7 Full Library Package Generation Verification Report Figure 6_8 Full Library Package Generation Folder Figure 6_9 AppCOE Target Code Generator Figure 6_10 Selected VxWorks Target in this Example Figure 6_11 Select the linked in Libraries Figure 6_12 Profiler Configuration Figure 6_13 Platform API Profiling Figure 6_14 Application Function Profiling Figure 6_15 API Optimization Figure 6_16 Task Tab Figure 6_18 Memory Tab Figure 6_19 Other Resources Tab Figure 6_20 Debug Tab Figure 6_21 Output Devices Tab Figure 6_22 ANSI Mapping Tab Figure 6_23 Device Input or Output Tab Figure 6_24 Interface Tab Figure 6_25 Target Code Generation Output Figure 6_26 AppCOE Generated Example Figure 6_27 Generating Project Files Figure 7_2 Opening App Platform Profiler Perspective Figure 7_3 App Platform Profiler Perspective Figure 7_4 App Platform Profiler System Details Figure 7_5 App Platform Profiler System Figure 7_6 Platform APIs and Application Functions Figure 7_7 Platform APIs Figure 7_8 Application Functions Figure 7_9 App Platform Profiler Threads Figure 7_10 Viewing AppCOE Profiler Data Figure 7 11
161. lication The demo application is located at the mapusoft demo_uitron directory location From this location you will find the make files or project files at the appropriate specific OS tools target directory For instance if you need the demo application to be built for micro ITRON OS using Eclipse tools and for x86 targets then the make file location will be at specific uitron lt OS gt x86 eclipse directory MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL OS Changer Windows Interface The OS Changer Windows Interface library contains the following modules Table 5_13 OS Changer Windows Interface Header File Module Description windows_interface h This header file is required in all of the Windows source modules This header file provides the translation layer between the Windows defines APIs and parameters to OS Abstraction The Windows Interface demo contains the following modules Table 5 14 Windows Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer Windows Interface Before building the WINDOWS Interface library and or application ensure that the flags INCLUDE OS WINDOWS and INCLUDE OS PROCESS are set to OS TRUE in the cross os usr h configuration file Building OS Changer Windows Interface Library The WINDOWS Interface library is located at ymapusoftVwindows interface directory From
162. lication application function functions enter the name in the text box and click Add Remove Specifies if you want to TO remove any remove any application application function functions from the list from the list select the name of the application function in the text box and click Remove Add your APIs by typing in the name of the API next to Enter Application Function text box and click Add and click Next MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 9 On API Optimization tab you can select either to generate Full API Library Interface or Optimized API interface In API Optimization you can select the API s which needs to be a standard function or a macro function and move the selected API using the double arrow button as shown in Figure 6_15 Macro functions will execute faster but will increase the memory footprint of the application and click Next Figure 6_15 API Optimization D Optimized Target Code Generator This wizard optimizes target specific source code Generate Full API Library Interface Q9 Generate Optimized API Interface Files Select whether the API needs to be a standard or a macro function Macro functions will be faster as they do not have a function wrapper To change a standard function into a macro function select the name in the standard function column and click the gt gt arrow To change a macro function to a standa
163. lication Building OS Changer pSOS Interface Building OS Changer pSOS Interface Library Building OS Changer pSOS Interface Demo Application OS Changer micro ITRON Interface Building OS Changer micro ITRON Interface Building OS Changer micro ITRON Interface Library Building OS Changer micro ITRON Interface Demo Application OS Changer Windows Interface Building OS Changer Windows Interface Building OS Changer Windows Interface Library Building OS Changer Windows Interface Demo Application Building Application with Multiple Interface Components Building Application with Multiple Interfaces Developing Applications with Multiple Interfaces Chapter 6 Using Cross OS Development platform About Cross OS Development Platform About OS Abstractor Interfaces Available for OS Abstractor Full Library Package Generator Generating Binary Packages Generating Full Library Packages MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Generating Binary Packages Optimized Target Code Generator Generating Optimized Target Code Click Apply and OK Optimized Target Code Generation for Ada Projects Generating Project Files for your Target Inserting Application Code to Run only on Target OS Environment Running AppCOE Generated Code on your Target Chapter 7 App Platform Profiler About App Platform Profiler Opening App Platform Profiler Perspective Components on the App Platform Profiler Window Viewing App Platform Profiler Data Generating API Timing
164. ll This works toward getting the migration effort faster and much easier Figure 5_1 About OS Changer Your Application QS CHANGER OS Abstractor Porting Kit your OS OS Changer is designed for use as a C library Services used inside your application software are extracted from the OS Changer and TARGET OS libraries and are then combined with the other application objects to produce the complete image OS Changer is optimized to take full advantage of the underlying TARGET RTOS features It is built to be totally independent of the target hardware and all the development tools like compilers and debuggers Please note that there may be some minor implementation differences in some of the OS Changer APIs when compared to the native API s This may be as a result of any missing features within the underlying RTOS that OS Changer provides migration to MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL MAPUSQDFT SOSCHANGER Flow Diagram STEP ONE Choose an option a d 4 Option Ove Option Two Full Source Package Generation z F E a n E 5 i 3 i 1 i i I Jl i ji i j Contnue to STEP i B n www mapusoft com 1 877 MAPUSOFT Continue to STEP TWO Figure 5 2 OS Changer Flow Diagram Your legacy application can be re usable and also portable by the support provided by the OS Changer library and the OS Abstractor library Applications can directly use the
165. location will be at specific psos lt OS gt x86 eclipse directory OS Changer micro ITRON Interface The OS Changer micro ITRON Interface library contains the following modules Table 5_11 OS Changer micro ITRON Interface Header File Module Description uitron interface h This header file is required in all of the uITRON source modules This header file provides the translation layer between the uITRON defines APIs and parameters to OS Abstraction The OS Changer micro ITRON Interface demo contains the following modules Table 5 12 OS Changer micro ITRON Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer micro ITRON Interface Before building the OS Abstractor micro ITRON Interface library and or application ensure that the flag INCLUDE OS UITRON is set to OS TRUE in the cross os usr h configuration file Building OS Changer micro ITRON Interface Library The OS Abstractor micro ITRON Interface library is located at mapusoft uitron_interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for uITRON OS using Eclipse tools and for x86 target then the make file location will be at specific vuitron V OS Mx86 eclipse directory Building OS Changer micro ITRON Interface Demo App
166. lopment Platform Cross OS Hypervisor Linux OK OS Simulator M App Platform Profiler OS Version UpKit products download either app coe linux x32 tar gz or app coe linux x64 tar gz depending on the host machine CPU architecture Extract the tar file app coe linux x32 tar gz or app coe linux x64 tar gz You will get install sh amp app coe linux bin Run the install sh program it will check for dependency needed for installing AppCOE Install the missing dependencies and try running this script again If no dependencies is found AppCOE installer will start Installer wil ask for a directory to install AppCOE release Browse to the directory installdir or provide a directory name when prompted ensure that the logged in user has full read write execute privileges to in this install directory After AppCOE gets installed install sh will check for AppCOE dependencies Install the missing dependencies if any Then run app coe linux bin to launch the AppCOE installer Repeat steps 2 4 as in the Linux host For Windows Host By default it is c MapuSoft AppCOE For Linux Host By default path is usr local AppCOE Do not provide special characters to the installdir as you will get java run time errors AppCOE may have problems with paths containing spaces and if not usually other programs used with AppCOE will experience problems with such paths MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANU
167. me posix C demo_windows C nudez legacy C pose legacy C psos legacy C uitron legacy B eurn Problems amp Console T Properties Debug C Build Ade Sudciku funsigned char Xlinker stack Xlinker 00 Ada_Sudoku source sudoku_test adb o ada2CCe MAd MMda SudokuNlsourceVmudoku adb o sdaZCC Ada_Sudokm lrrtl lwines Build com Time cor Ade Sudcku Debxxg Ada Sudoku exe NOTE 1 When you build Ada C C Changer project you may get many warnings Target Code Generation for Ada C C Changer Projects AppCOE allows Target Code Generation for Ada C C Changer Projects when the Ada C C Changer projects are created with Real time OS Abstractor Scheduling or Ada C C Changer Scheduling For Ada C C Changer Projects OS Abstractor interfaces are added directly to the project as target sources if you have a valid and relevant Full Library Package Generator license If Target Code Generation is attempted on these projects all the OS Abstractor functionality being part of application is again redefined in cross os c This will give re definition errors on compile time NOTE For Ada C C changer projects along with Abstractor if you do target code generation it will generate sample project files You have to generate your own project files to generate binaries MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Manual Modifications to Projects files generated by Target Code Generator The target c
168. modules This header file provides the translation layer between the pSOS defines APIs and parameters to OS Abstraction MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The pSOS Interface demo contains the following modules Table 5_10 pSOS Interface Demo Application File Module Description demo c Contains a sample demo application Building OS Changer pSOS Interface Before building the pSOS Interface library and or application ensure that the flag INCLUDE OS pSOS is set to OS TRUE in the cross_os_usr h configuration file Building OS Changer pSOS Interface Library The pSOS Interface library is located at mapusoft psos interface directory From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for pSOS OS using Eclipse tools and for x86 target then the make file location will be at specific psos_interface lt OS gt x86 eclipse directory Building OS Changer pSOS Interface Demo Application The demo application is located at the mapusoft demo_pSOS directory location From this location you will find the make files or project files at the appropriate specific lt OS gt lt tools gt lt target gt directory For instance if you need the demo application to be built for pSOS OS using eclipse tools and for x86 target then the make file
169. n AppCOE Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help CX m lt Pp 0 QS 5 VxWorks E BD Projects Profiler psos 2B Nucleus IO D He C C Projects 3 ThreadX POSIX s micro ITRON C demo_posix Windows gt Import Legacy C Code C demo_psos n demo threadx n d E AJ demo_ada_to_c demo uitron C C demo vxworks C demo windows Problems El Console 23 E Properties MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL On AppCOE Import Window select the Import Application Project Library Project radio button with reference to your project Here we are considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5 29 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5 29 Import Windows Legacy Code 2 Import Import Windows Legacy Code Select a Directory to Import Windows Legacy Code into AppCOE 9 Import Application Project Import Library Project Root Directory E ExamplesLegacyDemosMLegacy Windows App Browse Project Name windows_legacy Root Task Prototype int win main int argc Root Task Stack Size
170. n file To generate full source library package follow the steps To generate full library package a From AppCOE main menu click Full Library Package Generator button on the tool bar as highlighted in Figure 6_3 Or select Tools gt Full Library Package Generator Figure 6_3 Generating Library Package Fie Ed Sowce Refactor Navigate Seach fuse Project Took Window Heip r Ww o HN amp Em O Debug O Pregects 2 Profe R License Po Full Lisrary Package Generate BE Ade CIC Change 1 wn nnnnnnnonnnna MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL b On Full Library Package Generator window select the required Target OS from the list and click Next as shown in Figure 6_4 Figure 6 4 Select Target OS e a D Full Library Package Generator Choose a target OS from below and select next to continue 9 uCOS RT Linux Android D Windows micro ITRON QNX VxWorks NetBSD Nucleus MQX Solaris LynxOS Linux ThreadX Finish Cancel MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL c Select the development OS APIs needed to generate full library package and click Next as shown in Figure 6_5 Figure 6_5 Select OS Changer or OS Abstractor Products Pi ESEIT i i pe Full Library Package Generator Choose your current and or development OS APIs Select next to continue OS Abstractor Interface Nucleus Interface VxWorks Interface pS
171. native target OS API however doing so will not make your code portable across operating systems We recommend that you use the optimized abstraction APIs for the features and support that are not provided by the OS Changer compatibility library NOTE For more information on configuration and target OS specific information see OS Abstractor Interface Reference Manual Interfaces Available for OS Changer The following are the interfaces available for OS Changer e VxWorks e Nucleus e pSOS micro ITRON POSIX LINUX Windows ThreadX MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Using OS Changer OS Changer is designed for use as a C library Services used inside your application software are extracted from the OS Changer and TARGET OS libraries and are then combined with the other application objects to produce the complete image This image can be loaded to the target system or placed in ROM on the target system The steps for using OS Changer are described in the following generic form Remove the TARGET RTOS header file defines from all the TARGET RTOS source files Remove definitions and references to all the TARGET RTOS configuration data structures in your application Include the TARGET RTOS interface h For example nucleus interface h in case of OS Changer Nucleus Interface and os target h in the source files Modify the OS Changer init code see sample provided and the TARGET RTOS root task o
172. nd user MinGW provides a complete Open Source programming tool set which is suitable for the development of native MS Windows applications and which do not depend on any 3rd party C Runtime DLLs MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL GNU Compiler The GNU Compiler Collection includes front ends for C C Java as well as libraries for these languages such as libstdc libgcj AppCOE Supplied GDB A debugger is a computer program that is used to test and debug other programs the target program The code to be examined might alternatively be running on an instruction set simulator ISS a technique that allows great power in its ability to halt when specific conditions are encountered but which will typically be somewhat slower than executing the code directly on the appropriate processor Some debuggers offer two modes of operation full or partial simulation to limit this impact Typically debuggers also offer more sophisticated functions such as running a program step by step single stepping or program animation stopping breaking pausing the program to examine the current state at some event or specified instruction by means of a breakpoint and tracking the values of some variables Some debuggers have the ability to modify the state of the program while it is running rather than merely to observe it It may also be possible to continue execution at a different location in the program
173. ng the ability to develop amp use portable application 1 OS Abstractor development interfaces from Mapusoft OS Abstractor Target Specific Module specific to each target OS provides the connection to your target operating system s Linux POSIX Interface Providing the POSIX LINUX re host capability micro ITRON Interface Provides ITRON re host capability Developers also have the ability to choose multiple Interfaces for use within the same application and existing applications can connect to the appropriate Interface for re hosting on a different OS Figure 6_1 Cross OS Development Platform Cross OS Development Platform rot Mic ula Linux POSIX Your Applications OS Abstractor In house abstraction MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL About OS Abstractor OS Abstractor is designed for use as a C library Services used inside your application software are extracted from the OS Abstractor libraries and are then combined with the other application objects to produce the complete image This image may be downloaded to the target system or placed in ROM on the target system OS Abstractor will also function under various host environments Developing a solid software architecture that can run on multiple operating systems requires considerable planning development and testing as well as upfront costs associated with the purchase of various OS and tools to validate your software MapuSo
174. nlibrany v Sharewith v New folder Name Date modified X Favorites Lj profiler data 20131112116 pal 3j Libraries W timing comparsion report Documents d Music ial New Library ks Pictures E Subversion E Videos MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 8 Introduction to Ada C C Changer This chapter contains the following topics Ada C C Changer in AppCOE Error Reference source not found Creating Ada C Changer project Using the Ada Source Directory Configuration with Linked Libraries Configuration with Multiple Source Directories Specifying the Configuration Program Library Options Tool adaopts Source Registration Tool adareg Adacgen Adacgen Options MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada C C Changer in AppCOE Note This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license Ada C C Changer allows developers to easily convert software written in Ada code to C C utilizing AppCOE The resultant C C software can be integrated with the robust OS Abstractor environment to support a wide variety of host and target OS platforms The automatic conversion process eliminates the need for costly and tedious code rewrites providing extensive resource savings Ada C C Changer generates ANSI C output as well as certain C features while preserving Ada code
175. ntaining Ada oriented debugging information The ga option is also applied to any implicit invocations of the compiler during program building Generate C oriented debugging information The gc option causes the program builder to build an executable containing C oriented debugging information The gc option is also applied to any implicit invocations of the compiler during program building h or help The help option shows the options that can be used with the adabgen command ke The ke option specifies that intermediate files which are normally deleted are to be kept l option The ll switch passes option to the target linker For example to pass map foo map to the target linker use ll map llfoo map Options passed via the ll switch follow the options to the linker that is generated by the Ada program builder The nc option prevents recompilation Normally the Ada C C Changer is invoked by the adabgen command to recompile Ada programs as needed The nl option prevents calling the linker The prelinker is called but the target linker is not no The no option prevents recompilations to recreate o files that are out of date o file The o option specifies the name of the output file used instead of the default filename ol file The ol file option passes file to the target linker q The q option specifies quiet mode F Use a m
176. nte Open in New Window 4 Q eda Tech 4 i Det Index Build Configurations Make Targets Build Project Clean Project Copy Delete Mowe Rename impot 5 bport Reh Chose Project Run As Debug As Prefde As T m ems 2 Console Properties Debug 0 T 205m Team oe Compare Wah Restore from Local history Properties sda Comp The Ada C C Changer property page is displayed as shown in the Figure 9 18 Make the necessary changes and click Apply To change the Main Procedure Name on the Ada C C Changer property page click on Additional tab and make the necessary changes and click Apply MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 9 18 Ada C C Changer Property Page 12 Properties for NewAdaC type filter text Ada Changer Resource idajcbanger Ada Source C C output Ada listings Ada messages Ada drivers Additional Builders m 8 C C Build Additional options TET C C General Project References Run Debug Settings Task Tags Validation Compatibility AT Compatibility Ada Main Procedure hello world Restore Defaults l Apply C When you do an Ada Build you can re import files or import deleted files remove any files or change the Main procedure name on this page You can modify on any of the configurations on the property page NOTE You cannot edit or modify the Ada Source Direct
177. ode remove references to the original OS include files and use os_target h and the header files of your ported legacy API instead l 2 Remove the original OS specific initialization code and use OS Application Init function call instead refer to the OS Abstractor Interface Reference Manual Create an AppCOE C C project for your legacy application and select the legacy API that your application will need E g to port VxWorks application you need to check the Include OS Changer VxWorks Interface API s If your application uses any APIs that are not supported under AppCOE re write the code using OS Abstractor Interface APIs Import your legacy application into the new project Compile and link your application and resolve all compiler and linker errors Run or debug your application under AppCOE host in an x86 environment You should rewrite replace any hardware specific code in your application for this step Step 2 Moving from AppCOE Host to target using AppCOE Optimized Target Code Generator Generate the code for your target OS using the AppCOE Optimized Target Code Generator Using cross compiler compile link and download the AppCOE generated code to your target Port low level drivers and hardware interrupt code as required refer to OS Abstractor Interface I O and device driver APIs sections in the OS Abstractor Reference Manual Resolve any run time errors MAPUS fFT APPLICATION COMMON OPERATING E
178. ode output produced when optimizing Ada projects via the target code optimization process is a little different than that of the standard C C AppCOE project In this case the API level optimization process is skipped as the application needs to link in other required RTL C C libraries and possible other C interface libraries Instead of the OS Abstractor code being included as part of the application it is added into the target directory as a separate code base that should be built as libraries There will be separate libraries for the OS Abstractor component as well as any other OS Interface components like VxWorks Windows etc included in the project There will also be a separate Ada Run Time Library RTL required to be linked in as well For example if a converted Ada to C C project that was integrated with OS Abstractor and includes the POSIX Linux Interface were optimized for a windows target it would look like follows lt target dir gt cross os windows source include Specific posix interface source include Specific include include rtl XIL sre IL lt app name gt ada2C lt app name gt source include The lt target_dir gt is the directory location where the generated code would be placed The OS Abstractor and OS Abstractor Interface directories will include project files specific to your target Project files for the RTL will only be included for Windows and Linux targets Ona Windows target you
179. ofiling Specifies if the OS Abstractor Interface API Profiling feature is enabled or disabled Select the check box to enable platform profiling Platform Profiling means OS Abstractor Interface APIs profiling NOTE By default OS Abstractor Interface API profiling is enabled for all projects Enable POSIX LINUX Interface API Profiling Specifies if OS Abstractor POSIX LINUX Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your POSIX LINUX APIs Enable micro ITRON Interface API Profiling Specifies if OS Abstractor micro ITRON Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your micro ITRON APIs Enable Windows Interface API Profiling Specifies if OS Changer Windows Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your Windows APIs Enable VxWorks Interface API Profiling Specifies if VxWorks Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your VxWorks Interface APIs Enable pSOS Interface API Profiling Specifies if OS Changer pSOS Interface API Profiling feature is enabled for your project Select the check box if you need profiling for your psOoOs Interface APIs Enable Nucleus Interface API Profiling
180. ogram A single Ada source file can have any kind of code within it though some compilers are more restrictive than that and use specific naming conventions such as Rational s 1 ada and 2 ada or AdaCore s ads and adb Ada Tool is designed to handle any organization of code within source files Furthermore even though a source file might contain only a package spec it might still have code that needs to be executed when the package is elaborated This code will be placed in the c file for the package spec Similarly even though a file might contain only a package body it might have subunits or inlined subprograms that need access to its local declarations and so those are placed in an h file for the body Ada C C Changer is very portable because the Ada Tool s RTS relies mostly on the standard C run time However C run time support is not truly real time as it uses C setjmp longjmp to accomplish multi threading which is not very flexible But by adapting the Ada Tool RTS to use the OS Abstractor POSIX LINUX Interface Mapusoft APIs we can use true multithreading and still be very portable to multiple OS and RTOSs MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 9 Working with Ada Changer This chapter contains the following topics Working with Ada C C Changer Projects Ada C Changer Projects with Ada C C Scheduling Ada C Changer Projects
181. olaris c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Solaris you could do it here before calling OS Main os init threadx c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on ThreadX you could do it here before calling OS Main Os init uitron c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on micro ITRON you could do it here before calling OS Main os init vxworks c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on VxWorks you could do it here before calling OS Main os init windows host c These functions are the various entry functions for the different operating systems This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Windows host you could do it here before calling OS Main When optimizing you will need to write an equivalent function for your target operating system
182. ons on Device I O tab Table 6 14 Field descriptions on Interface tab Table 6 15 Target OS Selection Table 7 1 Field descriptions for importing the PAL file Table 8 1 Compiler Generates the Requested listing Options for Each File Table 8 2 adacgen Options Table 8 3 Options For Maintainers Table 8 4 Compiler Output Files Table 8 5 Additional Compiler Output Files Table 8 5 adabgen Options Table 9 1 Field Descriptions for Import Ada Files Table 9 2 Field Descriptions for C C Output tab Table 9 3 Field Descriptions for Ada Listings tab Table 9 4 Field Descriptions for Ada Messages tab Table 9 5 Field Descriptions for Ada Drivers Options tab Table 9 6 Field Descriptions for Additional Options tab MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 1 About this Guide This chapter contains the following topics Objectives Audience How to Use This Manual Document Conventions MapuSoft Technologies and Related Documentation Requesting Support Documentation Feedback MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Objectives This manual describes about AppCOE IDE and offers information on porting your application to different toolsets and platforms and information on how to use our functionality and learn our user interface UI AppCOE provides a multiple OS interface host environment with provisions to generate optimized code for a wide variety of target OS
183. ons to the back end All text within the quotations is passed directly to gcc These options precede the other options that adacgen generates and passes to gcc Record layout listing for packed record types The q option specifies quiet mode It suppresses all nonessential messages Record layout listing for all record types The s option suppresses all automatic runtime checking including numeric checking This option is equivalent to using pragma Suppress on all checks Suppress Language Exception Handlers If this option is specified exception handlers that handle predefined exceptions Constraint_Error Program_Error Tasking Error and Storage_Error are removed from the program if the exception is always propagated speh Suppress Propagating Exception Handlers Same as sleh but applies to user defined exceptions as well MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Options Description This option has the same effect as using pragma suppress aggregate temps Suppress Aggregate Temps T The T option causes the compiler to report timing information for the compilation of each source file specified on the command line V The v option specifies verbose mode The marked Adabgen options are already added in Ada C C Changer Do not add these in your additional options tab If you add these options it will break your application
184. or or other interfaces Select the check box to enter the main Ada procedure name For example Sudoku_Test Note To import a library project use the all option for the main procedure Enter Ada File Extensions used in your Ada Project Specifies the source files that have extensions other than the default extensions listed in the drop down list The default extensions listed here are a ada adb ads bdy dat spc sub You can do any one of the following e To add a new extension other than the default ones enter in the text box and click Add Note By default this is enabled To remove an extension select the extension from the drop down list and click Remove Notel Default extensions available cannot be removed already Note 2 Ada Extensions are case sensitive Specify Option File Specifies if the user wants to specify any set of options that are needed for the Ada C C Changer Note This can be created using space as delimiter To specify an option file select the check box and click Browse and select the option file Note If option file is specified then Ada configuration options page will open with the specified options in the option file If not specified then Ada Configuration options page opens with the default options User can select or over ride the options in this page NOTE If you create your Eclipse Workspace in a deeply nested s
185. ore friendly elaboration order The default is to use an order that is more likely to fail but which can lead to more portable programs The v option causes the program builder to print informational messages as processing proceeds The v option is also applied to any implicit invocations of the compiler during program building The marked options are already added in Ada C C Changer Do not add these in your additional options tab If you add these options it will break your application MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Ada C C Changer Outputs Output Files The Ada program builder generates a corresponding load module for eg main procedure name exe Messages All program builder messages are written to console view Main features of Ada C C Changer The Ada run time is written in Ada 95 and then translated to C C The run time is layered and is re hostable on various operating systems As delivered it depends only on C s native setjmp longjmp but is structured to allow re hosting on POSIX LINUX like OS s or other RTOS s that have support for threads and some kind of mutex Ada C C Changer converts 100 of the Ada source into C with no human intervention Our tool is based on a fully validated Ada C C Changer which handles the full Ada 95 language It produces efficient and readable C that exactly matches the semantics of the original Ada pr
186. ort 4 Export Ome maaan Problems amp Console E Properties CDT Build Console NewAdaC Source Folder Folder Source File Header File File from Template Class 63 C3 ie R G Example L L m Other Ctrl N f On Ada C Changer Project Wizard window type a project name and give a location next to Project Name text box Note 1 The project name should not be more than 256 characters Note 2 Please avoid creating an eclipse workspace in a deeply nested sub directory 4 Under Project Types expand the Executable menu Select Ada C C Scheduling or Real time OS Abstractor Scheduling and click Next as shown in Figure 9_2 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 9 2 Ada C C Changer Wizard Ada C Changer Wizard T Ada C Changer Wizard Create Ada C Changer Project Project name Sudoku v Use default location D MapuSoft appcoe AppCOE_Winx32_Beta2 workspace Sudoku Project type Toolchains 4 Executable MinGW GCC Ada C C Scheduling Real time OS Abstractor Scheduling V Show project types and toolchains only if they are supported on the platform Cancel Ada C Changer Projects with Ada C C Scheduling Ada C Changer Projects created with Ada C C Scheduling will not include OS Abstractor Features Ada C Changer Projects with Real time OS Abstractor Scheduling Ada C Changer
187. ory location MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL ADA C C Changer Additional Information s Warning messages While importing an Ada project you will receive 3617 warning messages It appears that most if not all of them are associated with the rtl files They are as follows e Defined but not used variables 3129 e Return with no value in function returning non void 15 e Assignment from incompatible pointer type 52 Comparison is always false due to limited range of data type 94 Cast from pointer to integer of different size 3 Comparison of distinct pointer types lacks a cast 8 Control reaches end of non void function 71 Implicit declaration of function 10 Initialization from incompatible pointer type 5 Integer constant is so large that it is unsigned 1 Left shift count gt width type 1 Missing braces around initializer 2 Passing arg from incompatible pointer type 114 Statement with no effect 28 Unused variable 83 This decimal constant is unsigned only in ISO C90 1 NOTE When you are working on 64bit architecture make sure that m32 flag is added to both the compiler and linker options in project properties to avoid compilation errors MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Additional Ada C C Changer tools Ada C C Changer is equipped with following additional tools 1 Ada Line Count This feature enables you to count
188. ory to search for existing workbench projects by clicking on Browse button next to the text box and click Next as shown in Figure 5_4 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process In Import Wind River Workbench Projects window the projects list is displayed in a checkbox Tree Application projects and Library projects are separated into respective categories Select or deselect any one or all of the projects by selecting the check box next to the project name and click Finish to import the project as shown in Figure 5_4 Figure 5_4 AppCOE Import Window 2 Import Import Wind River Workbench Projects Select a Workspace to Search for existing Workbench Projects Select Workspace Directory E Examples LegacyDemos Legacy_Workbe Browse Host Library Configuration T OS Abstractor Process Mode Enabled Cancel MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The following are the project types 8 Application Projects Provides an executable application This project type folder contains three templates The makefile for the Executable project type is automatically created by the CDT Library Projects An executable module that is compiled and linked separately When you create a project that uses a shared library libxx so you define your shared library s project as a Project Reference for your application The mak
189. ou could do it here before calling OS Main os init linux c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Linux you could do it here before calling OS Main os init lynxos c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you want to add a signal handler on Lynxos you could do it here before calling OS Main os init mqx c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you wanted to add a signal handler on MQX you could do it here before calling OS Main os init nucleus c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you wanted to add a signal handler on Nucleus you could do it here before calling OS Main MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Os init qnx c This function is the entry function for the native operating system This is where you should put any of your operating system specific code For instance if you wanted to add a signal handler on QNX you could do it here before calling OS Main OS init s
190. ound MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Generating Optimized Target Code This section describes how to generate optimized target code using AppCOE Most of the configurations described below can also be changed at run time using the OS_Application_Init function NOTE 1 This feature requires a target license Click http mapusoft com contact to send a request to receive licenses and documentation NOTE 2 For all Optimized Target Code Generation the preprocessor OS_HOST flag is set to OS_FALSE If the user intends to do the host development on the optimized target code they need to change this preprocessor flag to OS_TRUE manually NOTE 3 On Linux target PC hangs while running demo_uitron from terminal if you terminate the execution by Ctrl C Make sure that define OS BUILD FOR SMP is set to False when compiling for non SMP processors NOTE 4 If you select a library project which either has a C C generic library project or AppCOE library project Target Code Generator icon is disabled NOTE 5 API optimization is not supported for AppCOE libraries linked with application project during target code generation NOTE 6 The Eclipse Indexer may report errors after successfully building an application These errors are related to missing symbols and are due to the fact that the indexer is not detecting the changes in the source files which are generated and select Index Rebuild from the context
191. pdate Site file C mapusoft App COE updatesite http Jjdowrload eckpse org bit update sitej3 7 hitp download ecipse org datatools updates http jdowrload ecipse org tools cdt Jreleases indigo hitp download eclipse org tools gefjupdatesireleases hitp download ecipseorg webtools reposkory uno http www ecipse org modeingjupdates bi tp Jwewew mapusoft com appcoe update 1 3 9 100008 Dd o Name AppCOE Update Ste Location file C mapusoft AppCOE updatesite RN 4 Contacting Software Sites for Updates as shown in Figure 2 16 Figure 2 17 Contacting Software Sites for Updates 7 Projects Application Common Operating Environment Appcoe Fig cic Projects 5 RA demo_ada_to_c demo cross os 5 C demo nudeus C demo posi D demo psos demo threadx C demo_uitron C demo_vxworks i C demo_windows Contacting Software Sites j cheno for updates A Always run in background Run in Background Cancel Details gt gt Problems El Console 23 E Properties No consoles to display at this time Contacting Software Sites 50 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 5 On Available Updates Window select the features under the AppCOE Update Site tree parent and click Next as shown in Figure 2_17 Figure 2_17 Review and confirm the Updates Available Updates Update Details Review and
192. platforms Topics in this manual also apply to the other MapuSoft s interfaces supported by OS Changer which allows you to re use a wide variety of legacy code such as VxWorks pSOS Nucleus PLUS POSIX LINUX Windows uITRON ThreadX Audience This manual is designed for anyone who wants to port applications to different operating systems create projects and run applications This manual is intended for the following audiences e Customers with technical knowledge and experience with the Embedded Systems e Application developers who want to migrate their application to different RTOSs e Managers who want to minimize the cost and leverage on their existing code How to Use This Manual This manual and the other MapuSoft Technologies manuals explain how to port and migrate applications to different operating systems The organization of this document is as described below Using these documents you can e Develop amp Port legacy applications e Generate code optimization amp target code generation e Generate Full Library Package OS Abstractor OS Changer Packages Enable Application profiling and platform profiling Convert Ada 83 95 applications to C C MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Document Conventions Table 1_1 defines the notice icons used in this manual Table 1_1 Notice Icons Icon Meaning Description Informational note Indicates important features or icons A Caution
193. played On the bottom of the window the function properties are displayed such as e Average Function execution time e Function with the longest execution time e Function with the shortest execution time Number of OS Abstractor Interface Functions called in application MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL If you expand the Platform APIs you can view all the platform APIs called in the application as shown in Figure 7_7 On the bottom of the window the function properties are displayed such as Average execution time Instance with the longest execution time The Task _1 in square brackets denote that these function properties belong to the Task 1 Thread Instance with the shortest execution time e Total number of times function was called If you click on a Platform API you can view the number of instances of the specific function on the x axis and the time taken for each API on the y axis NOTE On top of the profiler view you can view different measures of time such as e Seconds milli seconds micro seconds e nano seconds as highlighted in the Figure 7_7 This is used to capture the time taken for each instance of the function in different time measures If you click on nano seconds the time graph will be shown as Time nano seconds as shown in the Figure 7_7 Figure 7_7 Platform APIs Profiler demo cross os source os init windows host c Application Common Operatin File Edit Source
194. project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5_11 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5_11 Import Legacy Code Window Import Import Posix Legacy Code Select a Directory to Import Posix Legacy Code into AppCOE 9 Import Application Project Import Library Project Root Directory E Examples LegacyDemos Legacy_Vxwerks_App Browse Project Name vxworks legacy Root Task Prototype int usrRoot UNSIGNED argc Root Task Stack Size in bytes OS MIN STACK SIZE Host Library Configuration 7 OS Abstractor Process Mode Enabled Enter the project name for which you want to import the legacy code in the Project Name text box Enter the root task prototype as int usrROOT UNSIGNED argc next to Root Task Prototype text box Enter the root task stack size next to the Root Task Stack Size text box The value should be in bytes Click Finish to complete the importing of legacy code into AppCOE You have successfully imported the legacy code and a project with your given project name is created in the current workspace MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Method 3 Manually Porting Legacy Applications using Import Feature Step 1 In your source c
195. puSoft AppCOE _ 32 mingw bin gdb exe 11 11 13 6 39 PM New Thread 948 xe2c New Thread 948 0xeb8 New Thread 948 0x988 New Thread 948 0x474 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 7 You have now successfully finished debugging by using external console or terminal as shown in Figure 4_38 Figure 4_38 Debugging in Progress 2 Debug demo cross os source os library init c Application Common Operating Environment AppCOE File Edit Source Refactor gate Search Project Run Window Help rii el wb e 0 Q 5 32 9 ES Projects O Profiler 35 Debug 09 Variables amp 99 Breakpoints oio Registers E Modules demo cross os exe AppCOE Local C C Application t xt 4 Q AppCOE Supplied GDB 11 11 13 8 41 PM p Thread 1 Running p Thread 2 Running 9 Thread 3 R x x read EL Running r cat CAMapuSoftAppCOE x32Workspacedemo ros S eJ p G MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 8 41 PM OS_DEBUG The affinity of XOSDEMO is being manai C MapuSoft AppCOE_x32 workspace d ADebug d Task Iterations 1 ba Maps PP 2 SFE NIE MOLTO Dena TOemo cros aren OS DEBUG The affinity of Proc_ is being manag 4 m D 4 Nalue read from Queue_ 12345678 lUalue read f Pipe_ ABCDEFGH A _os_init_windows_host c os_main c 8 os library init c Z3 kask 2 Itoratione 1 Application Start Nalue read from Queue_ 87654321 a P Ualue read from
196. r given project name is created in the current workspace MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Building OS Abstractor Interface Library Before using OS Abstractor Interface make sure the OS and tools are configured correctly for your target To ensure this compile link and execute a native sample demo application that is provided by the OS vendor on your target Refer to the OS vendor provided documentation on how to compile link download and debug the demo applications for your specific target and toolset After this step you are ready to use the OS Abstractor Interface library to develop your applications Building OS Abstractor Interface Demo Application The demo application is located at the mapusoft demo_cross_os directory location From this location you will find the make files or project files at the appropriate specific OS tool target directory For instance if you need the demo application to be built for Windows OS using visual studio 12 tools and for x86 target then the make file location will be at specific windows x86 vsnet2012 directory OS Changer VxWorks Interface The OS Changer Nucleus Interface library contains the following modules Table 5_1 VxWorks Interface Header File Module Description vxworks interface h This header file is required in all of the VxWorks source modules This header file provides the translation layer between the VxWorks defines AP
197. r Ada Listings tab Field Description Your Action Source Listing Specifies how you want the Ada source list to be generated or not You can do any one of the following e To not to generate Ada source list select the radio button To do Ada source list only if errors are present select the radio button Note By default this is enabled To always produce Ada source list select the radio button Source Listing Format Pagination Specifies the format of the Source Listing You can do any one of the following e For continuous source select the radio button Note By default this is enabled e For listing only of lines with errors or warnings select the radio button For paginated source listing select the radio button listing Page Length Specifies the length of the page Enter a value for the length of the page Note By default the value is 66 Page Width Specifies the width of the page Enter a value for the width of the page Note By default the value is 80 Listing only of lines with errors or warnings Specifies if you want to list only lines with errors or warnings Select the check box Cross Reference Listing Specifies if you want to generate a cross reference listing or not You can do any one of the following e To not to generate a cross reference listing select the radio button Note By default
198. r a value to specify the limit on number of error messages Note By default the value is 999 Warning Messages Specifies if you want to select warning messages You can do any one of the following e To select warning messages select the check box Note By default this is enabled To show warnings in with ed files select the check box Info Messages Specifies if you want to select the info messages You can do any one of the following e To select info messages select the check box e To show information in with ed files select the check box Message Format Specifies the format of the message You can do any one of the following e To show given error message only once select the radio button Note By default this is enabled e To show message on each line it applies select the radio button MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 10 On Ada Drivers tab set your driver options as shown in Figure 9_9 Figure 9 9 Ada Drivers Tab 9 Ada C Changer Wizard Configuration options Set your configurations for Ada C C Changer tool C C output Ada listings Ada messages Ada drivers Additional Mode Verbose Q Normal Quiet The field descriptions for Ada driver options tab are as follows Table 9 5 Field Descriptions for Ada Drivers Options tab Field Description Your Action Mode Specifies the
199. r debugging Confirm Perspective Switch window is to confirm the Debug Perspective support for debugging the application and it is displayed as shown in Figure 4 26 at a same time windows command prompt is displayed as shown in Figure 4 27 Note if the user used to open the Debug Perspective for debugging the application by click Yes button then debugging progress is started as shown in Figure 4 28 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_26 Confirm Perspective Switch window Confirm Perspective Switch eS This kind of launch is configured to open the Debug perspective when it suspends This Debug perspective is designed to support application debugging It incorporates views for displaying the debug stack variables and breakpoint management Do you want to open this perspective now Remember my decision Projects Application Common Operating Environment AppCOE R o Search Project Tools Run OOR BO Y Fig C C Projects 22 J NW demo ada to c a demo cross os C demo_nucleus L Confirm Perspective Switch pd C demo_posix C demo_psos o This kind of launch is configured to open the Debug perspective when it suspends C Hemocthreads This Debug perspective is designed to support application debugging It E demo uitron incorporates views for displaying the debug stack variables and breakpoint CD demo vxworks management D demo windows C sample Do you want to open this pe
200. r proprietary OS you could add your own define for your OS and include the MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Flag and Purpose Available Options appropriate OS interface files within os_target h file MapuSoft can also add custom support and validate the OS Abstraction solution for your proprietary OS platform Running AppCOE Generated Code on your Target NOTE This feature requires a license and documentation Click http mapusoft com contact to send a request to receive licenses and documentation After Generating Optimized Target Code for your target OS using the AppCOE Optimized Target Code Generator 1 Using a cross compiler compile link and download the AppCOE generated code to your target 2 Port low level drivers and hardware interrupt code as required refer to OS Abstractor Interface I O and device driver APIs sections in the reference manual Resolve any run time errors MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 7 App Platform Profiler AppCOE provides the Profiler to collect performance data concerning your application and the platform You can graphically view the data with charts and graphs to find bottlenecks system wide or for a specific task It enables you to generate API timing report and also doa comparison for two timing reports This chapter contains the following topics About App Platform
201. rd function select the name in the macro function column and click the lt lt arrow Standard Function Macro Function OS Application Init OS Fatal Error OS Application Wait For End kernellnit semBCreate msgQCreate taskldSelf taskSpawn printf semGive taskSuspend taskDelay creat OS Driver Install remove Cancel Need for Code Optimization Macro function is used to eliminate the time overhead when a function is called It is typically used for functions that execute frequently It also has a space benefit for very small functions and is an enabling transformation for other optimizations Without macro functions however the compiler decides which functions to inline The programmer has little or no control over which functions are macro functions and which are not Giving this degree of control to the programmer allows her him to use application specific knowledge in choosing which functions to macro MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on API Optimization tab are as follows Table 6_5 Field descriptions on API Optimization tab Field Description Your Action Generate Full API Library Interface Specifies if you want to generate full API library package Note You can do this if you have a valid license for standalone generation Select the radio button to generate full library package Note If you select this option the r
202. red memory region size NOTE value is Bytes Default 1024 Maximum Tiered Memory Pool Control Blocks Specifies the total number of Tiered Memory Pools required by the application Enter the maximum number of Tiered Memory variable pools NOTE Default value is 100 Maximum Tiered Shared Memory Pool Control Blocks Specifies the total number of Tiered Shared Memory Pools required by the application Enter the maximum number of Tiered Shared Memory variable pools NOTE Default value is 100 MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 13 On Other Resources configuration tab configure the options to your specifications as shown in Figure 6_19 Figure 6_19 Other Resources Tab lo a Optimized Target Code Generator This wizard optimizes target specific source code Task Process Memory Other Resources Debug Output Devices ANSI Mapping Device I O Interface Maximum Pipe Control Blocks Loo Maximum Queue Control Blocks 100 Maximum Mutex Control Blocks 100 Maximum Semaphore Control Blocks 100 Maximum Event Group Control Blocks 100 Maximum Timer Control Blocks 100 Maximum Protection Control Blocks 100 Maximum Protection System Handles 100 MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Other Resources tab are as follows Table 6_9 Field descriptions on
203. reference to your project Here we are considering importing a application project for example purpose Select the root directory from where you want to import the legacy code by clicking on Browse button next to the text box and click Next as shown in Figure 5 26 On Select Host Library Configuration window select OS Abstractor Process Mode if the imported application runs in multiple process Figure 5 26 Import micro ITRON Legacy Code Window amp Import Import micro ITRON Legacy Code Select a Directory to Import micro ITRON Legacy Code into AppCOE Import Application Project Import Library Project Root Directory E Examples LegacyDemos Legacy Uitron App Project Name uitron_legacy Root Task Prototype VOID uITRONRoct UNSIGNED argv Root Task Stack Size in bytes OS MIN STACK SIZE Host Library Configuration OS Abstractor Process Mode Enabled a Gon Enter the project name for which you want to import the legacy code in the Project Name text box Enter the root task prototype as a VOID uITRONRoot UNSIGNED argv next to Root Task Prototype text box as shown in Figure 5_27 Enter the root task stack size next to the Root Task Stack Size text box as shown The value should be in bytes MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Click Finish to complete the importing of legacy code into AppCOE You can see micro ITRON legacy code you have imported as shown in Figure 5_27 Figure
204. rofiler Application Common Operating Environment AppCOE File Edit Navigate Search Project Run Window Help Ci la BANDE qE Load Profiler Data File Ej Projects Profiler pl Generate Report Profiler Data Explorer 3 B Generate Comparison Report 4 profiler data 1210343810 9 System A rf es 280000 240000 200000 p 160000 120000 80000 e B c o o L 0 o c c z E o E E 40000 o Instances of OS Get Current Task Id called by Task 2 Thr 4 E Properties 25 i Property MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 3 A Save As window is displayed Select the directory where you want to save the report and enter a file name for the report and click Save as shown in 4 Figure 7_14 NOTE In Windows Vista and Windows 7 Windows 8 you cannot generate the profiler report on c if UAC is turned on To turn off UAC refer to the Turning Off UAC You can generate the Timing report to generate in any sub folder inside C drive For Ex C pal_report rtf Figure 7_14 Saving the Timing Report Save in Se Local Disk C Standalone generation CO Config Msi IOD Adobe Suitecs3 WIndows IOD workspace eciipse3 3 1 1 IC VersalSoft i checkout Target CMapusSoft IO nucleus legacy code ICI RoboHelp Documents and Settings MSOCache Program Files IC MnGw soues eC Dtargett File name Save as type 5 Your Timing Report is successfully
205. rspective now 3 CAMapuSoft AppCOE 32 workspace aE Remember my decision 5 onsole 23 E Properties Ex amp B GES Ele Be r3 7 8 AppCOE Local C C Application C MapuSoft AppCOE_ 32 mingw bin gdb exe 11 11 13 6 36 PM s from C MapuSoft AppCOE_x32 workspace demo_cross_os Debug demo_cross_os exe done uch file or directory 0x7bc 4 demo cross os MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 4_28 Debugging Progress Information Progress Information o Launching demo cross os exe Cancel Debugging stops at the main function Click Resume icon highlighted in red circle to resume the debugging process as shown in Figure 4 29 Figure 4 29 Resume Debugging process Edit Source Refactor Navigate Search Project Run Window Help 5 2 2 lt P RR OvrQa S v v EY Projects Profiler Debug v F 69 Variables 23 99 Breakpoints 0 Registers E Modules AppCOE Supplied GDB 11 11 13 6 39 PM Suspended Value 1 4 a Thread 1 Suspended Breakpoint hit 1main os init windows host c 85 0x00402f23 0x011b2d00 ri C MapuSoft AppCOE_x32 mingw bin gdb exe 11 11 13 6 39 PM bal C MapuSoft AppCOE_ 32 workspace demo_cross_os Debug demo_cross_os exi 4 os init windows host c 23 a Outline 25 if OS_TARGET OS WINDOWS amp amp OS HOST OS TRUE 1 Rw eX os_application
206. s 4 m E Properties 23 Property Value Average Function execution time 3 243 023 384 Nano Seconds Instance with the longest total execution time OS Get Events Instance with the shortest total execution time OS Get Event Group Id Number of functions used by this thread 7 Thread ID Task 1 Tasks These are functions called for each task If you expand the Task tab you have the following as already discussed under the Functions tab e Platform APIs e Application Functions MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Viewing App Platform Profiler Data NOTE This feature requires a license Click http mapusoft com downloads AppCOE evaluation to request an evaluation license 1 Open the App Platform Profiler perspective From the AppCOE main menu select Tools gt Load Profiler Data File as shown in Figure 7_10 Figure 7_10 Viewing AppCOE Profiler Data Wolter A m Conn Opcaing Enisonmenl O file Edit Nevigete Seach Project Bun Ico Window Help Bie gt BAB QP toad Profiter Date hie fj Projects 12 Profiler Bd Generate Report Profiler Data Explorer 5 B Generate Companson Report Ds ool EA 4 profiler data 1210343810 system Functions 4 Threads c p Task 4 Task 5 amp Task 6 amp Task 7 na gt 4 Function Iterations 08 Ow Queue ic OB Sei Everts OB Send To Queue E E 3 7 H i E og S 8 g o MAPUS ZfFT APPLICATION C
207. s comments files structures and variable names to ease ongoing code maintenance Creating Ada C C Changer Projects Note This feature requires a license Click www mapusoft com downloads to request for an evaluation license Creating Ada C Changer project Ada C Changer converts Ada 83 or Ada 95 Programs to C Source Code and keeps the C Source Code in Projects 1 From AppCOE main window select any project under C C Projects tab on the left pane 2 Select New gt Ada C Changer Project as shown in Figure 8_1 Figure 8_1 Ada C Changer project Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help R BO 35 07 57 tiv s E Projects Profiler Gq C C Projects Ii demo ada to c E demo cross os E demo nucleus C demo_posix C demo_psos C demo threadx C demo uitron C demo vxworks C demo windows e Sample AppCOE Project W sudoku MAPUS ZfFT do ACRE ImmRREn s Import e Export Resource Configurations 1 Problems El Console 2 5 Properties CDT Build Console NewAdaC 71 Le AppCOE C Project AppCOE C Project Ada C Changer Project Ada C Changer Project New Ada C Project New Ada C Project Project Source Folder Folder Source File Header File File from Template Class Example Other Ctrl N f APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL
208. s exe AppCOE Local C C Application 4 e AppCOE Supplied GDB 11 11 13 8 10 PM Suspended 4 a Thread 1 Suspended Breakpoint hit Z1 main os init windows host c 85 0x00402f23 ba C MapuSoft AppCOE_932 mingw bin gdb exe 11 11 13 8 10 PM P C MapuSoft AppCOE_ 32 workspace demo_cross_os Debug demo_cross_os exe 11 11 13 8 10 PM Figure 4_33 Resume Debugging process Projects demo cross os source os init windows host c Application Common Operating Environment AppCOE e ae Jg avigate S h Project Tools Run o0 E Projects Profiler Fig C C Projects 23 Ei 6 _os init_windows_host c 53 v if OS_TARGET OS WINDOWS amp amp OS HOST OS TRUE AB demo ada to c C demo_cross_os CD demo nucleus oO demo_posix m OS DEBUG The affinity of XOSDEMO being managed by C demo_psos 0 tig Iterations 1 ation 1 CD demo _threadx E affinity of Proc_ is being managed by t SCRIPTION M G 12345678 CO demo_uitron i ABCDEFGH C demo_vxworks s f 87654321 EE demo windows HGFEDCBA Walue read from Queue_ 12345678 Value read from Pipe_ ABCDEFGH i 3 2 2 iam crat from Queue_ 87654321 int main int argc LPSTR arg W from Pipe_ HGFEDCBA iT 4 Sen Os rom Queue_ 12345678 Walue read from Pipe ABCDEFGH return 0S_SUCCESS Task 2 Iterations 5 Value read from Queue 87654321 ESGESEREREBEERERERH Y endif Problems E Console 23 E Properties 35 De
209. s the use of any MT Software made available by Mapusoft Technologies Inc that is not otherwise subject to a separate physically signed license agreement between Licensee and Mapusoft Technologies Inc The term MT Software means computer software and may include associated media printed materials and documentation RIGHTS IN THE SOFTWARE PRODUCT ARE OFFERED ONLY ON THE CONDITIOM 1accept the terms of the license agreement O1 do not accept the terms of the license agreement During the Updating Software Window you can view the new plug ins being downloaded as shown in Figure 2 8 Figure 2 8 Remote Updates Download Projects Application Common Operating Environment AppCOE Je p lt Ed Projects 2 Profiler Fic C C Projects 23 2m IAB demo ada to c a C demo cross os a C demo nudeus C demo_posix a C demo_psos C demo_threadx a C demo_uitron a C demo_vxworks a C demo windows Updating Software j iens Software Downloading mapusoft appcoe target Always run in background Run in Background Cancel Details gt gt Problems EJ console 53 E Properties No consoles to display at this time Updating Software 23 APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 7 Security Warning in between the Installation as shown in Figure 2_9 Figure 2_9 Security Warning Security Warning Warning You are installing software that contains
210. sages Messages and displays generated by adaopts are written to standard error Source Registration Tool adareg Overview The source registration tool adareg maintains the UNIT MAP file The UNIT MAP file which is located in the project directory contains the unit to source correlation of all source files that have been registered in the program library The source registration tool is used to register additional source files in the program library The source registration tool provides the following function e Explicit registration of a specified source file s Registration is performed by doing a syntax analysis of a source file to determine the name and kind of the units in the file and then adding that information to the UNIT MAP When the source registration tool is invoked with a list of source files or directories containing source files registration is performed on all files specified on the command line When the source registration tool is invoked with a directory name it registers all files with the following extensions a ada adb ads bdy dat spc sub This is stored in your newly created Ada C C Changer project Conflicts during Registration The following restrictions apply to source file registration e Two source files with the same simple file name exclusive of the directory path cannot be simultaneously registered Two source files containing the same library unit cannot be simultaneously registered
211. sor Select this if your target supports SMP or UP Kernel Mode If applicable to the Target OS name and version this specifies the following modes e User mode e Kernel mode Select the Target kernel mode by selecting it from the drop down list Architectu re This specifies the architecture of the Target OS The options are e 32 bit e 64 bit Select the architecture you need Target Hardware Specifies the type of target hardware used to complete code optimization Note You can select the target hardware only when you select VxWorks as your target OS Select the type of target hardware used The options are PPC PPC_604 X86 AR M M68K MCORE MIP S SH SIMLINUX SIMN T SIMSOLARIS SPARC Load Settings This specifies the following two options to load settings from e Previous If you select Previous then initial values for this wizard are loaded from previously saved settings and populated Default If you select Default then the values from default settings are populated Select the option to load settings from by selecting from the drop down list Generate a Project File Specifies if you want to generate a project file Select the check box next to Generate project file Project Specifies the different target project types that you can generate for this project The generated project files are directly imported into the specified IDE Eclipse Visual Studio
212. stalled new feature updates to your AppCOE using the Remote Update Site MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Figure 2_21 Restart AppCOE Software Updates You will need to restart Application Common Operating Environment AppCOE For the changes to take effect Would you like to restart now 11 Check the new features installed correctly from the AppCOE installed directory gt plugins as shown Figure 2 22 Figure 2_22 Confirmation of new features installed amp plugins f Jm File Edit View Favorites Tools Help ay Qo Back P B Na Search E Folders z B Folder Sync Address CAMapuSoft AppCOE 82 plugins He Name a Size File and Folder Tasks mi Rename this file gy Move this file A Copy this file e Publish this File to the Web G E mail this file XK Delete this file Other Places Ej APPCOE Winx32 Final iL My Documents Shared Documents Y My Computer 3 My Network Places Details mapusoft appcoe target Executable Jar File Date Modified Today November 08 2013 5 30 a mapusoft appcoe ada_1 3 9 jar B mapusoft appcoe core 1 3 9 jar a mapusoft appcoe generation_1 3 9 jar Aj mapusoft appcoe license_1 3 9 jar mapusoft appcoe profiler 1 3 9 jar al mapusoft appcoe startup 3 9 jar mapuso get_ ja mapusoft appcoe target 1 3 9 jar a net sourceforge Ipg Ipgjavaruntime 1 1 0 v201004271650 jar a org apache batik bridge_1 6 0 20
213. ster and enter the required details After furnishing all your details click Submit Submitting a Ticket 1 To submit a ticket 1 From http www mapusoft com main page select Support gt Submit a Ticket 2 Select a department according to your problem and click Next 3 Fillin your details and provide detailed information of your problem 4 Click Submit MapuSoft Support personnel will get back to you within 48 hours with a valid response 2 To submit a ticket from AppCOE From AppCOE main menu Select Help Create a Support Ticket as shown in Figure 1 1 Figure 1 1 Create a Support Ticket from AppCOE MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL f Praia G commie Propertus Ada Changer Duk Coresi demo ada to c 1 Using the Existing Email and Password for login into Mapusoft Support Suite 2 Select the department according to your problem and click Next 3 Fill in your details and provide detailed information of your problem 4 Click Submit MapuSoft Support personnel will get back to you within 48 hours with a valid response Live Support Offline MapuSoft Technologies also provides technical support through Live Support offline To contact live support offline 1 From http www mapusoft com main page select Support gt Live Support Offline 2 Enter your personal details in the required fields Enter a message about your technical query One of our support personnel will ge
214. systems supported can be found here http mapusoft com products This chapter includes the following topics e List of Available OS Simulators e Host Development Environment e Creating an AppCOE C C Project C Project Template Files HOST Defines Adding Source Code Files to AppCOE C C Project Building Binary Files for a Project Executing Binary Files Debugging the Demos Supplied by MapuSoft Debugging Using External Console Terminal Inserting Application Code to Run only on Host Environment Inserting Application Code to Run only on Specific Target OS Environment Updating Project Settings For more information on the host development refer to OS Simulator MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL OS Changer Porting kit The OS Changer family of products is COTS porting tools that give users the freedom to change operating systems while reusing their existing embedded code and knowledge base to protect their software investment and avoid costly porting issues OS Changer also allows developers to write code using a familiar application programming interface API and run the application on a wide variety of supported target OS platforms Solutions are available for porting from VxWorks pSOS Windows and Nucleus to many different real time RTOS and non real time operating systems Target operating systems supported can be found here http mapusoft com products OS Changer is designed for use as a
215. t back to you as soon as possible 3 Click Send You can reach us at our toll free number 1 877 627 8763 for any urgent assistance Documentation Feedback Send Feedback on Documentation http www mapusoft com support index php MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Chapter 2 Introduction to AppCOE This chapter contains the following topics About AppCOE Installing AppCOE Uninstalling AppCOE Supported Host Platforms Getting a License for AppCOE Installing License for AppCOE Updating APPCOE MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL About AppCOE AppCOE is an Eclipse based IDE AppCOE integrates software interoperability amp reuse tools like OS Changer and OS Abstractor with Eclipse s CDT to offer an IDE for developing and porting embedded applications on many host target platforms With AppCOE you can perform the following actions Creation of C and C AppCOE projects Porting of legacy applications Host development with simulation for many OS applications Converting Ada source code to C C code Platform and Application profiling Automatic configuration of any OS Changer and OS Abstractor APIs needed by the application Custom configuration of OS amp OS Abstractor resources needed by the application Custom configuration of OS Abstractor for single or multi application development Process Feature support Optimized source code generat
216. t in os init mqx c For Linux target insert in os init linux c For Nucleus target insert in os init nucleus c For QNX target insert in os init qnx c For Solaris target insert in os init solaris c For Threadx target insertin os init threadx c For uITRON target insert in os init uitron c For VxWorks target insert in os init vxworks c For Android target insert in os init android c For uCOS target insert in os init ucos c For NetBSD target insert in os init netbsd c MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Host System Configuration The below defines are the system settings used by the OS_Application_Init function Use these to modify the settings when running on the host A value of 1 for any of these will use the default values located in cross_os_usr h When you optimize for the target side code the wizard will create a custom cross_os_usr h using the settings you specify at that time so these defines will no longer be necessary define HOST_DEBUG_INFO 1 define HOST_TASK_POOL_TIMESLICE 1 define HOST TASK POOL TIMEOUT 1 define HOST ROOT PROCESS PREEMPT 1 define HOST ROOT PROCESS PRIORITY 1 define HOST ROOT PROCESS STACK SIZE 1 define HOST ROOT PROCESS HEAP SIZE 1 define HOST ROOT PROCESS AFFINITY 1 define HOST DEFAULT TIMESLICE 1 define HOST MAX TASKS 1 define HOST MAX TIMERS 1 define HOST MAX MUTEXES 1 define HOST MAX PIPES 1 define HOST MAX PROCESSES 1 define HOST MAX
217. tance with the longest execution time 1 Task_3 Instance with the shortest execution time 1 Task_3 Total number of times Application Function was ci 1 MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Threads Threads are created to execute any function in an application IN App Platform Profiler you can view the Thread properties by expanding the Thread tab as shown in Figure 7_9 On the bottom of the window the thread properties are displayed as shown in Figure 7_9 such as e Average Function execution time e Instance with the longest total execution time e Instance with the shortest total execution time e Number of Functions used by this thread e Thread ID Figure 7 9 App Platform Profiler Threads Profiler demo cross o File Edit Source Refactor Navigate Search Project Run Tools Window Help ri amp BRB aiee TE E Debug 2 Projects Profiler Profiler Data Explorer 3 El Profiler View 23 4 profiler data 1210343810 o System 4 Functions Platform APIs Q Application Functions 4 Threads Task 1 amp Task 2 4 0 Task 3 Platform APIs Q Application Functions Task 4 Q Task 5 Task 6 Task 7 o I gt N Function Iterations o p ip Id OS Protect OS_Unprotect OS Get Events OS Create Task OS Get Current Task Id OS Get Event Grouj a A o g S gt 2 E A s o o Function
218. tart c ge Vxworks demo port os_entry c A windDemoOrginal c 6 windDemoPorted c Filter Types Select All Deselect All Into folder sample Options Overwrite existing resources without warning Create top level folder lt lt Advanced C Create links in workspace Create virtual folders Create link locations relative to PROJECT LOC Back Nex Cancel MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL You can view the source code files added to your AppCOE C C project as shown in Figure 4_20 Figure 4_20 Importing Source Code Files Output Projects sample os entry c Application Common Operating Environment AppCOE Edit Source Refactor Navigate Search Project Tools Run Window Help ORBO 077 eP E3 O Projects 2 Profiler 5 Debug Fie C C Projects 23 os_entry c 23 im e Copyright c 2013 MapuSoft Technologies Inc D Ww demo ada to c e demo cross os C demo_nucleus C demo_posix C demo_psos e demo threadx e demo uitron oO demo_vxworks LE demo windows DESCRIPTION a C sample i Includ gt This tasks exercises various kernel functions W Includes include os target h include FUNCTION Task Entry include amp source n demo h 8 init c os application start c try c id windDemoOrginal c windDemoPorted c AUTHOR VOID Task 0 Entry UNSIGNED arg
219. te Timing Comparison Report Current PAL File J profiler data 20131112116 J System J Functions 4 Platform APIs v OS Create Task OS Get Current Task Id OS Aquire Protection OS Release Protection OS Get Current Process Id OS Create Semaphore OS Get Events OS Create Pipe OS Create Queue OS Create Event Group INT OS Get Semaphore Id INT OS Get Queue Id INT OS Get Pipe Id OS Take Semaphore OS Send To Queue OS Send To Pipe INT OS Get Event Group Jd OS Receive From Queue INT OS Get Task Id OS Create Timer OS Sleep Task OS Receive From Pipe J amp S S S S S S S S S S S S S ST S S S S S emen MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 4 Save As window will be displayed Select the directory where you want to save the report Enter a file name for the report and click Save as shown in Figure 7_18 Figure 7_18 Saving Timing Comparison Report Gor Organize v New folder Name Ta Libraries Documents 2 Music 3J New Library b Pictures amp j Subversion E Videos j Computer 4 New Volume C xi New Volume D f File name timing_comparision_report Save as type rtf 6 Your Timing Comparison Report is successfully generated as an rtf file extension as shown in Figure 7 19 Figure 7 19 Generated Timing Comparison Report QUO gt Computer New Volume C profileData Organize v Incudei
220. th the lc le lp or lr option the lf option causes the compiler to write the listing to filename instead of the default file lst lp The lp option causes the compiler to generate a line numbered listing with pagination and a header at the top of each page The page is 60 lines long and 80 columns wide Any errors or other compiler generated messages are interspersed in the listing which includes all messages generated by the compiler The listing is written to file lst The lr option causes the compiler to generate a listing containing only those lines for which compiler messages were generated as well as the compiler messages The listing is written to file lst The Ix option causes the compiler to generate a cross reference listing This cross reference listing is a line numbered listing followed by a cross reference table This listing is written to file xlst A binary cross reference file file ref will also be generated pl length This sets the page length for the paginated source MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Listing Options Description listing to length lines This option has no effect unless used in conjunction with the lp option pw width This sets the page width for the paginated source listing to width columns This option has no effect unless used in conjunction with the lp option nh No headers in listings
221. than where they were installed To force Momentics to update these paths e Right click on the project and select Properties from the context menu Then click Apply and close the properties window NOTE 5 To generate optimized target code on Windows Interface ensure that the flag INCLUDE_OS_PROCESS is set to OS_TRUE in the cross_os_usr h configuration file MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL To generate Optimized Target Code From AppCOE C C projects select a project From AppCOE main menu click Tools gt Optimize Target Code Generator or click the Optimized Target Code Generator button on the AppCOE Toolbar as shown in Figure 6_9 Figure 6_9 AppCOE Target Code Generator Projects demo_cross_os source _os_init_windows_host c Application Common Operating Environment 00 File Edit Source Refactor Navigate Search Run Project Tools Window Help riv t Ww mo 3i G Optimized Target Code Generator Ed Debug Projects Profiler BA C C Projects 13 e C demo_cross_os ed demo nucleus D demo posix D demo psos C demo_uitron D demo_vxworks D demo windows C Sample AppCOE Project Sample AppCOE Project MAPUS fFT lag Update Settings El 6 applicatio License Full Library Package Generator inclu sif 0 Ada C C Changer ST OS TRUE OS Application Start DESCRIPTION These are the various entry f
222. the Ada lines of code with a simple program It just takes a list of file names and prints out the number of lines of Ada source code lines of comments and blank lines counting lines of code the same way the license checker counts them The application name is ada_line_count exe You have to run this exe in cmd prompt Command ada line count file1 file2 file3 POSIX ADA Support For Linux only Ada C C Changer toolsnow give support to POSIX You have a separate library with POSIX Ada packages for Linux only To make this linked library available to a given user the adaopts command Command adaopts p usr local AppCOE Tools Ada linux posix ada will link the posix ada library into the search path for the current library Ada Support for GNAT compatibility compiler This feature enables you to link the gnat compatibility library into the search path for the current library The following commands are used to link Linux Command adaopts p usr local AppCOE Tools Ada linux gnat compat Windows Command adaopts p C Mapusoft AppCOE Tools Ada windows gnat_compat Ada Support for Win32 This feature enables support for Ada on Win32 host The following command is used for the win32ada library Windows Command adaopts p C Mapusoft AppCOE Tools Ada windows win32ada For Ada C C Changer project from Properties page if you change Ada Main procedure it will not build the project with that procedure imm
223. this is enabled To generate a cross reference listing select the radio button MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 9 On Ada Messages tab set your message options as shown in Figure 9_8 Figure 9 8 Ada Messages Tab 2 Ada C Changer Wizard E jm gt TEn Configuration options A Set your configurations for Ada C C Changer tool C C output Ada listings Ada messages Ada drivers Additional Error messages v Error messages Show errors in with ed files Limit on number of error messages 999 Warning messages v Warning messages I Show warnings in with ed files Info messages _ Info messages F Show infos in with ed files Message format Show given error message only once Q Show message on each line it applies MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Ada Messages tab are as follows Table 9_4 Field Descriptions for Ada Messages tab Field Description Your Action Error Messages Specifies if you want to select error messages You can do any one of the following e To select error messages select the check box Note By default this is enabled To show error sin with ed files select the check box Limit on number of error messages Specifies the count of error messages Ente
224. time click OK If you are comparing the same two files for the second time click Cancel as shown in Figure 7_16 Figure 7_16 Import PAL File Import PAL File Select the directory containing your PAL file Select PAL File C profileData profiler_data_20131112116 pal Report for Differential data All Data 2 Fresh Categorization Categorized Data Already Available For File Named profiler data 20131112116 Do You Want To Categorize Again as MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions for importing the PAL file are described as follows Table 7_1 Field descriptions for importing the PAL file Field Description Your Action Select PAL File Specifies you to To select the PAL file click Browse select the PAL file and select it from your system for which the Timing Comparison Report has to be generated Report for Specifies what you You can do any one of the following are comparing and click Next e To compare only the differences select the radio button before Differential Data Note By default this feature is disabled To compare all the data in the PAL files select the radio button before All Data Note By default this feature is disabled Select the APIs you want to generate the Timing Comparison Report as shown in Figure 7_17 click Finish Figure 7_17 Selecting the APIs e Comparison Report Genera
225. tool chain that is installed recently The Update button performs an auto update on all the projects updates which include files new directory structures libraries and tool chains to the Project Settings To update project settings 1 From AppCOE main menu select Tools gt Update Settings or click AppCOE C C Project Settings button on AppCOE main menu or as shown in Figure 4_39 Figure 4_39 Updating Project Settings T demo ros oi ORT TRS GRE RSEN Common Ozinga 55 file Edit Source Mefacter PMavigate Segrch Bun Project ooh Window Hele Orno 9 0 Q Sy 3 Debug I3 Preci O Pretites UEan Projects i v i Probiems Console Properties 39 Debug C Build Sample AppCOE Project MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 2 AppCOE does an auto search for the project updates and updates the settings as shown in the Project Settings Updating window in Figure 4_40 si Windas els aure factor Newgate Search Rum Propect t OQONXM 5 M Q Q AF f O Debug I3 Prefect Protter f CC Projects 3 Cc demo co55 05 D emo nuceus Cc demo poss demo psor demo uitron demo vweons demo windows 4 e Sample AppCOE Proyect a Bn gt Sample AppCOE Project ace a Includes VD wctude A source 5 Detug fandit Ih Problems Console 1 Properbes T Debug C Bald Sample AppCOE Project css os lwinsnm Sample AppCOK Project Sample AppCOE
226. ubdirectory you will get an error while creating a project MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL ADA C C Changer Configuration Options On the Ada C C Changer Configuration Options page you can set the following configurations e C C Output e Ada Listings e Ada Messages e Ada Drivers e Additional NOTE 1 You can change the configuration options on the Ada C C Changer Property Page To go to the Ada C C Changer Property Page right click on the project and select Properties gt Ada Changer Ada Changer Options Configurations File Ada Changer options are configurable via an Option s file amp b c Once you have an Ada Changer project and you want to use the same options that you have used Browse to the workspace directory location and into your project name directory You will find a file called options file and you can save that file in a different location you can also rename it if you want and use it again and again You can create new Ada Changer projects by passing the file info in the first screen Ada Changer reads this info and sets up the GUI configuration values accordingly This way you can create an option file and use it repeatedly as a template However if you later want to modify these options after creating the project you can select the Ada Changer project and right click and choose Properties and select Ada Changer Configuration page and change This w
227. ude Windows Interface API s MAPUS ZfFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 13 After successfully creating an Ada C C Changer project a report page is displayed as shown in Figure 9_12 Click Done to complete the process The report gives detailed information on the status of different activities in Ada to C source file generation Figure 9 12 Ada C Project Report Page e Ada C Project WizardProject Report Displays status report regarding your Ada Project License Check Status SUCCESS Description License for Ada C Changer is valid Ada C C Changer Status SUCCESS Description For more details see console view 14 You have now successfully created Ada C C Changer project MAPUS FT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL 15 To view the C C code expand the project you have created as shown in the Figure 9 13 Figure 9 13 Output for Ada C C Changer Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help m ia S amp F Oe 6 O a amp v Projects Profiler Projects cC demo utron en demo vxworks C demo wi Ci Sampie AppCOE Projec Ph sudoku s Inciudes 4 ada2CCes gt ndude gt nfo 4 i source alleltabc Sudoku testadb c Sudoku adb c sudokuadsc e wet Problems D Console Properties 4 amp adaRoot e s1 sudoku adb
228. uild time and identifies the list of object modules that make up the program The linking phase invokes the target linker to combine the object modules to form a load module with all references resolved Prelinking The prelinking phase performs three functions e It determines the complete list of units needed for the main procedure e It finds or generates all object modules for the units on this list ensuring that they are up to date e It determines an acceptable elaboration order To perform these functions the prelinker uses the information files generated by the Ada C C Changer These files contain the names of depended upon and needed units For a description of how the information files in the program library are found Finding the information files results in implicit invocations of the compiler for source files or units in the current program library if e The source file containing a needed unit has either never been compiled e Or has been modified since it was last compiled e Ora source file on which a unit depends has been modified since the unit was compiled The program builder uses time stamps to determine if a source file has been modified The prelinking phase handles all of the compilation order and completeness requirements for building the Ada program If a part of the program is missing or if the Ada source code contains incorrect dependencies the prelinking phase will detect and report this Linking The linking p
229. unctions for the t function for int main int argc LPSTR argv 1 OS Main Problems EJ Console 23 E Properties 35 Debug No consoles to display at this time APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL From AppCOE Optimized Target Code Generator window select your target platform specifications from the drop down list VxWorks operating system is selected as an example as shown in Figure 6_10 Figure 6_10 Selected VxWorks Target in this Example On Optimized Target Code Generator This wizard optimizes target specific source code ss Target VxWorks Version 6x SMP UP Kernel Mode Architecture Target Hardware x86 Load settings from Previous _ Generate a Project File Project WindRiver Workbench 3 1 Destination Path c optimizecode MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on AppCOE Optimized Target Code Generator window are as follows Table 6_1 Field descriptions on AppCOE Optimized Target Code Generator Field Description Your Action Target Specifies the target OS name Enter the target OS name in the text box Version Based on the Target OS name you selected this specifies the available version names listed in the Version drop down list Select the appropriate target version SMP This specifies the Symmetric Multi proces
230. urce not found Optimized Target Code Generator Ada C C Changer App Platform Profiler MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Introduction to AppCOE Components With Application Common Operating Environment AppCOE you can easily port abstract and optimize your code on a host machine and run the application on different target platforms AppCOE leverages the existing OS Changer and OS Abstractor technologies while adding advanced code optimization capacities on multiple OS environments AppCOE provides users an easy to use graphical user interface that is integrated with the Eclipse based CDT environment AppCOE uses OS Abstractor and OS Changer technology to produce Cross OS development platform for many targets AppCOE target features include Porting of legacy applications to your new chosen OS OS Changer Porting Kit Development of embedded applications on Host environment OS Simulator Convert Ada source code to C C code Ada C C Changer Application profiling and platform profiling for your APIs App Platform Profiler Generate API Profiling timing report and Profiling Timing comparison report App Platform Profiler Cross OS Development Platform Features that includes o Automatic configuration of any OS Changer and OS Abstractor APIs needed by the application Custom configuration of OS amp OS Abstractor resources needed by the application Custom configuration of OS Abstractor
231. with Real time OS Abstractor Scheduling Select Ada C C Changer build configurations Import Ada Source files to project ADA C C Changer Configuration Options Building Ada C C Changer Projects Target Code Generation for Ada C C Changer Projects Ada C C Changer Property Page ADA C C Changer Additional Information s Additional Ada C C Changer tools MAPUS QJFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL Working with Ada C C Changer Projects Ada C Changer converts Ada 83 or Ada 95 Programs to C Source Code and keeps the C Source Code in Projects From AppCOE main window select any project under C C Projects tab on the left pane Select New gt Ada C Changer Project as shown in Figure 9_1 From AppCOE main window select any project under C C Projects tab on the left pane Figure 9_1 Creating Ada C Changer Project Projects Application Common Operating Environment AppCOE File Edit Source Refactor Navigate Search Project Tools Run Window Help oy 7 WEB Or 0 Qq 5 E Projects Profiler Ga C C Projects 3 Ti demo_ada_to_c C demo cross os C demo nucleus C demo posix C demo psos New C demo threadx C demo uitron C demo vxworks C demo windows Resource Configurations E Sample AppCOE Project TW sudoku AppCOE C Project AppCOE C Project Ada C Changer Project Ada C Changer Project New Ada C Project New Ada C Project Project Imp
232. y Pool Control Blocks 10 Maximum Tiered Shared Memory Pool Control Blocks Minimum Variable Pool Allocation Size in Bytes User Shared Memory Region Size MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Memory tab are as follows Table 6_8 Field descriptions on Memory tab Field Description Your Action Maximum Variable Memory Pool Control Blocks Specifies the total number of dynamic variable memory pools required by the application Enter the maximum number of dynamic variable pools NOTE Default value is 100 Maximum Fixed Memory Pool Control Blocks Specifies the total number of partitioned fixed size memory pools required by the application Enter the maximum number of partitioned memory pools NOTE Default value is 100 Minimum Variable Pool Allocation Size in Bytes Specifies the minimum memory allocated by the malloc and or OS Allocate Memory calls NOTE Increasing this value further reduces memory fragmentation at the cost of more wasted memory Enter the minimum memory allocated NOTE value is 4 Increasing value further reduces memory fragmentation at the cost of more wasted memory Default this User Shared Memory Region Size Specifies the application defined shared memory region usable across all OS Abstractor Interface processes applications Enter the user sha
233. zed Target Code Generator This wizard optimizes target specific source code Task Process Memory Other Resources Debug Output Devices ANSI Mapping Device I O Interface Number of pSOS Interface Task Registers C Go MAPUS fFT APPLICATION COMMON OPERATING ENVIRONMENT USER MANUAL The field descriptions on Interface tab are as follows Table 6_14 Field descriptions on Interface tab Field Description Your Action Number of pSOS Specifies the number of pSOS Interface Task Interface Task Registers Registers Enter the number of pSOS Interface task registers Note Default value is 32 Click Finish The target code will be generated into the destination path you defined in step 5 as shown in Figure 6 25 NOTE If it is not able to generate the target code the system will throw up an error Figure 6 25 Target Code Generation Output E Generator Verification 3 Displays the Information about different activities in Target Code Generation Create Target Directory Status Description Creation of ctmplOptimized code demo nucleus target directory was successful License Check i Status SUCCES Description License is valid License Check Status CES Description License file contains a valid license for VxWorks 6 x Generate OS Abstractor Interface Status Description Generation for OS Abstractor Interface is successful

Download Pdf Manuals

image

Related Search

Related Contents

きりまる 取扱説明書 - 有限会社川村製作所  Nikon FM3A  セットアップガイド  HCD-CL1/CL3  Sony VAIO SVF14A15CX  Cruiser III  Manual de Instalação e Manutenção - Extranet    KTD-405 Keypad User Manual  August 2003 QST Product Reviews and Short Takes  

Copyright © All rights reserved.
Failed to retrieve file