File platforms_examples.obscpio of Package Cpputest

0707010000C064000041ED000003E8000000640000000568A04FE700000000000000080000003000000000000000000000001900000000platforms_examples/armcc0707010000C063000081A4000003E8000000640000000168A04FE7000001E5000000080000003000000000000000000000001A00000000platforms_examples/READMEDirectory to place test examples for different toolchains/chips combinations.

Source files from this directory is compiled to executable using CppUTest,
  CppUTestExt and startup libraries from lib directory in CppUTest home.

There is a sample eclipse project in armcc/AT91SAM7A3 folder. It may be used
to see at possibility way of cross development with CppUTest running in
target platform. It is based on Makefile.
Makefile need some Cygwin utility, so you need to install cygwin.
0707010000C065000041ED000003E8000000640000000368A04FE700000000000000080000003000000000000000000000002400000000platforms_examples/armcc/AT91SAM7A30707010000C07E000041ED000003E8000000640000000468A04FE700000000000000080000003000000000000000000000002100000000platforms_examples/armcc/LPC18330707010000C074000041ED000003E8000000640000000368A04FE700000000000000080000003000000000000000000000002100000000platforms_examples/armcc/LPC17680707010000C072000041ED000003E8000000640000000268A04FE700000000000000080000003000000000000000000000002A00000000platforms_examples/armcc/AT91SAM7A3/tests0707010000C071000081A4000003E8000000640000000168A04FE70000006D000000080000003000000000000000000000003200000000platforms_examples/armcc/AT91SAM7A3/jlink_gdb.cmdstart "JLink GDB Server" "C:\Program Files (x86)\SEGGER\JLink_V490b\JLinkGDBServerCL.exe" -device AT91SAM7A3
0707010000C070000081A4000003E8000000640000000168A04FE7000002D7000000080000003000000000000000000000002E00000000platforms_examples/armcc/AT91SAM7A3/STACK.txtSee objs/app/app.htm for details about stack sizes for functions and call tree.

Stack usage for std::cout << (double) is about 1336 bytes

Stack usage for CppUTest is at least 4368 bytes with call chain:
main ->
  CommandLineTestRunner::RunAllTests(int, char**) ->
  CommandLineTestRunner::RunAllTests(int, const char**) ->
  MemoryLeakWarningPlugin::MemoryLeakWarningPlugin(const SimpleString&, MemoryLeakDetector*) ->
  MemoryLeakWarningPlugin::getGlobalDetector() ->
  MemoryLeakDetector::MemoryLeakDetector(MemoryLeakFailure*) ->
  MemoryLeakDetectorTable::MemoryLeakDetectorTable() ->
  __aeabi_vec_ctor_nocookie_nodtor
Maximum stack consumption for constructor MemoryLeakDetector::MemoryLeakDetector(MemoryLeakFailure*)
0707010000C06D000081A4000003E8000000640000000168A04FE7000000EC000000080000003000000000000000000000002C00000000platforms_examples/armcc/AT91SAM7A3/RAM.txtbss memory usage for std::cout is about 12248 bytes

Library cpp_ts(ios.o) needs two big regions of 7472 and 4104 bytes and other
  small regions.

More than 8k needed for statically created arrays with size
  SetPointerPlugin::MAX_SET
0707010000C06B000081A4000003E8000000640000000168A04FE7000000A4000000080000003000000000000000000000002C00000000platforms_examples/armcc/AT91SAM7A3/LICENSENo any additional license is used except standard Keil MDK-ARM license.

If you use Keil MDK-ARM or ARM C/C++ then you agreed with terms of 
Keil MDK-ARM license.

0707010000C06E000081A4000003E8000000640000000168A04FE7000007D4000000080000003000000000000000000000002B00000000platforms_examples/armcc/AT91SAM7A3/READMESample project to test CppUTest for Keil MDK-ARM toolchain and AT91SAM7A3 chip.

Requirements:
1. CYGWIN (rm.exe, mkdir.exe, make.exe)

2. Keil MDK-ARM

3. JLink Flash (for programming chip)

4. serial connection to DBGU interface

5. 4 MHz quartz. If else, need to be adjusted in
  $(CPPUTEST_HOME)/platforms_startup/armcc/AT91SAM7A3/SAM7A3.asm
  (for setup PLL and change core clock from IRC to PLL)
  and
  $(CPPUTEST_HOME)/platforms_startup/armcc/AT91SAM7A3/Retarget.c
  (for _clock_init() function working correctly)

6. eclipse + gdb server from JLink + arm-none-eabi-gdb from GNU ARM Tools Embedded
  For debug only.

First, you need to compile CppUTest and target startup library:
  make -C ../../../platforms/armcc
  make -C ../../../platforms_startup/armcc/AT91SAM7A3

Second, you need to write tests. As example, I use
  $(CPPUTEST_HOME)/examples/AllTests/CircularBufferTest.cpp.
  All test from $(CPPUTEST_HOME)/examples/AllTests/ needs to many
  RAM (chip does not have such).

Third, you need to make executable:
  make all

Fourth, you need to program executable on target chip:
  make prog

Project use semihosting, so you may use standard printf() or std::cout << "Hello!"

If problems with heap or low memory, adjust heap size in
  $(CPPUTEST_HOME)/platforms_startup/armcc/AT91SAM7A3/SAM7A3.asm
  and rebuild startup library.

Startup library uses standard Keil MDK-ARM license.

Eclipse project is tested in eclipse Kepler, eclipse Luna.
You need to adjust some environment variables in "C/C++ Build" tab in
properties window for project.
"CPPUTEST_HOME" is a path to root of CppUTest
"KEIL_DIR" is a path to ARM C/C++ compiler
"PATH" there is need to add path to make.exe
Eclipse project use plugin "GDB Hardware Debugger" to debug, so for debug
you may install "GDB Hardware Debugger" and gdb client (from
GNU ARM Tools Embedded) or create your own debug configuration
(for exampe, use eclipse plugin from Keil MDK-ARM installation; no need to
install other plugins and toolchains).
0707010000C068000081A4000003E8000000640000000168A04FE70000243B000000080000003000000000000000000000003600000000platforms_examples/armcc/AT91SAM7A3/AT91SAM7A3.jflash  AppVersion = 47803
[GENERAL]
  ConnectMode = 0
  CurrentFile = "obj/tst.mot"
  DataFileSAddr = 0x00000000
  GUIMode = 0
  HostName = ""
  TargetIF = 0
  USBPort = 0
  USBSerialNo = 0x00000000
[JTAG]
  IRLen = 0
  MultipleTargets = 0
  NumDevices = 0
  Speed0 = 30
  Speed1 = 400
  TAP_Number = 0
  UseAdaptive0 = 0
  UseAdaptive1 = 0
  UseMaxSpeed0 = 0
  UseMaxSpeed1 = 1
[CPU]
  CheckCoreID = 1
  ChipName = "Atmel AT91SAM7A3"
  ClockSpeed = 0x003D0900
  Core = 0x070000FF
  CoreID = 0x3F0F0F0F
  CoreIDMask = 0xFFFFFFFF
  DeviceFamily = 0x00000007
  EndianMode = 0
  HasInternalFlash = 1
  InitStep0_Action = "Write 32bit"
  InitStep0_Comment = "Peripherial reset, need for disable WDT"
  InitStep0_Value0 = 0xFFFFFD00
  InitStep0_Value1 = 0xA5000004
  InitStep10_Action = "Write 32bit"
  InitStep10_Comment = "Unlock 0 region"
  InitStep10_Value0 = 0xFFFFFF64
  InitStep10_Value1 = 0x5A000004
  InitStep11_Action = "Delay"
  InitStep11_Comment = ""
  InitStep11_Value0 = 0x00000000
  InitStep11_Value1 = 0x00000001
  InitStep12_Action = "Write 32bit"
  InitStep12_Comment = "Unlock 1 region"
  InitStep12_Value0 = 0xFFFFFF64
  InitStep12_Value1 = 0x5A001004
  InitStep13_Action = "Delay"
  InitStep13_Comment = ""
  InitStep13_Value0 = 0x00000000
  InitStep13_Value1 = 0x00000001
  InitStep14_Action = "Write 32bit"
  InitStep14_Comment = "Unlock 2 region"
  InitStep14_Value0 = 0xFFFFFF64
  InitStep14_Value1 = 0x5A002004
  InitStep15_Action = "Delay"
  InitStep15_Comment = ""
  InitStep15_Value0 = 0x00000000
  InitStep15_Value1 = 0x00000001
  InitStep16_Action = "Write 32bit"
  InitStep16_Comment = "Unlock 3 region"
  InitStep16_Value0 = 0xFFFFFF64
  InitStep16_Value1 = 0x5A003004
  InitStep17_Action = "Delay"
  InitStep17_Comment = ""
  InitStep17_Value0 = 0x00000000
  InitStep17_Value1 = 0x00000001
  InitStep18_Action = "Write 32bit"
  InitStep18_Comment = "Unlock 4 region"
  InitStep18_Value0 = 0xFFFFFF64
  InitStep18_Value1 = 0x5A004004
  InitStep19_Action = "Delay"
  InitStep19_Comment = ""
  InitStep19_Value0 = 0x00000000
  InitStep19_Value1 = 0x00000001
  InitStep1_Action = "Reset"
  InitStep1_Comment = ""
  InitStep1_Value0 = 0x00000000
  InitStep1_Value1 = 0x00000000
  InitStep20_Action = "Write 32bit"
  InitStep20_Comment = "Unlock 5 region"
  InitStep20_Value0 = 0xFFFFFF64
  InitStep20_Value1 = 0x5A005004
  InitStep21_Action = "Delay"
  InitStep21_Comment = ""
  InitStep21_Value0 = 0x00000000
  InitStep21_Value1 = 0x00000001
  InitStep22_Action = "Write 32bit"
  InitStep22_Comment = "Unlock 6 region"
  InitStep22_Value0 = 0xFFFFFF64
  InitStep22_Value1 = 0x5A006004
  InitStep23_Action = "Delay"
  InitStep23_Comment = ""
  InitStep23_Value0 = 0x00000000
  InitStep23_Value1 = 0x00000001
  InitStep24_Action = "Write 32bit"
  InitStep24_Comment = "Unlock 7 region"
  InitStep24_Value0 = 0xFFFFFF64
  InitStep24_Value1 = 0x5A007004
  InitStep25_Action = "Delay"
  InitStep25_Comment = ""
  InitStep25_Value0 = 0x00000000
  InitStep25_Value1 = 0x00000001
  InitStep26_Action = "Write 32bit"
  InitStep26_Comment = "Unlock 8 region"
  InitStep26_Value0 = 0xFFFFFF64
  InitStep26_Value1 = 0x5A008004
  InitStep27_Action = "Delay"
  InitStep27_Comment = ""
  InitStep27_Value0 = 0x00000000
  InitStep27_Value1 = 0x00000001
  InitStep28_Action = "Write 32bit"
  InitStep28_Comment = "Unlock 9 region"
  InitStep28_Value0 = 0xFFFFFF64
  InitStep28_Value1 = 0x5A009004
  InitStep29_Action = "Delay"
  InitStep29_Comment = ""
  InitStep29_Value0 = 0x00000000
  InitStep29_Value1 = 0x00000001
  InitStep2_Action = "Delay"
  InitStep2_Comment = ""
  InitStep2_Value0 = 0x00000000
  InitStep2_Value1 = 0x00000002
  InitStep30_Action = "Write 32bit"
  InitStep30_Comment = "Unlock 10 region"
  InitStep30_Value0 = 0xFFFFFF64
  InitStep30_Value1 = 0x5A00A004
  InitStep31_Action = "Delay"
  InitStep31_Comment = ""
  InitStep31_Value0 = 0x00000000
  InitStep31_Value1 = 0x00000001
  InitStep32_Action = "Write 32bit"
  InitStep32_Comment = "Unlock 11 region"
  InitStep32_Value0 = 0xFFFFFF64
  InitStep32_Value1 = 0x5A00B004
  InitStep33_Action = "Delay"
  InitStep33_Comment = ""
  InitStep33_Value0 = 0x00000000
  InitStep33_Value1 = 0x00000001
  InitStep34_Action = "Write 32bit"
  InitStep34_Comment = "Unlock 12 region"
  InitStep34_Value0 = 0xFFFFFF64
  InitStep34_Value1 = 0x5A00C004
  InitStep35_Action = "Delay"
  InitStep35_Comment = ""
  InitStep35_Value0 = 0x00000000
  InitStep35_Value1 = 0x00000001
  InitStep36_Action = "Write 32bit"
  InitStep36_Comment = "Unlock 13 region"
  InitStep36_Value0 = 0xFFFFFF64
  InitStep36_Value1 = 0x5A00D004
  InitStep37_Action = "Delay"
  InitStep37_Comment = ""
  InitStep37_Value0 = 0x00000000
  InitStep37_Value1 = 0x00000001
  InitStep38_Action = "Write 32bit"
  InitStep38_Comment = "Unlock 14 region"
  InitStep38_Value0 = 0xFFFFFF64
  InitStep38_Value1 = 0x5A00E004
  InitStep39_Action = "Delay"
  InitStep39_Comment = ""
  InitStep39_Value0 = 0x00000000
  InitStep39_Value1 = 0x00000001
  InitStep3_Action = "Write 32bit"
  InitStep3_Comment = "Disable watchdog"
  InitStep3_Value0 = 0xFFFFFD44
  InitStep3_Value1 = 0x00008000
  InitStep40_Action = "Write 32bit"
  InitStep40_Comment = "Unlock 15 region"
  InitStep40_Value0 = 0xFFFFFF64
  InitStep40_Value1 = 0x5A00F004
  InitStep41_Action = "Delay"
  InitStep41_Comment = ""
  InitStep41_Value0 = 0x00000000
  InitStep41_Value1 = 0x00000001
  InitStep4_Action = "Write 32bit"
  InitStep4_Comment = "Set PLL"
  InitStep4_Value0 = 0xFFFFFC20
  InitStep4_Value1 = 0x00000601
  InitStep5_Action = "Delay"
  InitStep5_Comment = ""
  InitStep5_Value0 = 0x00000000
  InitStep5_Value1 = 0x00000002
  InitStep6_Action = "Write 32bit"
  InitStep6_Comment = "Set PLL and divider"
  InitStep6_Value0 = 0xFFFFFC2C
  InitStep6_Value1 = 0x00C79E04
  InitStep7_Action = "Write 32bit"
  InitStep7_Comment = "4MHz"
  InitStep7_Value0 = 0xFFFFFC30
  InitStep7_Value1 = 0x00000001
  InitStep8_Action = "Delay"
  InitStep8_Comment = ""
  InitStep8_Value0 = 0x00000000
  InitStep8_Value1 = 0x00000002
  InitStep9_Action = "Write 32bit"
  InitStep9_Comment = "Set WS = 2 (for write), FCN = 6 for 4 MHz"
  InitStep9_Value0 = 0xFFFFFF60
  InitStep9_Value1 = 0x00060000
  NumExitSteps = 0
  NumInitSteps = 42
  RAMAddr = 0x00200000
  RAMSize = 0x00004000
  ScriptFile = ""
  UseAutoSpeed = 0x00000001
  UseRAM = 1
  UseScriptFile = 0
[FLASH]
  aSectorSel[1024] = 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1
  AutoDetect = 0
  BankName = ""
  BankSelMode = 0
  BaseAddr = 0x00100000
  CheckId = 0
  CustomRAMCode = ""
  DeviceName = "AT91SAM7A3 internal"
  EndBank = 1023
  NumBanks = 1
  OrgNumBits = 32
  OrgNumChips = 1
  StartBank = 0
  UseCustomRAMCode = 0
[PRODUCTION]
  AutoPerformsErase = 1
  AutoPerformsHardLock = 0
  AutoPerformsHardUnlock = 0
  AutoPerformsProgram = 1
  AutoPerformsSecure = 0
  AutoPerformsSoftLock = 0
  AutoPerformsSoftUnlock = 1
  AutoPerformsStartApp = 1
  AutoPerformsUnsecure = 0
  AutoPerformsVerify = 1
  EnableProductionMode = 0
  EnableTargetPower = 1
  EraseType = 1
  ProductionDelay = 0x000001F4
  ProductionThreshold = 0x00000BB8
  ProgramSN = 0
  SerialFile = ""
  SNAddr = 0x00000000
  SNInc = 0x00000001
  SNLen = 0x00000008
  SNListFile = ""
  SNValue = 0x00000001
  TargetPowerDelay = 0x00000014
  VerifyType = 2
0707010000C06A000081A4000003E8000000640000000168A04FE7000000C6000000080000003000000000000000000000002D00000000platforms_examples/armcc/AT91SAM7A3/HEAP.txtHeap usage for initialization of std::cout is about 1496 bytes.
Additional heap usage for std::cout << (double) is about 644 bytes.

All heap usage for CRT + cpp + sample tests is about 10624 bytes.0707010000C066000081A4000003E8000000640000000168A04FE700001EF7000000080000003000000000000000000000002E00000000platforms_examples/armcc/AT91SAM7A3/.cproject<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
	<storageModule moduleId="org.eclipse.cdt.core.settings">
		<buildSystem id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317">
			<storageModule id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317" moduleId="org.eclipse.cdt.core.settings"/>
		</buildSystem>
		<cconfiguration id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317">
			<storageModule moduleId="cdtBuildSystem" version="4.0.0">
				<configuration artifactName="CppUTest AT91SAM7A3 sample project" buildProperties="" description="" errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317" name="Preference Configuration" parent="org.eclipse.cdt.build.core.prefbase.cfg">
					<folderInfo id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317." name="/" resourcePath="">
						<toolChain errorParsers="" id="org.eclipse.cdt.build.core.prefbase.toolchain.1554948526" name="No ToolChain" resourceTypeBasedDiscovery="false" superClass="org.eclipse.cdt.build.core.prefbase.toolchain">
							<targetPlatform binaryParser="org.eclipse.cdt.core.ELF" id="org.eclipse.cdt.build.core.prefbase.toolchain.1554948526.181399830" name=""/>
							<builder enableAutoBuild="true" errorParsers="org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.CWDLocator" id="org.eclipse.cdt.build.core.settings.default.builder.1798742252" incrementalBuildTarget="all" keepEnvironmentInBuildfile="false" name="Gnu Make Builder" parallelBuildOn="true" parallelizationNumber="optimal" superClass="org.eclipse.cdt.build.core.settings.default.builder"/>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.libs.2119621088" name="holder for library settings" superClass="org.eclipse.cdt.build.core.settings.holder.libs"/>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.256174936" name="Assembly" superClass="org.eclipse.cdt.build.core.settings.holder">
								<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.533153938" name="Include Paths" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
									<listOptionValue builtIn="false" value="&quot;${SYS_INCLUDE_DIRS}&quot;"/>
									<listOptionValue builtIn="false" value="&quot;../${CPPUTEST_HOME}\include&quot;"/>
								</option>
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.946681329" languageId="org.eclipse.cdt.core.assembly" languageName="Assembly" sourceContentType="org.eclipse.cdt.core.asmSource" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.1341050389" name="GNU C++" superClass="org.eclipse.cdt.build.core.settings.holder">
								<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.1198479538" name="Include Paths" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
									<listOptionValue builtIn="false" value="&quot;${SYS_INCLUDE_DIRS}&quot;"/>
									<listOptionValue builtIn="false" value="&quot;../${CPPUTEST_HOME}\include&quot;"/>
								</option>
								<option id="org.eclipse.cdt.build.core.settings.holder.symbols.973447871" name="Symbols" superClass="org.eclipse.cdt.build.core.settings.holder.symbols" valueType="definedSymbols">
									<listOptionValue builtIn="false" value="CPPUTEST_MEM_LEAK_DETECTION_DISABLED"/>
								</option>
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.1258467244" languageId="org.eclipse.cdt.core.g++" languageName="GNU C++" sourceContentType="org.eclipse.cdt.core.cxxSource,org.eclipse.cdt.core.cxxHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.1638185256" name="GNU C" superClass="org.eclipse.cdt.build.core.settings.holder">
								<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.1190707854" name="Include Paths" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
									<listOptionValue builtIn="false" value="&quot;${SYS_INCLUDE_DIRS}&quot;"/>
									<listOptionValue builtIn="false" value="&quot;../${CPPUTEST_HOME}\include&quot;"/>
								</option>
								<option id="org.eclipse.cdt.build.core.settings.holder.symbols.632118779" name="Symbols" superClass="org.eclipse.cdt.build.core.settings.holder.symbols"/>
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.831274149" languageId="org.eclipse.cdt.core.gcc" languageName="GNU C" sourceContentType="org.eclipse.cdt.core.cSource,org.eclipse.cdt.core.cHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
						</toolChain>
					</folderInfo>
				</configuration>
			</storageModule>
			<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317" moduleId="org.eclipse.cdt.core.settings" name="Preference Configuration">
				<externalSettings/>
				<extensions>
					<extension id="org.eclipse.cdt.core.VCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
				</extensions>
			</storageModule>
			<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
		</cconfiguration>
	</storageModule>
	<storageModule moduleId="cdtBuildSystem" version="4.0.0">
		<project id="CppUTest AT91SAM7A3 sample project.null.1595792166" name="CppUTest AT91SAM7A3 sample project"/>
	</storageModule>
	<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
	<storageModule moduleId="scannerConfiguration">
		<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
		<scannerConfigBuildInfo instanceId="preference.org.eclipse.cdt.managedbuilder.core.configurationDataProvider.1662926317">
			<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
		</scannerConfigBuildInfo>
	</storageModule>
	<storageModule moduleId="refreshScope" versionNumber="2">
		<configuration configurationName="Preference Configuration">
			<resource resourceType="PROJECT" workspacePath="/CppUTest AT91SAM7A3 sample project"/>
		</configuration>
	</storageModule>
</cproject>
0707010000C06F000081A4000003E8000000640000000168A04FE700000329000000080000003000000000000000000000002C00000000platforms_examples/armcc/AT91SAM7A3/ROM.sct#! armcc -E
; code upper need to use #define 

;-------------------------------------------------------------------------------------
;   Keil scatter loading file
; For AT91SAM7A3
;-------------------------------------------------------------------------------------

#define FLASH_START (0x00100000)
#define FLASH_END   (0x00140000)
#define FLASH_SIZE  (FLASH_END-FLASH_START)

; Internal SRAM
#define RAM_START 0x00200000
#define RAM_END   0x00208000
#define RAM_SIZE  (RAM_END-RAM_START)

; Load region for main program
LR1   FLASH_START  FLASH_SIZE {
   ER2 FLASH_START {
        *.o(.reset, +First)
        *.o(InRoot$$Sections)
        *.o(+RO)
   }
   ER5 RAM_START RAM_SIZE {
    *.o(+RW +ZI)
    *.o(STACK)
   }
}



/*----------------------------------------------------------------------------*/

0707010000C069000081A4000003E8000000640000000168A04FE700001CCA000000080000003000000000000000000000003600000000platforms_examples/armcc/AT91SAM7A3/AT91SAM7A3.launch<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.cdt.debug.gdbjtag.launchConfigurationType">
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.delay" value="3"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doHalt" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doReset" value="false"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.initCommands" value="monitor endian little&#13;&#10;monitor reset&#13;&#10;monitor speed auto&#13;&#10;set remote memory-write-packet-size 4096&#13;&#10;set remote memory-write-packet-size fixed&#13;&#10;monitor clrbp&#13;&#10;monitor flash download = 0&#13;&#10;monitor flash breakpoints = 1&#13;&#10;set target-wide-charset UTF-8"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="Generic TCP/IP"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.portNumber" value="2331"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.runCommands" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="false"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.DEBUG_NAME" value="D:\GNU Tools ARM Embedded\4.7 2013q2\bin\arm-none-eabi-gdb.exe"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="D:\GNU Tools ARM Embedded\4.7 2013q2\bin\arm-none-eabi-gdb.exe"/>
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="0"/>
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&lt;contentList&gt;&lt;content id=&quot;r0-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r1-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r2-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r3-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r4-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r5-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r6-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r7-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r8-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r9-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r10-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r11-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r12-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;sp-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;lr-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;cpsr-(format)&quot; val=&quot;4&quot;/&gt;&lt;/contentList&gt;"/>
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;globalVariableList/&gt;&#13;&#10;"/>
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;memoryBlockExpressionList&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x20063c&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x20063c&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x207907&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x2007d0&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x64&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;memoryBlockExpressionItem&gt;&#13;&#10;&lt;expression text=&quot;0x2007d0&quot;/&gt;&#13;&#10;&lt;/memoryBlockExpressionItem&gt;&#13;&#10;&lt;/memoryBlockExpressionList&gt;&#13;&#10;"/>
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="D:\Home\bortsov\git\cpputest\platforms_tests\armcc\AT91SAM7A3\obj\SimpleStringTest.axf"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="CppUTest AT91SAM7A3 sample project"/>
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value=""/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/CppUTest AT91SAM7A3 sample project"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="4"/>
</listAttribute>
<mapAttribute key="org.eclipse.debug.core.preferred_launchers">
<mapEntry key="[debug]" value="org.eclipse.cdt.debug.gdbjtag.core.cdiLaunchDelegate"/>
</mapAttribute>
<listAttribute key="org.eclipse.debug.ui.favoriteGroups">
<listEntry value="org.eclipse.debug.ui.launchGroup.debug"/>
</listAttribute>
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;memoryBlockExpressionList context=&quot;reserved-for-future-use&quot;/&gt;&#13;&#10;"/>
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
<stringAttribute key="saved_expressions&lt;seperator&gt;Unknown" value="0X20063C,0x1297a0,0x200090,r0,$r0,$r1,0x00127EB0,r5,$r5,0x00207907,buf,&amp;size_heap,0x1004f0"/>
</launchConfiguration>
0707010000C067000081A4000003E8000000640000000168A04FE700000313000000080000003000000000000000000000002D00000000platforms_examples/armcc/AT91SAM7A3/.project<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
	<name>CppUTest AT91SAM7A3 sample project</name>
	<comment></comment>
	<projects>
	</projects>
	<buildSpec>
		<buildCommand>
			<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
			<arguments>
			</arguments>
		</buildCommand>
		<buildCommand>
			<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
			<triggers>full,incremental,</triggers>
			<arguments>
			</arguments>
		</buildCommand>
	</buildSpec>
	<natures>
		<nature>org.eclipse.cdt.core.cnature</nature>
		<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
		<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
		<nature>org.eclipse.cdt.core.ccnature</nature>
	</natures>
</projectDescription>
0707010000C06C000081A4000003E8000000640000000168A04FE7000022E1000000080000003000000000000000000000002D00000000platforms_examples/armcc/AT91SAM7A3/Makefile.SILENT:

#We don't need to clean up when we're making these targets
NODEPS  = clean

# CPU architecture. Passing to armcc.exe. For list: armcc --cpu list
ifndef CPU
	CPU = ARM7TDMI
endif

# ARM/THUMB mode. Passing to armcc.exe. May be 'thumb' or 'arm'
ifndef CPU_MODE
	CPU_MODE = thumb
endif

TARGET_PLATFORM =armcc_$(CPU)_$(CPU_MODE)

# Need to use only relative path! Path with logical letters does not working.
CPPUTEST_HOME = ../../..

COMPONENT_NAME = app

CPPUTEST_OBJS_DIR = objs

# directory for appication library
CPPUTEST_LIB_DIR = lib

CPPUTEST_USE_MEM_LEAK_DETECTION = N
CPPUTEST_USE_STD_CPP_LIB = Y
CPPUTEST_USE_VPATH = Y
CPPUTEST_USE_STD_C_LIB = Y
CPPUTEST_ENABLE_DEBUG = Y
CPPUTEST_USE_EXTENSIONS = N

SRC_DIRS = \

SRC_FILES = $(CPPUTEST_HOME)/examples/ApplicationLib/CircularBuffer.cpp \
  $(CPPUTEST_HOME)/examples/ApplicationLib/Printer.cpp

TEST_SRC_DIRS = \
	tests \

TEST_FILES = $(CPPUTEST_HOME)/examples/AllTests/CircularBufferTest.cpp


# directory with CppUTest and startup libraries
CPPUTEST_LIB_LINK_DIR = $(CPPUTEST_HOME)/lib/$(TARGET_PLATFORM)

INCLUDE_DIRS = \
  $(CPPUTEST_HOME)/include \
  $(SRC_DIRS) \
  $(CPPUTEST_HOME)/examples/ApplicationLib \

# name of extension of output file. Default Keil MDK-ARM extension is .axf which is elf format
# .axf will be .elf for eclipse debug
OUTFILE_EXT = elf

# output filename, mapfile (.map), hexfile (.mot)
OUTNAME = $(COMPONENT_NAME)
OUTFILE = $(OUTNAME).$(OUTFILE_EXT)
HEXFILE = $(OUTNAME).mot
MAPFILE = $(OUTNAME).map

# CYGWIN path
CYGWIN =C:/CYGWIN/bin
MKDIR  =$(CYGWIN)/mkdir
RM     =$(CYGWIN)/rm
TOUCH  =$(CYGWIN)/touch
ECHO   =$(CYGWIN)/echo

KEIL_DIR=D:/Keil/ARM/ARMCC
CC=$(KEIL_DIR)/bin/armcc.exe
AS=$(KEIL_DIR)/bin/armasm.exe
AR=$(KEIL_DIR)/bin/armar.exe
LD=$(KEIL_DIR)/bin/armlink.exe
FROMELF=$(KEIL_DIR)/bin/fromelf.exe
# armcc system include path
SYS_INCLUDE_DIRS =$(KEIL_DIR)/include 

JFLASH ="C:/Program Files (x86)/SEGGER/JLink_V490b/JFlash.exe"
JFLASHPRJ =AT91SAM7A3.jflash
LDSCRIPT = ROM.sct

CPUFLAGS =--cpu=$(CPU)
ifeq ($(CPU_MODE), thumb)
  CPUFLAGS +=--apcs=/interwork
endif
DEPFLAGS =-M \
 $(INCLUDES) \
 --depend_format=unix_escaped \
 --depend_single_line \
 --no_depend_system_headers

OPTFLAGS =-O3

CPPUTEST_CPPFLAGS =$(CPUFLAGS) \
 $(OPTFLAGS) \
 -c \
 -g \
 $(INCLUDES) \
 --$(CPU_MODE) \
 --exceptions \
 -D__CLK_TCK=1000 \

CPPUTEST_LDFLAGS =$(CPUFLAGS) \
 --strict \
 --entry=Reset_Handler \
 --summary_stderr \
 --map \
 --callgraph \
 --info=summarysizes \
 --info=sizes \
 --info=totals \
 --info=veneers\
 --load_addr_map_info \
 --library_type=standardlib \
 --remove \
 --debug \

ARFLAGS = --debug_symbols


# new and delete for memory leak detection on by default
ifndef CPPUTEST_USE_MEM_LEAK_DETECTION
	CPPUTEST_USE_MEM_LEAK_DETECTION = Y
endif

# Use the standard C library
ifndef CPPUTEST_USE_STD_C_LIB
	CPPUTEST_USE_STD_C_LIB = Y
endif

# Use the standard C++ library
ifndef CPPUTEST_USE_STD_CPP_LIB
	CPPUTEST_USE_STD_CPP_LIB = Y
endif

# No extentions is default
ifndef CPPUTEST_USE_EXTENSIONS
	CPPUTEST_USE_EXTENSIONS = N
endif

# No VPATH is default
ifndef CPPUTEST_USE_VPATH
	CPPUTEST_USE_VPATH = N
endif
# Make empty, instead of 'N', for usage in $(if ) conditionals
ifneq ($(CPPUTEST_USE_VPATH), Y)
	CPPUTEST_USE_VPATH =
endif

# Without the C library, we'll need to disable the C++ library and ... 
ifeq ($(CPPUTEST_USE_STD_C_LIB), N)
	CPPUTEST_USE_STD_CPP_LIB = N
	CPPUTEST_USE_MEM_LEAK_DETECTION = N
	CPPUTEST_CPPFLAGS += -DCPPUTEST_STD_C_LIB_DISABLED
	CPPUTEST_LDFLAGS +=--no_scanlib
else
	INCLUDE_DIRS +=$(SYS_INCLUDE_DIRS)
endif


ifeq ($(CPPUTEST_USE_MEM_LEAK_DETECTION), N)
	CPPUTEST_CPPFLAGS += -DCPPUTEST_MEM_LEAK_DETECTION_DISABLED
else
    ifndef CPPUTEST_MEMLEAK_DETECTOR_NEW_MACRO_FILE
	    	CPPUTEST_MEMLEAK_DETECTOR_NEW_MACRO_FILE = -include $(CPPUTEST_HOME)/include/CppUTest/MemoryLeakDetectorNewMacros.h
    endif
    ifndef CPPUTEST_MEMLEAK_DETECTOR_MALLOC_MACRO_FILE
	    CPPUTEST_MEMLEAK_DETECTOR_MALLOC_MACRO_FILE = -include $(CPPUTEST_HOME)/include/CppUTest/MemoryLeakDetectorMallocMacros.h
	endif	
endif


ifeq ($(CPPUTEST_USE_STD_CPP_LIB), N)
	CPPUTEST_CPPFLAGS += -DCPPUTEST_STD_CPP_LIB_DISABLED
endif

# Link with CppUTest lib
CPPUTEST_LIB = $(CPPUTEST_LIB_LINK_DIR)/libCppUTest.a

# Link with startup lib
CPPUTEST_LIB += $(CPPUTEST_LIB_LINK_DIR)/libStartup_AT91SAM7A3.a

# Link with CppUTestExt lib
ifeq ($(CPPUTEST_USE_EXTENSIONS), Y)
CPPUTEST_LIB += $(CPPUTEST_LIB_LINK_DIR)/libCppUTestExt.a
endif

TARGET_LIB = \
    $(CPPUTEST_LIB_DIR)/lib$(COMPONENT_NAME).a

ifndef TEST_TARGET
	ifndef TARGET_PLATFORM
		TEST_TARGET = $(COMPONENT_NAME)_tests
	else
		TEST_TARGET = $(COMPONENT_NAME)_$(TARGET_PLATFORM)_tests
	endif
endif

#Helper Functions
get_src_from_dir  = $(wildcard $1/*.cpp) $(wildcard $1/*.cc) $(wildcard $1/*.c) $(wildcard $1/*.asm)
get_src_from_dir_list = $(foreach dir, $1, $(call get_src_from_dir,$(dir)))
__src_to = $(subst .c,$1, $(subst .cc,$1, $(subst .cpp,$1, $(if $(CPPUTEST_USE_VPATH),$(notdir $2),$2))))
src_to = $(addprefix $3/,$(call __src_to,$1,$2))
src_to_o = $(call src_to,.o,$1,$2)
src_to_d = $(call src_to,.d,$1,$2)
time = $(shell date +%s)
delta_t = $(eval minus, $1, $2)
debug_print_list = $(foreach word,$1,echo "  $(word)";) echo

# исходники программных модулей
SRC = $(call get_src_from_dir_list, $(SRC_DIRS)) $(SRC_FILES)
OBJ = $(call src_to_o,$(SRC),$(CPPUTEST_OBJS_DIR))
# исходники тестов
TEST_SRC = $(call get_src_from_dir_list, $(TEST_SRC_DIRS)) $(TEST_FILES)
TEST_OBJ = $(call src_to_o,$(TEST_SRC),$(CPPUTEST_OBJS_DIR))

# If we're using VPATH
ALL_SRC = $(SRC) $(TEST_SRC)
ifeq ($(CPPUTEST_USE_VPATH), Y)
# gather all the source directories and add them
	VPATH += $(sort $(dir $(ALL_SRC)))
# Add the component name to the objs dir path, to differentiate between same-name objects
	CPPUTEST_OBJS_DIR := $(addsuffix /$(COMPONENT_NAME),$(CPPUTEST_OBJS_DIR))
endif

# for building application library
INCLUDES += $(foreach dir, $(INCLUDE_DIRS), -I$(dir))
DEP_FILES = $(call src_to_d, $(SRC), $(CPPUTEST_OBJS_DIR))
DEP_TEST_FILES = $(call src_to_d, $(TEST_SRC), $(CPPUTEST_OBJS_DIR))
STUFF_TO_CLEAN = $(OBJ) $(TEST_OBJ) $(DEP_FILES) $(DEP_TEST_FILES) $(TARGET_LIB)

#Don't create CRT dependencies when we're cleaning, for instance
ifeq (0, $(words $(findstring $(MAKECMDGOALS), $(NODEPS))))
    -include $(DEP_FILES)
endif

STUFF_TO_CLEAN += $(OUTFILE) $(MAPFILE)


all: $(CPPUTEST_OBJS_DIR)/$(OUTFILE)
	echo Done!

$(TARGET_LIB): $(OBJ) | $(CPPUTEST_LIB_DIR)
	echo Building application library $@
	$(AR) $(ARFLAGS) --create $@ $^

$(CPPUTEST_OBJS_DIR)/$(OUTFILE): $(TEST_OBJ) $(CPPUTEST_LIB) $(TARGET_LIB) | ROM.sct Makefile
	echo Linking!
	$(LD) $(CPPUTEST_LDFLAGS) $^ --scatter $(LDSCRIPT) --list $(MAPFILE) -o $@


.PHONY: prog
prog:	$(CPPUTEST_OBJS_DIR)/$(HEXFILE)
	$(JFLASH) -openprj$(JFLASHPRJ) -open$< -auto -exit 

$(CPPUTEST_OBJS_DIR)/$(HEXFILE): $(CPPUTEST_OBJS_DIR)/$(OUTFILE)
	echo Converting to Motorola S19
	$(FROMELF) --m32 --output=$@ $<

debug:
	echo
	echo "Target Source files:"
	$(call debug_print_list,$(SRC))
	echo "Target Object files:"
	$(call debug_print_list,$(OBJ))
	echo "All Input Dependency files:"
	$(call debug_print_list,$(DEP_FILES))
	echo Stuff to clean:
	$(call debug_print_list,$(STUFF_TO_CLEAN))
	echo Includes:
	$(call debug_print_list,$(INCLUDES))
	echo Directories to create:
	$(call debug_print_list,$(OBJS_DIRS))
	echo Directories of CppUTest object files:
	$(call debug_print_list,$(OBJS_DIR))

#Don't create dependencies when we're cleaning, for instance
ifeq (0, $(words $(findstring $(MAKECMDGOALS), $(NODEPS))))
    -include $(DEP_FILES)
endif

OBJS_DIRS =$(sort $(dir $(STUFF_TO_CLEAN)))

$(LIB_DIR) $(OBJS_DIRS):
	echo Updating directory $@
	$(MKDIR) -p $@

#This is the rule for creating the dependency files
$(CPPUTEST_OBJS_DIR)/%.d: %.c Makefile | $(OBJS_DIRS)
	echo Compiling C file $< for dependency. Out file $@.
	$(CC) $(DEPFLAGS) $< --depend=$@ --depend_target='$(patsubst %.d,%.o,$@)'

$(CPPUTEST_OBJS_DIR)/%.d: %.cpp Makefile | $(OBJS_DIRS)
	echo Compiling C++ file $< for dependency. Out file $@.
	$(CC) $(DEPFLAGS) $< --depend=$@ --depend_target='$(patsubst %.d,%.o,$@)'

$(CPPUTEST_OBJS_DIR)/%.d: %.cc Makefile | $(OBJS_DIRS)
	echo Compiling CC++ file $< for dependency. Out file $@.
	$(CC) $(DEPFLAGS) $< --depend=$@ --depend_target='$(patsubst %.d,%.o,$@)'

#This rule does the compilation C++ files
$(CPPUTEST_OBJS_DIR)/%.o: %.cpp $(CPPUTEST_OBJS_DIR)/%.d
	echo Compiling C++ file $<. Out file $@
	$(CC) $(CPPUTEST_CPPFLAGS) $< -o $@

#This rule does the compilation CC++ files
$(CPPUTEST_OBJS_DIR)/%.o: %.cc $(CPPUTEST_OBJS_DIR)/%.d
	echo Compiling CC++ file $<. Out file $@
	$(CC) $(CPPUTEST_CPPFLAGS) $< -o $@

#This rule does the compilation C files
$(CPPUTEST_OBJS_DIR)/%.o: %.c $(CPPUTEST_OBJS_DIR)/%.d
	echo Compiling C file $<. Out file $@
	$(CC) $(CPPUTEST_CPPFLAGS) $< -o $@

clean:
	$(RM) -f $(STUFF_TO_CLEAN)


0707010000C073000081A4000003E8000000640000000168A04FE7000006B4000000080000003000000000000000000000003300000000platforms_examples/armcc/AT91SAM7A3/tests/main.cpp/*
 * Copyright (c) 2007, Michael Feathers, James Grenning and Bas Vodde
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *     * Redistributions of source code must retain the above copyright
 *       notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright
 *       notice, this list of conditions and the following disclaimer in the
 *       documentation and/or other materials provided with the distribution.
 *     * Neither the name of the <organization> nor the
 *       names of its contributors may be used to endorse or promote products
 *       derived from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE EARLIER MENTIONED AUTHORS ''AS IS'' AND ANY
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED. IN NO EVENT SHALL <copyright holder> BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

#include "CppUTest/CommandLineTestRunner.h"

int main(int ac, char** av)
{
    return RUN_ALL_TESTS(ac, av);
}

0707010000C081000041ED000003E8000000640000000268A04FE700000000000000080000003000000000000000000000002500000000platforms_examples/armcc/LPC1833/src0707010000C083000041ED000003E8000000640000000268A04FE700000000000000080000003000000000000000000000002700000000platforms_examples/armcc/LPC1833/tests0707010000C07F000081A4000003E8000000640000000168A04FE70000049F000000080000003000000000000000000000002B00000000platforms_examples/armcc/LPC1833/FLASH.sct#! armcc -E
; code upper need to use #define 

;-------------------------------------------------------------------------------------
;   Keil scatter loading file
; For LPC1833
;-------------------------------------------------------------------------------------

; Internal SRAM0
#define SRAM0_START 0x10000000
#define SRAM0_END   0x10008000
#define SRAM0_SIZE  (SRAM0_END-SRAM0_START)

; Internal SRAM1
#define SRAM1_START 0x10080000
#define SRAM1_END   0x1008A000
#define SRAM1_SIZE  (SRAM1_END-SRAM1_START)

; Internal SRAM2
#define SRAM2_START 0x20000000
#define SRAM2_END   0x20010000
#define SRAM2_SIZE  (SRAM2_END-SRAM2_START)

; SDRAM
#define SDRAM_START 0x28000000

; Internal FLASHA
#define FLASHA_START 0x1A000000
#define FLASHA_END   0x1A040000
#define FLASHA_SIZE  (FLASHA_END-FLASHA_START)

; Internal FLASHB
#define FLASHB_START 0x1B000000
#define FLASHB_END   0x1B040000
#define FLASHB_SIZE  (FLASHB_END-FLASHB_START)

LR1 FLASHA_START FLASHA_SIZE {
  ER1 FLASHA_START FLASHA_SIZE {
    *(RESET, +FIRST)
   *(InRoot$$Sections)
    *.o (+RO)
  }
  ER2 SRAM0_START SRAM0_SIZE {
    *.o (+RW +ZI)
  }

  ER4 (SRAM1_START) SRAM1_SIZE {
    *(HEAP)
    *(STACK)
  }
}

0707010000C080000081A4000003E8000000640000000168A04FE700000716000000080000003000000000000000000000003000000000platforms_examples/armcc/LPC1833/LPC1833.jflash  AppVersion = 46202
[GENERAL]
  ConnectMode = 0
  CurrentFile = "objs\can_eth.hex"
  DataFileSAddr = 0x00000000
  GUIMode = 0
  HostName = ""
  TargetIF = 0
  USBPort = 0
  USBSerialNo = 0x00000000
[JTAG]
  IRLen = 0
  MultipleTargets = 0
  NumDevices = 0
  Speed0 = 5
  Speed1 = 4000
  TAP_Number = 0
  UseAdaptive0 = 0
  UseAdaptive1 = 0
  UseMaxSpeed0 = 1
  UseMaxSpeed1 = 1
[CPU]
  CheckCoreID = 1
  ChipName = "NXP LPC1833"
  ClockSpeed = 0x016E3600
  Core = 0x030000FF
  CoreID = 0x4BA00477
  CoreIDMask = 0x0F000FFF
  DeviceFamily = 0x00000003
  EndianMode = 0
  HasInternalFlash = 1
  InitStep0_Action = "Reset"
  InitStep0_Comment = "Reset and halt target"
  InitStep0_Value0 = 0x00000000
  InitStep0_Value1 = 0x00000000
  NumExitSteps = 0
  NumInitSteps = 1
  RAMAddr = 0x10080000
  RAMSize = 0x00008000
  ScriptFile = ""
  UseAutoSpeed = 0x00000001
  UseRAM = 1
  UseScriptFile = 0
[FLASH]
  aSectorSel[22] = 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1
  AutoDetect = 0
  BankName = ""
  BankSelMode = 0
  BaseAddr = 0x1A000000
  CheckId = 0
  CustomRAMCode = ""
  DeviceName = "LPC1833 internal"
  EndBank = 21
  NumBanks = 1
  OrgNumBits = 32
  OrgNumChips = 1
  StartBank = 0
  UseCustomRAMCode = 0
[PRODUCTION]
  AutoPerformsErase = 1
  AutoPerformsHardLock = 0
  AutoPerformsHardUnlock = 0
  AutoPerformsProgram = 1
  AutoPerformsSecure = 0
  AutoPerformsSoftLock = 0
  AutoPerformsSoftUnlock = 1
  AutoPerformsStartApp = 1
  AutoPerformsUnsecure = 0
  AutoPerformsVerify = 1
  EnableProductionMode = 0
  EnableTargetPower = 0
  EraseType = 1
  ProductionDelay = 0x000001F4
  ProductionThreshold = 0x00000BB8
  ProgramSN = 0
  SerialFile = ""
  SNAddr = 0x00000000
  SNInc = 0x00000001
  SNLen = 0x00000008
  SNListFile = ""
  SNValue = 0x00000001
  TargetPowerDelay = 0x00000014
  VerifyType = 1
0707010000C082000081A4000003E8000000640000000168A04FE700000084000000080000003000000000000000000000002D00000000platforms_examples/armcc/LPC1833/src/dummy.c/* this file is requred to build application library, armar.exe can't build
 * libraries without at least one object input file.
*/
0707010000C085000081A4000003E8000000640000000168A04FE70000006E000000080000003000000000000000000000003100000000platforms_examples/armcc/LPC1833/tests/test1.cpp#include "CppUTest/TestHarness.h"

TEST_GROUP(start)
{
};

TEST(start, first)
{
    FAIL("Start here!");
}
0707010000C084000081A4000003E8000000640000000168A04FE70000074E000000080000003000000000000000000000003000000000platforms_examples/armcc/LPC1833/tests/main.cpp/*
 * Copyright (c) 2007, Michael Feathers, James Grenning and Bas Vodde
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *     * Redistributions of source code must retain the above copyright
 *       notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright
 *       notice, this list of conditions and the following disclaimer in the
 *       documentation and/or other materials provided with the distribution.
 *     * Neither the name of the <organization> nor the
 *       names of its contributors may be used to endorse or promote products
 *       derived from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE EARLIER MENTIONED AUTHORS ''AS IS'' AND ANY
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED. IN NO EVENT SHALL <copyright holder> BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

#include "CppUTest/CommandLineTestRunner.h"

int main(int ac, const char** av)
{
    /* These checks are here to make sure assertions outside test runs don't crash */
    CHECK(true);
    LONGS_EQUAL(1, 1);

    return CommandLineTestRunner::RunAllTests(ac, av);
}

0707010000C07C000041ED000003E8000000640000000268A04FE700000000000000080000003000000000000000000000002700000000platforms_examples/armcc/LPC1768/tests0707010000C07B000081A4000003E8000000640000000168A04FE700000075000000080000003000000000000000000000002F00000000platforms_examples/armcc/LPC1768/jlink_gdb.cmdstart "JLink GDB Server" "C:\Program Files (x86)\SEGGER\JLinkARM_V486a\JLinkGDBServerCL.exe" -device LPC1768 -if SWD
0707010000C07A000081A4000003E8000000640000000168A04FE7000017A2000000080000003000000000000000000000004100000000platforms_examples/armcc/LPC1768/cpputest_example_Default.launch<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.cdt.debug.gdbjtag.launchConfigurationType">
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.delay" value="3"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doHalt" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doReset" value="false"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.initCommands" value="monitor reset&#13;&#10;monitor endian little&#13;&#10;monitor speed auto&#13;&#10;set remote memory-write-packet-size 4096&#13;&#10;set remote memory-write-packet-size fixed&#13;&#10;monitor flash download = 0&#13;&#10;monitor flash breakpoints = 1"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="Generic TCP/IP"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
<intAttribute key="org.eclipse.cdt.debug.gdbjtag.core.portNumber" value="2331"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.runCommands" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="false"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.DEBUG_NAME" value="D:\GNU Tools ARM Embedded\4.7 2013q2\bin\arm-none-eabi-gdb.exe"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard"/>
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="D:\GNU Tools ARM Embedded\4.7 2013q2\bin\arm-none-eabi-gdb.exe"/>
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&lt;contentList&gt;&lt;content id=&quot;FAULTMASK-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;BASEPRI-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;PRIMASK-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;PSP-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;MSP-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;xpsr-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;pc-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;lr-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;sp-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r12-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r11-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r10-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r9-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r8-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r7-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r6-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r5-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r4-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r3-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r2-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r1-(format)&quot; val=&quot;4&quot;/&gt;&lt;content id=&quot;r0-(format)&quot; val=&quot;4&quot;/&gt;&lt;/contentList&gt;"/>
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;globalVariableList/&gt;&#13;&#10;"/>
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;memoryBlockExpressionList/&gt;&#13;&#10;"/>
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="objs\app\app.elf"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="cpputest_example"/>
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value="0.558628371"/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/cpputest_example"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="4"/>
</listAttribute>
<mapAttribute key="org.eclipse.debug.core.preferred_launchers">
<mapEntry key="[debug]" value="org.eclipse.cdt.debug.gdbjtag.core.cdiLaunchDelegate"/>
</mapAttribute>
</launchConfiguration>
0707010000C078000081A4000003E8000000640000000168A04FE70000055B000000080000003000000000000000000000002800000000platforms_examples/armcc/LPC1768/READMESample project to test CppUTest for Keil MDK-ARM toolchain and LPC1768 chip.

Requirements:
1. CYGWIN (rm.exe, mkdir.exe, make.exe)

2. Keil MDK-ARM

3. JLink Flash (for programming chip) or FlashMagic

4. serial connection to UART0 or UART1 interface

5. 12 or 24 MHz quartz. If else, need to be adjusted in
  $(CPPUTEST_HOME)/platforms_startup/armcc/LPC1768/system_LPC17xx.c
  (for _clock_init() function working correctly and to set up 100 MHz core
  clock).
  Please check system_LPC17xx.c for correct quartz selection in function
  SystemInit(), and rebuild startup library for any change.
  Default is 12 MHz quartz.

6. eclipse + gdb server from JLink + arm-none-eabi-gdb from GNU ARM Tools Embedded
  For debug only.

First, you need to compile CppUTest and target startup library:
  make -C ../../../platforms/armcc CPU=Cortex-M3 all
  make -C ../../../platforms_startup/armcc/LPC1768 all

Second, you need to write tests. As example, I use
  $(CPPUTEST_HOME)/examples/AllTests/CircularBufferTest.cpp.

Third, you need to make executable:
  make all

Fourth, you need to program executable on target chip:
  make prog

Project use semihosting, so you may use standard printf() or std::cout << "Hello!"

If problems with heap or low memory, adjust heap size in
  $(CPPUTEST_HOME)/platforms_startup/armcc/LPC1768/startup_LPC17xx.asm
  and rebuild startup library.
0707010000C077000081A4000003E8000000640000000168A04FE700000726000000080000003000000000000000000000003000000000platforms_examples/armcc/LPC1768/LPC1768.jflash  AppVersion = 46202
[GENERAL]
  ConnectMode = 0
  CurrentFile = "objs/app/app.mot"
  DataFileSAddr = 0x00000000
  GUIMode = 0
  HostName = ""
  TargetIF = 1
  USBPort = 0
  USBSerialNo = 0x00000000
[JTAG]
  IRLen = 0
  MultipleTargets = 0
  NumDevices = 0
  Speed0 = 5
  Speed1 = 4000
  TAP_Number = 0
  UseAdaptive0 = 0
  UseAdaptive1 = 0
  UseMaxSpeed0 = 1
  UseMaxSpeed1 = 1
[CPU]
  CheckCoreID = 1
  ChipName = "NXP LPC1768"
  ClockSpeed = 0x05F5E100
  Core = 0x030000FF
  CoreID = 0x4BA00477
  CoreIDMask = 0xFFFFFFFF
  DeviceFamily = 0x00000003
  EndianMode = 0
  HasInternalFlash = 1
  InitStep0_Action = "Reset"
  InitStep0_Comment = "Reset and halt target"
  InitStep0_Value0 = 0x00000000
  InitStep0_Value1 = 0x00000000
  NumExitSteps = 0
  NumInitSteps = 1
  RAMAddr = 0x10000000
  RAMSize = 0x00008000
  ScriptFile = ""
  UseAutoSpeed = 0x00000001
  UseRAM = 1
  UseScriptFile = 0
[FLASH]
  aSectorSel[30] = 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1
  AutoDetect = 0
  BankName = ""
  BankSelMode = 0
  BaseAddr = 0x00000000
  CheckId = 0
  CustomRAMCode = ""
  DeviceName = "LPC1768 internal"
  EndBank = 29
  NumBanks = 1
  OrgNumBits = 32
  OrgNumChips = 1
  StartBank = 0
  UseCustomRAMCode = 0
[PRODUCTION]
  AutoPerformsErase = 1
  AutoPerformsHardLock = 0
  AutoPerformsHardUnlock = 0
  AutoPerformsProgram = 1
  AutoPerformsSecure = 0
  AutoPerformsSoftLock = 0
  AutoPerformsSoftUnlock = 1
  AutoPerformsStartApp = 1
  AutoPerformsUnsecure = 0
  AutoPerformsVerify = 1
  EnableProductionMode = 0
  EnableTargetPower = 0
  EraseType = 2
  ProductionDelay = 0x000001F4
  ProductionThreshold = 0x00000BB8
  ProgramSN = 0
  SerialFile = ""
  SNAddr = 0x00000000
  SNInc = 0x00000001
  SNLen = 0x00000008
  SNListFile = ""
  SNValue = 0x00000001
  TargetPowerDelay = 0x00000014
  VerifyType = 1
0707010000C075000081A4000003E8000000640000000168A04FE700001AED000000080000003000000000000000000000002B00000000platforms_examples/armcc/LPC1768/.cproject<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?>

