Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
a690c144
Commit
a690c144
authored
9 years ago
by
Deomid Ryabkov
Committed by
rojer
9 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make CC3200 example work with XCC3200HZ
PUBLISHED_FROM=42b188c5ae85742681266fee21ec0b0472912743
parent
d742b678
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
8 deletions
+16
-8
Makefile.build
examples/CC3200/Makefile.build
+4
-2
cc3200_example.ld
examples/CC3200/cc3200_example.ld
+4
-2
main.c
examples/CC3200/main.c
+8
-4
No files found.
examples/CC3200/Makefile.build
View file @
a690c144
...
...
@@ -40,7 +40,9 @@ MONGOOSE_FEATURES = \
-DMG_MAX_HTTP_SEND_MBUF
=
1024
\
-DMG_NO_BSD_SOCKETS
SDK_FLAGS
=
-DTARGET_IS_CC3200
-DUSE_FREERTOS
-DSL_PLATFORM_MULTI_THREADED
SDK_FLAGS
=
-DUSE_FREERTOS
-DSL_PLATFORM_MULTI_THREADED
# -DTARGET_IS_CC3200 would reduce code size by using functions in ROM
# but then the code won't work on pre-release chips (XCC3200HZ).
CFLAGS
+=
-Os
-Wall
-Werror
\
$(SDK_FLAGS)
-DCS_PLATFORM
=
4
-DCC3200_FS_SLFS
\
...
...
@@ -92,7 +94,7 @@ CC3200_PLATFORM_SRCS = cc3200_fs.c cc3200_fs_slfs.c cc3200_libc.c cc3200_socket.
VPATH
+=
$(COMMON_PATH)
/platforms/cc3200
FREERTOS_SRCS
=
timers.c list.c queue.c tasks.c port.c heap_3.c osi_freertos.c
DRIVER_SRCS
=
cpu.c gpio
_if
.c i2c_if.c interrupt.c pin.c prcm.c spi.c uart.c udma.c utils.c
DRIVER_SRCS
=
cpu.c gpio
.c gpio_if.c i2c
.c i2c_if.c interrupt.c pin.c prcm.c spi.c uart.c udma.c utils.c
SL_SRCS
=
socket.c wlan.c driver.c device.c netapp.c netcfg.c cc_pal.c fs.c
SDK_SRCS
=
startup_gcc.c
$(FREERTOS_SRCS)
$(DRIVER_SRCS)
$(SL_SRCS)
IPATH
+=
$(SDK_PATH)
$(SDK_PATH)
/inc
$(SDK_PATH)
/driverlib
\
...
...
This diff is collapsed.
Click to expand it.
examples/CC3200/cc3200_example.ld
View file @
a690c144
...
...
@@ -41,8 +41,10 @@ HEAP_SIZE = 0xB000;
MEMORY
{
/* SRAM size of 240KB for cc3200 ES 1.33 device onward */
SRAM (rwx) : ORIGIN = 0x20004000, LENGTH = 0x3C000
/* SRAM size of 240KB (0x3C000) for cc3200 ES 1.33 device onward,
* 176KB (0x2C000) for XCC3200HZ (pre-release device).
* We use the latter for maximum compatibility. */
SRAM (rwx) : ORIGIN = 0x20004000, LENGTH = 0x2C000
}
SECTIONS
...
...
This diff is collapsed.
Click to expand it.
examples/CC3200/main.c
View file @
a690c144
...
...
@@ -91,16 +91,20 @@ static void ev_handler(struct mg_connection *nc, int ev, void *p) {
switch
(
ev
)
{
case
MG_EV_ACCEPT
:
{
char
addr
[
32
];
mg_sock_addr_to_str
(
&
nc
->
sa
,
addr
,
sizeof
(
addr
),
MG_SOCK_STRINGIFY_IP
|
MG_SOCK_STRINGIFY_PORT
);
mg_conn_addr_to_str
(
nc
,
addr
,
sizeof
(
addr
),
MG_SOCK_STRINGIFY_REMOTE
|
MG_SOCK_STRINGIFY_IP
|
MG_SOCK_STRINGIFY_PORT
);
LOG
(
LL_INFO
,
(
"%p conn from %s"
,
nc
,
addr
));
break
;
}
case
MG_EV_HTTP_REQUEST
:
{
char
addr
[
32
];
struct
http_message
*
hm
=
(
struct
http_message
*
)
p
;
mg_sock_addr_to_str
(
&
nc
->
sa
,
addr
,
sizeof
(
addr
),
MG_SOCK_STRINGIFY_IP
|
MG_SOCK_STRINGIFY_PORT
);
mg_conn_addr_to_str
(
nc
,
addr
,
sizeof
(
addr
),
MG_SOCK_STRINGIFY_REMOTE
|
MG_SOCK_STRINGIFY_IP
|
MG_SOCK_STRINGIFY_PORT
);
LOG
(
LL_INFO
,
(
"HTTP request from %s: %.*s %.*s"
,
addr
,
(
int
)
hm
->
method
.
len
,
hm
->
method
.
p
,
(
int
)
hm
->
uri
.
len
,
hm
->
uri
.
p
));
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment