summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2016-05-27 14:28:15 +0100
committerDamien George <damien.p.george@gmail.com>2016-06-28 11:28:50 +0100
commit9b1c1262dc70cfb6b5cf5d27e3e3d8e41b5a4901 (patch)
tree1da848cac21240d814fcfa6df8a59dacfcd3ac73
parent5c0fc73f33dde64d7e56f3f1ed85eb44957c804e (diff)
downloadmicropython-9b1c1262dc70cfb6b5cf5d27e3e3d8e41b5a4901.tar.gz
micropython-9b1c1262dc70cfb6b5cf5d27e3e3d8e41b5a4901.zip
cc3200: Define our own FreeRTOS heap so it can go in a special segment.
-rw-r--r--cc3200/FreeRTOS/FreeRTOSConfig.h3
-rw-r--r--cc3200/main.c3
2 files changed, 6 insertions, 0 deletions
diff --git a/cc3200/FreeRTOS/FreeRTOSConfig.h b/cc3200/FreeRTOS/FreeRTOSConfig.h
index 2e9a514381..27ba880f62 100644
--- a/cc3200/FreeRTOS/FreeRTOSConfig.h
+++ b/cc3200/FreeRTOS/FreeRTOSConfig.h
@@ -151,4 +151,7 @@ See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */
version. */
#define configUSE_PORT_OPTIMISED_TASK_SELECTION 1
+/* We provide a definition of ucHeap so it can go in a special segment. */
+#define configAPPLICATION_ALLOCATED_HEAP 1
+
#endif /* FREERTOS_CONFIG_H */
diff --git a/cc3200/main.c b/cc3200/main.c
index 78b4e3161c..4a6f6172bf 100644
--- a/cc3200/main.c
+++ b/cc3200/main.c
@@ -56,6 +56,9 @@
OsiTaskHandle mpTaskHandle;
#endif
+// This is the FreeRTOS heap, defined here so we can put it in a special segment
+uint8_t ucHeap[ configTOTAL_HEAP_SIZE ] __attribute__ ((section (".rtos_heap"))) __attribute__((aligned (8)));
+
/******************************************************************************
DEFINE PUBLIC FUNCTIONS
******************************************************************************/