<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
	<storageModule moduleId="org.eclipse.cdt.core.settings">
		<cconfiguration id="0.558628371">
			<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="0.558628371" moduleId="org.eclipse.cdt.core.settings" name="Default">
				<macros>
					<stringListMacro name="Path" type="VALUE_PATH_ANY_LIST">
						<value name="D:/eclipse/jre/bin/client"/>
						<value name="D:/eclipse/jre/bin"/>
						<value name="D:/eclipse/jre/lib/i386"/>
						<value name="C:\Program Files (x86)\AMD APP\bin\x86_64"/>
						<value name="C:\Program Files (x86)\AMD APP\bin\x86"/>
						<value name="C:\Windows\system32"/>
						<value name="C:\Windows"/>
						<value name="C:\Windows\System32\Wbem"/>
						<value name="C:\Windows\System32\WindowsPowerShell\v1.0\"/>
						<value name="C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static"/>
						<value name="C:\Program Files\Microsoft SQL Server\110\Tools\Binn\"/>
						<value name="C:\Program Files (x86)\Flash Magic"/>
						<value name="C:\SynaptiCAD\bin"/>
						<value name="C:\SynaptiCAD\bin\win32"/>
						<value name="C:\Program Files (x86)\AMD APP\bin\x86_64"/>
						<value name="C:\Program Files (x86)\AMD APP\bin\x86"/>
						<value name="C:\Windows\system32"/>
						<value name="C:\Windows"/>
						<value name="D:\eclipse"/>
						<value name="C:\cygwin\bin"/>
					</stringListMacro>
				</macros>
				<externalSettings/>
				<extensions>
					<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
					<extension id="org.eclipse.cdt.core.VCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
					<extension id="org.eclipse.cdt.ui.ARMCC Error Parser" point="org.eclipse.cdt.core.ErrorParser"/>
				</extensions>
			</storageModule>
			<storageModule moduleId="cdtBuildSystem" version="4.0.0">
				<configuration artifactName="${ProjName}" buildProperties="" description="" errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.ui.ARMCC Error Parser" id="0.558628371" name="Default" parent="org.eclipse.cdt.build.core.prefbase.cfg">
					<folderInfo id="0.558628371." name="/" resourcePath="">
						<toolChain errorParsers="" id="org.eclipse.cdt.build.core.prefbase.toolchain.30340466" name="No ToolChain" resourceTypeBasedDiscovery="false" superClass="org.eclipse.cdt.build.core.prefbase.toolchain">
							<targetPlatform binaryParser="org.eclipse.cdt.core.ELF" id="org.eclipse.cdt.build.core.prefbase.toolchain.30340466.1028665541" name=""/>
							<builder enableAutoBuild="true" errorParsers="org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.CWDLocator" id="org.eclipse.cdt.build.core.settings.default.builder.1550397938" keepEnvironmentInBuildfile="false" managedBuildOn="false" name="Gnu Make Builder" parallelBuildOn="true" parallelizationNumber="optimal" superClass="org.eclipse.cdt.build.core.settings.default.builder"/>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.libs.65556822" name="holder for library settings" superClass="org.eclipse.cdt.build.core.settings.holder.libs"/>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.421105064" name="Assembly" superClass="org.eclipse.cdt.build.core.settings.holder">
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.2145778233" languageId="org.eclipse.cdt.core.assembly" languageName="Assembly" sourceContentType="org.eclipse.cdt.core.asmSource" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.1714014332" name="GNU C++" superClass="org.eclipse.cdt.build.core.settings.holder">
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.724975793" languageId="org.eclipse.cdt.core.g++" languageName="GNU C++" sourceContentType="org.eclipse.cdt.core.cxxSource,org.eclipse.cdt.core.cxxHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
							<tool errorParsers="org.eclipse.cdt.core.VCErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GASErrorParser;org.eclipse.cdt.core.GLDErrorParser" id="org.eclipse.cdt.build.core.settings.holder.426578454" name="GNU C" superClass="org.eclipse.cdt.build.core.settings.holder">
								<inputType id="org.eclipse.cdt.build.core.settings.holder.inType.1107299094" languageId="org.eclipse.cdt.core.gcc" languageName="GNU C" sourceContentType="org.eclipse.cdt.core.cSource,org.eclipse.cdt.core.cHeader" superClass="org.eclipse.cdt.build.core.settings.holder.inType"/>
							</tool>
						</toolChain>
					</folderInfo>
				</configuration>
			</storageModule>
			<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
		</cconfiguration>
	</storageModule>
	<storageModule moduleId="cdtBuildSystem" version="4.0.0">
		<project id="cpputest_example.null.375401268" name="cpputest_example"/>
	</storageModule>
	<storageModule moduleId="scannerConfiguration">
		<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
		<scannerConfigBuildInfo instanceId="0.558628371">
			<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
		</scannerConfigBuildInfo>
	</storageModule>
	<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
	<storageModule moduleId="refreshScope" versionNumber="2">
		<configuration configurationName="Default">
			<resource resourceType="PROJECT" workspacePath="/cpputest_example"/>
		</configuration>
	</storageModule>
	<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
</cproject>
0707010000C079000081A4000003E8000000640000000168A04FE7000003E7000000080000003000000000000000000000002900000000platforms_examples/armcc/LPC1768/ROM.sct#! armcc -E
; code upper need to use #define 

;-------------------------------------------------------------------------------------
;   Keil scatter loading file
; For LPC1768
;-------------------------------------------------------------------------------------

#define FLASH_START (0x00000000)
#define FLASH_END   (0x00080000)
#define FLASH_SIZE  (FLASH_END-FLASH_START)

; Internal SRAM
#define RAM1_START 0x10000000
#define RAM1_END   0x10008000
#define RAM1_SIZE  (RAM1_END-RAM1_START)

; Internal SRAM for peripherial DMA
#define RAM2_START 0x2007C000
#define RAM2_END   0x20084000
#define RAM2_SIZE  (RAM2_END-RAM2_START)

; Load region for main program
LR1   FLASH_START  FLASH_SIZE {
   ER1 FLASH_START {
        *.o(RESET, +First)
        *.o(InRoot$$Sections)
        *.o(+RO)
   }
   ER2 RAM1_START RAM1_SIZE {
    *.o(+RW +ZI)
   }
   ER3 RAM2_START RAM2_SIZE {
    *.o(HEAP)
    *.o(STACK)
   }
}



/*----------------------------------------------------------------------------*/

0707010000C076000081A4000003E8000000640000000168A04FE700000301000000080000003000000000000000000000002A00000000platforms_examples/armcc/LPC1768/.project<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
	<name>cpputest_example</name>
	<comment></comment>
	<projects>
	</projects>
	<buildSpec>
		<buildCommand>
			<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
			<arguments>
			</arguments>
		</buildCommand>
		<buildCommand>
			<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
			<triggers>full,incremental,</triggers>
			<arguments>
			</arguments>
		</buildCommand>
	</buildSpec>
	<natures>
		<nature>org.eclipse.cdt.core.cnature</nature>
		<nature>org.eclipse.cdt.core.ccnature</nature>
		<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
		<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
	</natures>
</projectDescription>
0707010000C07D000081A4000003E8000000640000000168A04FE700000862000000080000003000000000000000000000003000000000platforms_examples/armcc/LPC1768/tests/main.cpp/*
 * Copyright (c) 2007, Michael Feathers, James Grenning and Bas Vodde
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *     * Redistributions of source code must retain the above copyright
 *       notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright
 *       notice, this list of conditions and the following disclaimer in the
 *       documentation and/or other materials provided with the distribution.
 *     * Neither the name of the <organization> nor the
 *       names of its contributors may be used to endorse or promote products
 *       derived from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE EARLIER MENTIONED AUTHORS ''AS IS'' AND ANY
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED. IN NO EVENT SHALL <copyright holder> BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

#include "CppUTest/CommandLineTestRunner.h"
#include <iostream>
#include <cstdint>

extern "C" void _clock_init(void);
extern std::uint32_t SystemCoreClock;
extern const std::uint32_t SystemCoreClock12;

int main(int ac, char** av)
{
    SystemCoreClock = SystemCoreClock12; /* if 12 MHz quartz is used; need to LPC_TIM3 measure */
    _clock_init(); /* secondary call for new SystemCoreClock freq; previous call worked with unknown value */

    std::cout << "Hello, World!\n";
    int result = RUN_ALL_TESTS(ac, av);

    return result;
}

07070100000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000B00000000TRAILER!!!
openSUSE Build Service is sponsored by