NOTICE: The Processors Wiki will End-of-Life on January 15, 2021. It is recommended to download any files or other content you may need that are hosted on processors.wiki.ti.com. The site is now set to read only.

SitaraWareOnCCSv4

From Texas Instruments Wiki
Jump to: navigation, search

TIBanner.png


IMPORTANT - The content of this page is due to change quite frequently and thus the quality and accuracy are not guaranteed until this message has been removed. For suggestion/recommendation, please send mail to your local FAE.


AM1808 SitaraWare on CCS v4
[edit]

The Sitaraware software package has projects which can be imported on CCS v5 but not on CCS v4. To use SitaraWare on CCS v4 new projects have to be created. This page shows how to create projects in CCS v4 to generate libraries and executable binaries. 

The steps required to create the executable file is not same for all the projects. SitaraWare projects can be classified in to the following categories

  1. Driver lib
  2. Platform and system_config lib
  3. Grlib lib
  4. Usblib lib
  5. Application type1 (example project which includes – drivers, system_config & platform libs)
  6. Application type2 (example project which includes – drivers, system_config, platform and grlib libs)
  7. Application type3 (example project which includes – drivers, system_config, platform, grlib libs and usblib libs)
  8. Application type4 (example project which includes – drivers, system_config & platform libs) with multiple configurations

Note:

  1. To install CCS v4 please follow the steps given here
  2. '->' indicates that the corresponding button is to be clicked. For example 'next->' indicates that the user need to click 'next' button.
  3. This document is written with reference to TMS470 tool version v4.6.4 on CCS v5 and CCS v4.
  4. The images shown is section 1.1 are applicable for sections 1.2, 1.3 and 1.4 with the values given is corresponding sections.
  5. Clean the project before building it.

Creating Driver lib
[edit]

The driver library includes the device abstraction layer(DAL) for all the devices supported in SitaraWare. This lib is required to be included in all the example projects. The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project.

  1. Launch the CCS v4 IDE. File->new->CCS Project
  2. Enter the project name (driver) and the path (<install dir>\drivers\build\cg_ccs4\am1808) where the project files have to be created. Next->                  
  3. Select project type (ARM). Check debug and release configurations. Next->                                         
  4. Additional project settings: Next->
  5. Project settings. Select the values as shown in snap shot below. next->
    Driver proj settings.JPG
  6. Project template. Select Empty project. Finish->                                                                    
  7. Right click Project->link files. Go to <install dir>\drivers\src\ and select all the source files. open->
  8. Right click Project->Build Properties->Tool Settings
  9. Basic Options->select optimization level to 2.
    Driver Optim level.JPG
  10. Include Options->Add the include paths as shown in snap shot.
    Driver Include Opt.JPG
  11. Build Settings->set Artifact name as shown below. Apply->Ok->
    Driver Build Settings.JPG
  12. Dont modify any other options (let them have default values)
  13. Build Project. The compiled driver.lib will be kept at <install dir>\drivers\lib\cg_ccs\am1808

Platform and system_config lib
[edit]

The platform library includes the EVM specific code. The System_config lib includes SOC specific and Compiler specific code. These libs are required to be included in all the example projects. The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project.

  1. Launch the CCS v4 IDE. File->new->CCS Project
  2. Enter the project name (Platform OR System) and the path (<install dir>\platform\evmAM1808\build\cg_ccs4 OR <install dir>\system_config\am1808\build\cg_ccs4) where the project files have to be created. Next->
  3. Select project type (ARM). Check debug and release configurations. Next->
  4. Additional project settings: Next->
  5. Project settings. Select the values as shown below. next->
       Output type -> static library
       Device variant -> <select variant> and Generic ARM9 Device
       Device Endianness -> little
       Code Gen tools -> TI v4.6.4
       Output Format -> eabi (ELF)
  6. Project template. Select Empty project. Finish->
  7. Right click Project->link files. Go to <install dir>\platform\evmAM1808\src\ OR <install dir>\system_config\am1808\src\and select all the source files. open->
  8. Right click Project->Build Properties->Tool Settings
  9. Basic Options->select optimization level to 2.
  10. Include Options->Add the include paths as shown below.
       "../../../../../include/am1808/"
       "../../../../../include/hw"
       "../../../../../include/"
       "../../../../../include/usblib/"
  11. Build Settings->set Artifact name as "../../../lib/cg_ccs/${ProjName}". Apply->Ok->
  12. Dont modify any other options (let them have default values)
  13. Build Project. The compiled platform.lib will be kept at <install dir>\platform\evmAM1808\lib\cg_ccs and the system.lib will be kept at <install dir>\system_config\am1808\lib\cg_ccs

Creating Grlib lib
[edit]

The grib includes the graphics library implementation. This lib is required when the user wants to use the grlib API's. The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project.

  1. Launch the CCS v4 IDE. File->new->CCS Project
  2. Enter the project name (grlib) and the path (<install dir>\grlib\build\cg_ccs4) where the project files have to be created. Next->
  3. Select project type (ARM). Check debug and release configurations. Next->
  4. Additional project settings: Next->
  5. Project settings. Select the values as shown below. next->
       Output type -> static library
       Device variant -> <select variant> and Generic ARM9 Device
       Device Endianness -> little
       Code Gen tools -> TI v4.6.4
       Output Format -> eabi (ELF)
  6. Project template. Select Empty project. Finish->
  7. Right click Project->link files. Go to <install dir>\grlib\ and <install dir>\grlib\fonts\ and select all the source files. open->
  8. Right click Project->Build Properties->Tool Settings
  9. Basic Options->select optimization level to 2.
  10. Include Options->Add the include paths as shown below.
       "../../../../include/am1808"
       "../../../../include/hw"
       "../../../../include/"
       "../../../../grlib"
  11. Build Settings->set Artifact name as ../../../lib/cg_ccs/${ProjName}. Apply->Ok->
  12. Dont modify any other options (let them have default values)
  13. Build Project. The compiled grlib.lib will be kept at <install dir>\grlib\lib\cg_ccs.

Creating USB lib
[edit]

The USB library includes the USB stack. This lib is to be included in the projects where USB stack is used. The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project.

  1. Launch the CCS v4 IDE. File->new->CCS Project
  2. Enter the project name (usblib) and the path (<install dir>\usblib\build\cg_ccs4\) where the project files have to be created. Next->
  3. Select project type (ARM). Check debug and release configurations. Next->
  4. Additional project settings: Next->
  5. Project settings. Select the values as shown below. next->
       Output type -> static library
       Device variant -> <select variant> and Generic ARM9 Device
       Device Endianness -> little
       Code Gen tools -> TI v4.6.4
       Output Format -> eabi (ELF)
  6. Project template. Select Empty project. Finish->
  7. Right click Project->link files. Go to <install dir>\usblib\ and <install dir>\usblib\device and select all the source files. open->
  8. Right click Project->Build Properties->Tool Settings
  9. Basic Options->select optimization level to 2.
  10. Include Options->Add the following include paths.
       "../../../../../include/am1808/"
       "../../../../../include/hw"
       "../../../../../include/"
       "../../../../../include/usblib/"
  11. Build Settings->set Artifact name as ../../../../lib/cg_ccs/am1808/${ProjName}. Apply->Ok->
  12. Dont modify any other options (let them have default values)
  13. Build Project. The compiled platform.lib will be kept at <install dir>\usblib\lib\cg_ccs\am1808.

Creating applications (type1, type2 and type3)
[edit]

The different kind of applications differ basically on the additional library it includes. Accordingly the application examples are classified as below,

Application type1 (example project which includes – drivers, system_config & platform libs)
[edit]

This kind of application projects include drvier, platform and system_config libraries. The application examples which fall under this category are wdt, uart_edma, uart, timer, spi_edma, spi, rtc, raster, mcasp, lidd, i2c_edma, i2c, ehrpwm and gpio.

Application type2 (example project which includes – drivers, system_config, platform and grlib libs)
[edit]

This kind of application projects include drvier, platform, system_config and grlib libraries. The application examples which fall under this category are grlib_demo and game.

Application type3 (example project which includes – drivers, system_config, platform, grlib libs and usblib libs)
[edit]

This kind of application projects include drvier, platform, system_config, grlib and usblib libraries. The application example which fall under this category is demo.


The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project. Please ensure the dependent libraries are build before building the application project.

  1. Launch the CCS v4 IDE. File->new->CCS Project
  2. Enter the project name (game) and the path (<install dir>\examples\evmAM1808\<example>\build\cg_ccs4\) where the project files have to be created. Next->
  3. Select project type (ARM). Check debug and release configurations. Next->
  4. Additional project settings: Next->
  5. Project settings. Select the values as shown below. next->
    Appln new proj.JPG
                                                                                                                                                                           
  6. Project template. Select Empty project. Finish->
  7. Right click Project->link files.Go to <install dir>\examples\evmAM1808\<example>\src and <install dir>\utils\src\ and select all the source files. open->.
    For Application type3: Include <install dir>\third_party\lwip-1.3.2\apps\httpserver_raw_io\httpd_io.c and <install dir>\third_party\lwip-1.3.2\ports\am1808\lwiplib.c. open->
  8. Right click Project->Build Properties->Tool Settings
  9. Basic Options->select optimization level to 2.
  10. Include Options->Add the following include paths.
       For application type1, type2 and type3
          "../../../../../../include/am1808"
          "../../../../../../include/hw"
          "../../../../../../include/"
          "../../../include"
          "../../../src" (for raster example only)
       For Application type2 and type3
          "../../../../../../grlib"
       For Application type3
          "../../../../../../include/usblib/"
          ../../../../../../third_party/lwip-1.3.2/apps/httpserver_raw_io
          ../../../../../../third_party/lwip-1.3.2
          ../../../../../../third_party/lwip-1.3.2/src/include/
          ../../../../../../third_party/lwip-1.3.2/src/include/ipv4
          ../../../../../../third_party/lwip-1.3.2/ports/am1808/include
  11. Build Settings->set Artifact name as ../../../cg_ccs/${ProjName}. Apply->Ok->
  12. Re-use the command file from CCS v5 project. So copy AM1808.cmd from <install dir>\examples\evmAM1808\<example>\build\cg_ccs to <install dir>\examples\evmAM1808\<example>\build\cg_ccs4
  13. Right click Project-> Build Properties->Build steps: set post-build step(command) : tiobj2bin.bat ../../../cg_ccs/${ProjName}.out ../../../cg_ccs/${ProjName}.bin "${TMS470_CG_ROOT}/bin/ofd470.exe" "${TMS470_CG_ROOT}/bin/hex470.exe" mkhex4bin
    Outtobin.JPG Also include the path of tiobj2bin.bat in system environvment path variable.
  14. Dont modify any other options (let them have default values)
  15. Build Project. The compiled and linked <example>.out and <example>.bin will be kept at <install dir>\examples\evmAM1808\<example>\cg_ccs


