mbed library sources
Fork of mbed-src by
Revision 158:3121b9889f7b, committed 2014-04-11
- Comitter:
- mbed_official
- Date:
- Fri Apr 11 17:30:07 2014 +0100
- Parent:
- 157:90e3acc479a2
- Child:
- 159:3b23f6d9ecb9
- Commit message:
- Synchronized with git revision efbbb2f3070ba66a206581185b033ef0343242d7
Full URL: https://github.com/mbedmicro/mbed/commit/efbbb2f3070ba66a206581185b033ef0343242d7/
Conflicts:
libraries/mbed/targets/hal/TARGET_STM/TARGET_NUCLEO_F030R8/gpio_irq_api.c
libraries/mbed/targets/hal/TARGET_STM/TARGET_NUCLEO_F103RB/gpio_irq_api.c
libraries/mbed/targets/hal/TARGET_STM/TARGET_NUCLEO_L152RE/gpio_irq_api.c
Changed in this revision
--- a/common/exit.c Fri Apr 11 17:15:06 2014 +0100 +++ b/common/exit.c Fri Apr 11 17:30:07 2014 +0100 @@ -15,6 +15,9 @@ */ #include "semihost_api.h" #include "mbed_interface.h" +#if DEVICE_STDIO_MESSAGES +#include <stdio.h> +#endif #ifdef TOOLCHAIN_GCC_CW // TODO: Ideally, we would like to define directly "_ExitProcess" @@ -23,6 +26,11 @@ void exit(int return_code) { #endif +#if DEVICE_STDIO_MESSAGES + fflush(stdout); + fflush(stderr); +#endif + #if DEVICE_SEMIHOST if (mbed_interface_connected()) { semihost_exit();
--- a/targets/hal/TARGET_Freescale/TARGET_K20D5M/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_K20D5M/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -108,7 +108,7 @@ break; default: - error("gpio_irq only supported on port A-E.\n"); + error("gpio_irq only supported on port A-E."); break; } NVIC_SetVector(irq_n, vector);
--- a/targets/hal/TARGET_Freescale/TARGET_K20D5M/serial_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_K20D5M/serial_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -126,7 +126,7 @@ // 8 data bits = 0 ... 9 data bits = 1 if ((data_bits < 8) || (data_bits > 9)) - error("Invalid number of bits (%d) in serial format, should be 8..9\r\n", data_bits); + error("Invalid number of bits (%d) in serial format, should be 8..9", data_bits); data_bits -= 8; @@ -136,13 +136,13 @@ case ParityOdd : parity_enable = 1; parity_select = 1; data_bits++; break; case ParityEven: parity_enable = 1; parity_select = 0; data_bits++; break; default: - error("Invalid serial parity setting\r\n"); + error("Invalid serial parity setting"); return; } // 1 stop bits = 0, 2 stop bits = 1 if ((stop_bits != 1) && (stop_bits != 2)) - error("Invalid stop bits specified\r\n"); + error("Invalid stop bits specified"); stop_bits -= 1; uint32_t m10 = 0; @@ -151,7 +151,7 @@ if (data_bits == 2) { // only uart0 supports 10 bit communication if (obj->index != 0) - error("Invalid number of bits (9) to be used with parity\r\n"); + error("Invalid number of bits (9) to be used with parity"); data_bits = 0; m10 = 1; }
--- a/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL05Z/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL05Z/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -99,7 +99,7 @@ break; default: - error("gpio_irq only supported on Port A and B\n"); + error("gpio_irq only supported on Port A and B"); break; } NVIC_SetVector(irq_n, vector);
--- a/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL25Z/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL25Z/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -89,7 +89,7 @@ break; default: - error("gpio_irq only supported on port A and D\n"); + error("gpio_irq only supported on port A and D"); break; } NVIC_SetVector(irq_n, vector);
--- a/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL46Z/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KLXX/TARGET_KL46Z/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -109,7 +109,7 @@ break; default: - error("gpio_irq only supported on port A,C and D\n"); + error("gpio_irq only supported on port A,C and D"); break; } NVIC_SetVector(irq_n, vector);
--- a/targets/hal/TARGET_Freescale/TARGET_KLXX/serial_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KLXX/serial_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -159,7 +159,7 @@ // TODO: Support other number of data bits (also in the write method!) if ((data_bits < 8) || (data_bits > 8)) { - error("Invalid number of bits (%d) in serial format, should be 8\r\n", data_bits); + error("Invalid number of bits (%d) in serial format, should be 8", data_bits); } uint8_t parity_enable, parity_select; @@ -168,13 +168,13 @@ case ParityOdd : parity_enable = 1; parity_select = 1; data_bits++; break; case ParityEven: parity_enable = 1; parity_select = 0; data_bits++; break; default: - error("Invalid serial parity setting\r\n"); + error("Invalid serial parity setting"); return; } // 1 stop bits = 0, 2 stop bits = 1 if ((stop_bits != 1) && (stop_bits != 2)) { - error("Invalid stop bits specified\r\n"); + error("Invalid stop bits specified"); } stop_bits -= 1;
--- a/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/device.h Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/device.h Fri Apr 11 17:30:07 2014 +0100 @@ -49,7 +49,7 @@ #define DEVICE_DEBUG_AWARENESS 0 -#define DEVICE_STDIO_MESSAGES 0 +#define DEVICE_STDIO_MESSAGES 1 #define DEVICE_ERROR_RED 1
--- a/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -109,7 +109,7 @@ break; default: - error("gpio_irq only supported on port A-E.\n"); + error("gpio_irq only supported on port A-E."); break; } NVIC_SetVector(irq_n, vector);
--- a/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/spi_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/TARGET_K64F/spi_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -42,8 +42,7 @@ {PTB16, SPI_1, 2}, {PTB22, SPI_2, 2}, {PTC6 , SPI_0, 2}, - {PTD2 , SPI_0, 2}, - {PTD6 , SPI_0, 7}, + {PTD6 , SPI_1, 7}, {NC , NC , 0} }; @@ -55,7 +54,6 @@ {PTB17, SPI_1, 2}, {PTB23, SPI_2, 2}, {PTC7 , SPI_0, 2}, - {PTD3 , SPI_0, 2}, {PTD7 , SPI_1, 7}, {NC , NC , 0} };
--- a/targets/hal/TARGET_NXP/TARGET_LPC176X/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_NXP/TARGET_LPC176X/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -89,7 +89,7 @@ // Interrupts available only on GPIO0 and GPIO2 if (obj->port != LPC_GPIO0_BASE && obj->port != LPC_GPIO2_BASE) { - error("pins on this port cannot generate interrupts\n"); + error("pins on this port cannot generate interrupts"); } // put us in the interrupt table
--- a/targets/hal/TARGET_NXP/TARGET_LPC23XX/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_NXP/TARGET_LPC23XX/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -80,7 +80,7 @@ // Interrupts available only on GPIO0 and GPIO2 if (obj->port != LPC_GPIO0_BASE && obj->port != LPC_GPIO2_BASE) { - error("pins on this port cannot generate interrupts\n"); + error("pins on this port cannot generate interrupts"); } // put us in the interrupt table
--- a/targets/hal/TARGET_NXP/TARGET_LPC408X/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_NXP/TARGET_LPC408X/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -102,7 +102,7 @@ // Interrupts available only on GPIO0 and GPIO2 if (obj->port != LPC_GPIO0_BASE && obj->port != LPC_GPIO2_BASE) { - error("pins on this port cannot generate interrupts\n"); + error("pins on this port cannot generate interrupts"); } // put us in the interrupt table
--- a/targets/hal/TARGET_STM/TARGET_DISCO_F051R8/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_DISCO_F051R8/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -104,7 +104,7 @@ irq_index = 2; break; default: - error("This pin is not supported\n"); + error("This pin is not supported"); return -1; }
--- a/targets/hal/TARGET_STM/TARGET_DISCO_F100RB/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_DISCO_F100RB/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -110,7 +110,7 @@ irq_index = 3; break; default: - error("This pin is not supported with InterruptIn.\n"); + error("This pin is not supported with InterruptIn."); return -1; }
--- a/targets/hal/TARGET_STM/TARGET_DISCO_F407VG/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_DISCO_F407VG/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -138,7 +138,7 @@ irq_index = 6; break; default: - error("InterruptIn error: pin not supported.\n"); + error("InterruptIn error: pin not supported."); return -1; }
--- a/targets/hal/TARGET_STM/TARGET_NUCLEO_F302R8/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_NUCLEO_F302R8/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -154,7 +154,7 @@ irq_index = 6; break; default: - error("This pin is not supported with InterruptIn.\n"); + error("This pin is not supported with InterruptIn."); return -1; }
--- a/targets/hal/TARGET_STM/TARGET_NUCLEO_F401RE/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_NUCLEO_F401RE/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -138,7 +138,7 @@ irq_index = 6; break; default: - error("InterruptIn error: pin not supported.\n"); + error("InterruptIn error: pin not supported."); return -1; }
--- a/targets/hal/TARGET_STM/TARGET_STM32F3XX/gpio_irq_api.c Fri Apr 11 17:15:06 2014 +0100 +++ b/targets/hal/TARGET_STM/TARGET_STM32F3XX/gpio_irq_api.c Fri Apr 11 17:30:07 2014 +0100 @@ -154,7 +154,7 @@ irq_index = 6; break; default: - error("This pin is not supported with InterruptIn.\n"); + error("This pin is not supported with InterruptIn."); return -1; }