-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathCreating_sampleProject_usingFreeRTOS_source
More file actions
165 lines (93 loc) · 5.55 KB
/
Creating_sampleProject_usingFreeRTOS_source
File metadata and controls
165 lines (93 loc) · 5.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
How to create a sample Project Using Demo Project Provided in FreeRTOS source .
-----------------------------------------------------------------------------------
we do it in two ways one is crude way and smart way.
we need to do both the approaches .
Crude way : helps to understand the FreeRTOS source structure.
and purpose and structure of Demo codes in FreeRTOS source( provided for quick start)
and to get understanding in more generic way : irrespective of IDE, compiler,Platform.
Smart way: Doing the things fast using IDE (here iam using LPCexresso from nxp)
Crude way :
--------------------------
FreeRTOSv10.0.0.zip --->extract FreeRTOSv10.0.0
It has two directories : FreeRTOS and FreeRTOS-Plus
FreeRTOS ---> has FreeRTOS kernel source common to all the platforms
port files specific to each Platform
and demo - for each of Platform-compiler-combination
FreeRTOS-Plus--->
Creating a Project using Demo project Available in FreeRTOS source:
create Directory - Project1_cortexM0_LPC11x
copy contents of FreeRTOS directory contents into Project1_cortexM0_LPC11x
dir Project1_cortexM0_LPC11x ---> Demo , License, Source, + other readme files
Demo --> contains demo for each combination of
Source -> contains FreeRTOS kernel files and port directories for each platform.
remove License and other readme files (optional)
In the dir Project1_cortexM0_LPC11x\Demo:
keep common and CORTEX_M0_LPC1114_LPCXpresso directories - which are the rwquired platform
remove all other demo directories.
In the Project1_cortexM0_LPC11x\Source :
keep freertos kernel files
In the port layer -Project1_cortexM0_LPC11x\Source\portable:
keep common , Memmang,required compiler + arch- combination , + any other required directory
like Tasking which is required for CM4F
remove all other directories
- in this case keep GCC, common, MemMang
In the CORTEX_M0_LPC1114_LPCXpresso -- there are two directories RTOSDemo and CMSISv2p00_LPC11xx
dir Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso\RTOSDemo --->
.cproject , .project , CreateProjectDirectoryStructure
dir Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso\CMSISv2p00_LPC11xx --->
.cproject , .project , src , inc, docs , history
As per history file:
CMSISv2p00_LPC11xx is a Library project created using
files as supplied in ARM's CMSIS 2.0
+ together with device/board specific files from NXP (which were
also part of CMSISv1p30_LPC11xx library project )
RTOSDemo is sample Project - which is provided for user.
It has source files for project and project files , script to create Project directory structure.
The Source directory Application files + FreeRTOSConfig.h File + cr_startup_lpc11.c file
Application files -->
FreeRTOSConfig.h File -->
cr_startup_lpc11.c file --->
CreateProjectDirectoryStructure -->
It creates the directory:FreeRTOS_Source under Application Project source:RTOSDemo\Source
Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso\RTOSDemo\Source
copies FreeRTOS source files from Project1_cortexM0_LPC11x\Source : which has FreeRTOS kerenel Files and port Files
# Now we are ready with Minimal FreeRTos Source that is required for our Platform.
Summary:
Project1_cortexM0_LPC11x ---> Letus call this project preperation directory. This is not our Project directory.
Here we have two directories Source and Demo
Source -- has Minimal FreeRTOS source which we want to copy into our Project.
Demo --- has demo code for our platform code and common demo code for all Platforms.
Now we are going to create a Project under the dir: Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso
It has two directories :
CMSISv2p00_LPC11xx --> this is going to be the Project directory for CIMSIS Library
RTOSDemo ---> this is going to be our Application project.
by selecting RTOSDemo as Working
Let us rename our Application Project as Webserver.
Remove all the contents of Dir: Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso\Webserver
Remove all the contents of CMSISv2p00_LPC11xx
Launch LPCexpresso IDE.
select the workspace as : Project1_cortexM0_LPC11x\Demo\CORTEX_M0_LPC1114_LPCXpresso
C:\Users\suvelise\Documents\3_Embedded_rel\ARM_cortex_M4\DSP_nxp_projects\FreeRTOS\FreeRTOSv10.0.0.exe
we need to run the script CreateProjectDirectoryStructure at this point .
without running scrit-if we Import project It complains Later and asks to run the script .
if we don't run the script :CreateProjectDirectoryStructure here ?? go ahed and Launch lpcexpresso
---------------------------------------------------------------------
#######################################################################################################################
Smart Way:
----------
create dir : Creation_of_sample_project
FreeRTOSv10.0.0.zip ---> extract FreeRTOSv10.0.0
Run cmd from windows:
cd Creation_of_sample_project\FreeRTOSv10.0.0\FreeRTOS\Demo\CORTEX_M0_LPC1114_LPCXpresso\RTOSDemo
run the script CreateProjectDirectoryStructure
This copies FreeRTOS source into Application .
create a directory Webserver_workspace in Creation_of_sample_project.
Launch LPCexpresso IDE.
select workspace as : Creation_of_sample_project\Webserver_workspace
Import Projects ---> project directory
selct root directory as : Creation_of_sample_project\FreeRTOSv10.0.0\FreeRTOS\Demo\CORTEX_M0_LPC1114_LPCXpresso
and import the projects CMSISv2p00_LPC11xx and RTOSDemo .
now rename RTOSDemo as Webserver.
clean CMSISv2p00_LPC11xx and Build
clean RTOSDemo and Build.
export project to Archive(zip) ---> Creation_of_sample_project\webserver.zip