Creating application type4
[edit]

This type of application needs more than one binary images to demonstrate the capability of the module and this is managed with multiple configurations. For example in the case of cache_mmu the default configuration demonstrates the behaviour of cache when it is NOT flushed. The image created with specific configuration demonstrates the behaviour of cache when it is flushed.

The following steps shows how to create project in CCS v4, the build options to be selected and how to build the project. Please ensure the dependent libraries are build before building the application project.

  1. Follow the steps given in section 1.5 for appication type1 to create the application binary with cache NOT flushed. Follow the below steps to create additional configuration and corresponding executable image.
  2. Right click project -> properties -> C/C++ Build -> manage(configuration) -> New (Manage window)
  3. Enter the configuration name (debug_flush). OK ->
    Add config.JPG
  4. Tool setting -> predefined symbols -> add pre-define NAME (CACHE_FLUSH). Ok ->
    Pre define name.JPG
  5. Build Settings->set Artifact name as ../../../cg_ccs/${ProjName}Flush. Apply->Ok->
  6. Right click Project-> Build Properties->Build steps: set post-build step(command) : tiobj2bin.bat "../../../cg_ccs/${ProjName}Flush.out" "../../../cg_ccs/${ProjName}Flush.bin" "${TMS470_CG_ROOT}/bin/ofd470.exe" "${TMS470_CG_ROOT}/bin/hex470.exe" mkhex4bin
  7. Build Project. The compiled and linked <example>Flush.out and <example>Flush.bin will be kept at <install dir>\examples\evmAM1808\<example>\cg_ccs


AM1808 SitaraWare - Target Configurations and loading
[edit]

For target configurations and debugging instructions (same as CCS v5) please refer here.

E2e.jpg {{
  1. switchcategory:MultiCore=
  • For technical support on MultiCore devices, please post your questions in the C6000 MultiCore Forum
  • For questions related to the BIOS MultiCore SDK (MCSDK), please use the BIOS Forum

Please post only comments related to the article SitaraWareOnCCSv4 here.

Keystone=
  • For technical support on MultiCore devices, please post your questions in the C6000 MultiCore Forum
  • For questions related to the BIOS MultiCore SDK (MCSDK), please use the BIOS Forum

Please post only comments related to the article SitaraWareOnCCSv4 here.

C2000=For technical support on the C2000 please post your questions on The C2000 Forum. Please post only comments about the article SitaraWareOnCCSv4 here. DaVinci=For technical support on DaVincoplease post your questions on The DaVinci Forum. Please post only comments about the article SitaraWareOnCCSv4 here. MSP430=For technical support on MSP430 please post your questions on The MSP430 Forum. Please post only comments about the article SitaraWareOnCCSv4 here. OMAP35x=For technical support on OMAP please post your questions on The OMAP Forum. Please post only comments about the article SitaraWareOnCCSv4 here. OMAPL1=For technical support on OMAP please post your questions on The OMAP Forum. Please post only comments about the article SitaraWareOnCCSv4 here. MAVRK=For technical support on MAVRK please post your questions on The MAVRK Toolbox Forum. Please post only comments about the article SitaraWareOnCCSv4 here. For technical support please post your questions at http://e2e.ti.com. Please post only comments about the article SitaraWareOnCCSv4 here.

}}

Hyperlink blue.png Links

Amplifiers & Linear
Audio
Broadband RF/IF & Digital Radio
Clocks & Timers
Data Converters

DLP & MEMS
High-Reliability
Interface
Logic
Power Management

Processors

Switches & Multiplexers
Temperature Sensors & Control ICs
Wireless Connectivity