summaryrefslogtreecommitdiffstatshomepage
path: root/cc3200
diff options
context:
space:
mode:
authordanicampora <danicampora@gmail.com>2015-02-14 16:35:29 +0100
committerdanicampora <danicampora@gmail.com>2015-02-20 16:40:06 +0100
commite1dfc4417817cbefb31e1df3ac27de4de94b3f30 (patch)
treeb485212986f0c14a027489b2f1f06b2e091515a6 /cc3200
parent690458300b409423212ac15ab99d0891c5b702a5 (diff)
downloadmicropython-e1dfc4417817cbefb31e1df3ac27de4de94b3f30.tar.gz
micropython-e1dfc4417817cbefb31e1df3ac27de4de94b3f30.zip
cc3200: Disable FreeRTOS asserts. Optimize more files if BTYPE=debug.
Diffstat (limited to 'cc3200')
-rw-r--r--cc3200/FreeRTOS/FreeRTOSConfig.h7
-rw-r--r--cc3200/application.lds4
-rw-r--r--cc3200/application.mk5
-rw-r--r--cc3200/hal/cc3200_hal.c2
-rw-r--r--cc3200/mods/pybuart.c4
5 files changed, 10 insertions, 12 deletions
diff --git a/cc3200/FreeRTOS/FreeRTOSConfig.h b/cc3200/FreeRTOS/FreeRTOSConfig.h
index 072ab93946..0298031ca4 100644
--- a/cc3200/FreeRTOS/FreeRTOSConfig.h
+++ b/cc3200/FreeRTOS/FreeRTOSConfig.h
@@ -85,7 +85,7 @@
#define configTICK_RATE_HZ ( ( TickType_t ) 1000 )
#define configMINIMAL_STACK_SIZE ( ( unsigned short ) 64 )
#define configTOTAL_HEAP_SIZE ( ( size_t ) ( 16384 ) )
-#define configMAX_TASK_NAME_LEN ( 12 )
+#define configMAX_TASK_NAME_LEN ( 8 )
#define configUSE_TRACE_FACILITY 0
#define configUSE_16_BIT_TICKS 0
#define configIDLE_SHOULD_YIELD 1
@@ -151,9 +151,4 @@ See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */
version. */
#define configUSE_PORT_OPTIMISED_TASK_SELECTION 1
-#ifdef DEBUG
-#include "debug.h"
-#define configASSERT( x ) ASSERT( x )
-#endif
-
#endif /* FREERTOS_CONFIG_H */
diff --git a/cc3200/application.lds b/cc3200/application.lds
index 553b4400be..46b29e99ee 100644
--- a/cc3200/application.lds
+++ b/cc3200/application.lds
@@ -62,8 +62,8 @@
* THE SOFTWARE.
*/
-__stack_size__ = 1024; /* interrupts are handled using this stack */
-__min_heap_size__ = 4K;
+__stack_size__ = 1K; /* interrupts are handled using this stack */
+__min_heap_size__ = 6K;
__rtos_heap_size = 16K;
MEMORY
diff --git a/cc3200/application.mk b/cc3200/application.mk
index 73c84efa46..fa72c64b38 100644
--- a/cc3200/application.mk
+++ b/cc3200/application.mk
@@ -186,6 +186,9 @@ $(BUILD)/stmhal/%.o: CFLAGS += -Os
$(BUILD)/telnet/%.o: CFLAGS += -Os
$(BUILD)/util/%.o: CFLAGS += -Os
$(BUILD)/pins.o: CFLAGS += -Os
+$(BUILD)/main.o: CFLAGS += -Os
+$(BUILD)/mptask.o: CFLAGS += -Os
+$(BUILD)/servertask.o: CFLAGS += -Os
else
$(error Invalid BTYPE specified)
endif
@@ -216,7 +219,7 @@ PREFIX_FILE = boards/cc3200_prefix.c
GEN_PINS_SRC = $(BUILD)/pins.c
GEN_PINS_HDR = $(HEADER_BUILD)/pins.h
GEN_PINS_QSTR = $(BUILD)/pins_qstr.h
-
+
# Making OBJ use an order-only dependency on the generated pins.h file
# has the side effect of making the pins.h file before we actually compile
# any of the objects. The normal dependency generation will deal with the
diff --git a/cc3200/hal/cc3200_hal.c b/cc3200/hal/cc3200_hal.c
index 1e97324ea8..75b0dca033 100644
--- a/cc3200/hal/cc3200_hal.c
+++ b/cc3200/hal/cc3200_hal.c
@@ -88,7 +88,7 @@ void HAL_SystemInit (void) {
// in the case of a release image, these steps are already performed by
// the bootloader so we can skip it and gain some code space
-#ifndef NDEBUG
+#ifdef DEBUG
MAP_IntMasterEnable();
PRCMCC3200MCUInit();
#endif
diff --git a/cc3200/mods/pybuart.c b/cc3200/mods/pybuart.c
index 21daecf9f9..5c44c3c9df 100644
--- a/cc3200/mods/pybuart.c
+++ b/cc3200/mods/pybuart.c
@@ -145,13 +145,13 @@ bool uart_init2(pyb_uart_obj_t *self) {
self->reg = UARTA0_BASE;
uartPerh = PRCM_UARTA0;
MAP_UARTIntRegister(UARTA0_BASE, UART0IntHandler);
- MAP_IntPrioritySet(INT_UARTA0, INT_PRIORITY_LVL_7);
+ MAP_IntPrioritySet(INT_UARTA0, INT_PRIORITY_LVL_3);
break;
case PYB_UART_2:
self->reg = UARTA1_BASE;
uartPerh = PRCM_UARTA1;
MAP_UARTIntRegister(UARTA1_BASE, UART1IntHandler);
- MAP_IntPrioritySet(INT_UARTA1, INT_PRIORITY_LVL_7);
+ MAP_IntPrioritySet(INT_UARTA1, INT_PRIORITY_LVL_3);
break;
default:
return false;