Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision

Target

Select target project
  • isc2/pro/labo
1 result
Select Git revision
Show changes
Commits on Source (2)
Showing
with 3098 additions and 4 deletions
......@@ -92,8 +92,12 @@ err_ex2:
*****************************************************/
.thumb_func
funcexo3:
// push {r4}
// c in r4
// mov r
bx lr
// bx lr
......@@ -105,6 +109,28 @@ funcexo3:
*****************************************************/
.thumb_func
funcexo4:
subs r0, #1
bne rcall
mov r0, #1
// add sp, #8
bx lr
rcall:
push {r0, lr}
bl funcexo4
pop {r0, lr}
add r0, r0
bx lr
exit:
pop {r0, lr}
add r0, r0
bx lr
/*funcexo4:
mov r1, r0
push {r0, r1, lr}
bl lhs_fact
......@@ -145,7 +171,7 @@ rcall:
pop {r0, r1, lr}
add r0, r1
bx lr
bx lr*/
//.weak add_sat
......
......@@ -22,9 +22,10 @@ typedef struct {
void funcexo1(uint32_t, uint32_t, uint32_t, uint32_t, uint32_t *);
uint32_t funcexo2(uint32_t a, uint32_t b, uint32_t c, uint32_t d);
int funcexo3(numbers_t s);
int funcexo4(int n);
/* global variables */
int exo = 2; // change this number with the exercise number you want to test;
int exo = 4; // change this number with the exercise number you want to test;
int main(void)
{
......@@ -41,13 +42,17 @@ int main(void)
res=funcexo2(0x10000, 0x10005, 6,7); // doit retourner 0
res=funcexo2(0xF000, 0x8805, 0x8700,0xF760); // doit retourner 0
break;
default:
case 3:
s.a=5; s.b=-3; s.c=-1; s.d=10; s.e=3;
res_ref=s.a+s.b+s.c+s.d+s.e;
res=funcexo3(s);
if (res!=res_ref)
while(1); // error
break;
default:
res=funcexo4(4); // doit retourner 5
res=funcexo4(1); // doit retourner 1
break;
}
return 0;
......
This diff is collapsed.
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>CMSISv2p00_LPC17xx</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
<triggers>clean,full,incremental,</triggers>
<arguments>
<dictionary>
<key>?name?</key>
<value></value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.append_environment</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.autoBuildTarget</key>
<value>all</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildArguments</key>
<value></value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildCommand</key>
<value>make</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.buildLocation</key>
<value>${workspace_loc:/CMSISv2p00_LPC17xx/Debug}</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.cleanBuildTarget</key>
<value>clean</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.contents</key>
<value>org.eclipse.cdt.make.core.activeConfigSettings</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableAutoBuild</key>
<value>false</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableCleanBuild</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.enableFullBuild</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.fullBuildTarget</key>
<value>all</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.stopOnError</key>
<value>true</value>
</dictionary>
<dictionary>
<key>org.eclipse.cdt.make.core.useDefaultBuildCmd</key>
<value>true</value>
</dictionary>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
<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>
</natures>
</projectDescription>
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project>
<configuration id="com.crt.advproject.config.lib.debug.1814355025" name="Debug">
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
<provider copy-of="extension" id="com.crt.advproject.GCCBuildCommandParser"/>
<provider class="com.crt.advproject.specs.MCUGCCBuiltinSpecsDetector" console="false" env-hash="227759477465743802" id="com.crt.advproject.GCCBuildSpecCompilerParser" keep-relative-paths="false" name="MCU GCC Built-in Compiler Parser" parameter="${COMMAND} ${FLAGS} -E -P -v -dD &quot;${INPUTS}&quot;" prefer-non-shared="true">
<language-scope id="org.eclipse.cdt.core.gcc"/>
<language-scope id="org.eclipse.cdt.core.g++"/>
</provider>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
</extension>
</configuration>
<configuration id="com.crt.advproject.config.lib.release.1079171862" name="Release">
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
<provider copy-of="extension" id="com.crt.advproject.GCCBuildCommandParser"/>
<provider class="com.crt.advproject.specs.MCUGCCBuiltinSpecsDetector" console="false" env-hash="234512289041408538" id="com.crt.advproject.GCCBuildSpecCompilerParser" keep-relative-paths="false" name="MCU GCC Built-in Compiler Parser" parameter="${COMMAND} ${FLAGS} -E -P -v -dD &quot;${INPUTS}&quot;" prefer-non-shared="true">
<language-scope id="org.eclipse.cdt.core.gcc"/>
<language-scope id="org.eclipse.cdt.core.g++"/>
</provider>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
</extension>
</configuration>
</project>
\ No newline at end of file
eclipse.preferences.version=1
encoding/<project>=UTF-8
File added
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include src/subdir.mk
-include subdir.mk
-include objects.mk
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(strip $(C_DEPS)),)
-include $(C_DEPS)
endif
endif
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: libCMSISv2p00_LPC17xx.a
# Tool invocations
libCMSISv2p00_LPC17xx.a: $(OBJS) $(USER_OBJS)
@echo 'Building target: $@'
@echo 'Invoking: MCU Archiver'
arm-none-eabi-ar -r "libCMSISv2p00_LPC17xx.a" $(OBJS) $(USER_OBJS) $(LIBS)
@echo 'Finished building target: $@'
@echo ' '
$(MAKE) --no-print-directory post-build
# Other Targets
clean:
-$(RM) $(OBJS)$(ARCHIVES)$(C_DEPS) libCMSISv2p00_LPC17xx.a
-@echo ' '
post-build:
-@echo 'Performing post-build steps'
-arm-none-eabi-size libCMSISv2p00_LPC17xx.a ; # arm-none-eabi-objdump -h -S libCMSISv2p00_LPC17xx.a >libCMSISv2p00_LPC17xx.lss
-@echo ' '
.PHONY: all clean dependents
.SECONDARY: post-build
-include ../makefile.targets
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
USER_OBJS :=
LIBS :=
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
OBJ_SRCS :=
S_SRCS :=
ASM_SRCS :=
C_SRCS :=
S_UPPER_SRCS :=
O_SRCS :=
OBJS :=
ARCHIVES :=
C_DEPS :=
# Every subdirectory with source files must be described here
SUBDIRS := \
src \
src/core_cm3.o src/core_cm3.d: ../src/core_cm3.c
File added
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Add inputs and outputs from these tool invocations to the build variables
C_SRCS += \
../src/core_cm3.c \
../src/system_LPC17xx.c
OBJS += \
./src/core_cm3.o \
./src/system_LPC17xx.o
C_DEPS += \
./src/core_cm3.d \
./src/system_LPC17xx.d
# Each subdirectory must supply rules for building sources it contributes
src/%.o: ../src/%.c
@echo 'Building file: $<'
@echo 'Invoking: MCU C Compiler'
arm-none-eabi-gcc -D__REDLIB__ -DDEBUG -D__CODE_RED -I../inc -O0 -Os -g3 -Wall -c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -mcpu=cortex-m3 -mthumb -D__REDLIB__ -specs=redlib.specs -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@:%.o=%.o)" -MT"$(@:%.o=%.d)" -o "$@" "$<"
@echo 'Finished building: $<'
@echo ' '
src/system_LPC17xx.o src/system_LPC17xx.d: ../src/system_LPC17xx.c \
../inc/LPC17xx.h ../inc/core_cm3.h ../inc/core_cmInstr.h \
../inc/core_cmFunc.h ../inc/system_LPC17xx.h
../inc/LPC17xx.h:
../inc/core_cm3.h:
../inc/core_cmInstr.h:
../inc/core_cmFunc.h:
../inc/system_LPC17xx.h:
File added
File added
CMSIS : Cortex Microcontroller Software Interface Standard
==========================================================
Introduction
~~~~~~~~~~~~
CMSIS defines for a Cortex-M Microcontroller System:
* A common way to access peripheral registers and a
common way to define exception vectors.
* The register names of the Core Peripherals and the
names of the Core Exception Vectors.
* An device independent interface for RTOS Kernels
including a debug channel.
By using CMSIS compliant software components, the user can
easier re-use template code. CMSIS is intended to enable the
combination of software components from multiple middleware
vendors.
This project contains appropriate files for this MCU family
taken from CMSIS. A full copy of the CMSIS files, together
with additional information on CMSIS can be found at:
http://www.onarm.com/
http://www.arm.com/
Documentation
~~~~~~~~~~~~~
The standard CMSIS documentation can be found within the
Code Red IDE help system, via:
Help -> Help Contents -> Code Red Product Documentation -> CMSIS
More information on the use of CMSIS within the Code Red IDE
can be found in the Support area of the Code Red website at
http://www.code-red-tech.com/
At the time of writing, the CMSIS FAQ can be found directly
at:
http://support.code-red-tech.com/CodeRedWiki/Support4CMSIS
History of updates to CMSISv2p00_LPC17xx
========================================
7 March 2011
------------
LPC17xx CMSIS 2.0 library project using ARM
Cortex-M3 CMSIS files as supplied in ARM's CMSIS 2.0
December 2010 release, together with device/board
specific files from NXP (as previously supplied in
CMSISv1p30_LPC17xx library project, dated 24 Aug 2010).
Note files are built -Os for both Debug and Release
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.