diff --git a/boards/msba2-common/drivers/include/uart0.h b/boards/msba2-common/drivers/include/uart0.h
index b0861b2b15e8f0e7836201828007e7e2b3a916e8..9ed716a1dea12529331fb070a8864b714319440e 100644
--- a/boards/msba2-common/drivers/include/uart0.h
+++ b/boards/msba2-common/drivers/include/uart0.h
@@ -1,8 +1,6 @@
 #ifndef __UART0_H
 #define __UART0_H
 
-#define UART0_BUFSIZE 32
-
 extern int uart0_handler_pid;
 
 #endif /* __UART0_H */
diff --git a/cpu/lpc2387/include/cpu-conf.h b/cpu/lpc2387/include/cpu-conf.h
index 43ea15a52238852dc492a77ab094effa5c62e83a..afe924cf37e869f3dcea658258c6466e8ea28f8c 100644
--- a/cpu/lpc2387/include/cpu-conf.h
+++ b/cpu/lpc2387/include/cpu-conf.h
@@ -75,5 +75,10 @@ See the file LICENSE in the top level directory for more details.
 #define TRANSCEIVER_BUFFER_SIZE (10)
 #define RX_BUF_SIZE  (10)
 
+#ifndef UART0_BUFSIZE
+#define UART0_BUFSIZE                   (128)
+#endif
+
+
 /** @} */
 #endif /* CPUCONF_H_ */
diff --git a/cpu/mc1322x/include/cpu-conf.h b/cpu/mc1322x/include/cpu-conf.h
index b1c6f5210d4065a1bcb45b7312e1f6b75f0b75dc..57121f114eae7c5cbe8a89b09e16c81366a896da 100644
--- a/cpu/mc1322x/include/cpu-conf.h
+++ b/cpu/mc1322x/include/cpu-conf.h
@@ -59,5 +59,9 @@
 #define TRANSCEIVER_BUFFER_SIZE (10)
 #define RX_BUF_SIZE  (10)
 
+#ifndef UART0_BUFSIZE
+#define UART0_BUFSIZE                   (64)
+#endif
+
 /** @} */
 #endif /* CPUCONF_H_ */
diff --git a/cpu/msp430-common/include/cpu-conf.h b/cpu/msp430-common/include/cpu-conf.h
index 198223a768f9023b0a2a3b975352816f955e3456..4ffa783b638f2f199570ea74fc2c08aa92e3e679 100644
--- a/cpu/msp430-common/include/cpu-conf.h
+++ b/cpu/msp430-common/include/cpu-conf.h
@@ -28,6 +28,10 @@ See the file LICENSE in the top level directory for more details.
 
 #define RX_BUF_SIZE (3)
 #define TRANSCEIVER_BUFFER_SIZE (3)
+
+#ifndef UART0_BUFSIZE
+#define UART0_BUFSIZE                   (32)
+#endif
 /** @} */
 
 #endif /* CPUCONF_H_ */
diff --git a/cpu/native/include/cpu-conf.h b/cpu/native/include/cpu-conf.h
index c9153275dd292ee07bfe6c931129c009e5f58839..4ddd47a91ab6535a9430edb5480b0be65f3c2460 100644
--- a/cpu/native/include/cpu-conf.h
+++ b/cpu/native/include/cpu-conf.h
@@ -48,6 +48,11 @@
 #define NATIVE_ISR_STACKSIZE            (8192)
 #endif /* OS */
 
+#ifdef UART0_BUFSIZE
+#undef UART0_BUFSIZE
+#endif
+#define UART0_BUFSIZE                   (128)
+
 /* for nativenet */
 #define NATIVE_ETH_PROTO 0x1234
 
diff --git a/sys/include/board_uart0.h b/sys/include/board_uart0.h
index 734950da059d5c51c48711cb5cf3a88a6641b2a0..e7af70bd571f425bdac4ec372d1d6db312ccebc4 100644
--- a/sys/include/board_uart0.h
+++ b/sys/include/board_uart0.h
@@ -12,6 +12,8 @@
 #ifndef __BOARD_UART0_H
 #define __BOARD_UART0_H
 
+#include "cpu-conf.h"   /* To give user access to UART0_BUFSIZE */
+
 extern int uart0_handler_pid;
 
 void board_uart0_init(void);
diff --git a/sys/include/shell.h b/sys/include/shell.h
index 0b3cf13aee6e5390cb026c622ec7d4e3f7be0816..0e225204469b17f6569a59f6e73ebd38fc1dbc86 100644
--- a/sys/include/shell.h
+++ b/sys/include/shell.h
@@ -20,6 +20,7 @@
 
 #ifndef __SHELL_H
 #define __SHELL_H
+#include <stdint.h>
 
 typedef struct shell_command_t {
     char *name;
@@ -29,20 +30,21 @@ typedef struct shell_command_t {
 
 typedef struct shell_t {
     const shell_command_t *command_list;
+    uint16_t shell_buffer_size;
     int (*readchar)(void);
     void (*put_char)(int);
 } shell_t;
 
-#define SHELL_BUFFER_SIZE (127)
-
 /**
  * @brief Initialize a shell object
  * @param shell Pointer to preallocated shell object
  * @param shell_commands Pointer to shell command structure. See test_shell project for example.
+ * @param shell_buffer_size The size of the shell buffer.
  * @param read_char Pointer to input device read function. Should return exactly one byte or block.
  * @param put_char Pointer to output funtion. currently unused, shell code will use printf.
  */
-void shell_init(shell_t *shell,  /*@null@*/ const shell_command_t *shell_commands, int(*read_char)(void), void (*put_char)(int));
+void shell_init(shell_t *shell,  /*@null@*/ const shell_command_t *shell_commands,
+                uint16_t shell_buffer_size, int(*read_char)(void), void (*put_char)(int));
 
 /**
  * @brief Endless loop that waits for command and executes handler.
diff --git a/sys/shell/shell.c b/sys/shell/shell.c
index 2878208c6934618e624ba60cdb2cad075477421a..a70122c899477bb009da239d6106baf7aa78400a 100644
--- a/sys/shell/shell.c
+++ b/sys/shell/shell.c
@@ -1,5 +1,5 @@
 /**
- * Shell interpreter 
+ * Shell interpreter
  *
  * Copyright (C) 2009, Freie Universitaet Berlin (FUB).
  * Copyright (C) 2013, INRIA.
@@ -45,7 +45,7 @@ static void(*find_handler(const shell_command_t *command_list, char *command))(c
     const shell_command_t *entry;
 
     /* iterating over command_lists */
-    for (unsigned int i = 0; i < sizeof(command_lists)/sizeof(entry); i++) {
+    for (unsigned int i = 0; i < sizeof(command_lists) / sizeof(entry); i++) {
         if ((entry = command_lists[i])) {
             /* iterating over commands in command_lists entry */
             while (entry->name != NULL) {
@@ -77,7 +77,7 @@ static void print_help(const shell_command_t *command_list)
     const shell_command_t *entry;
 
     /* iterating over command_lists */
-    for (unsigned int i = 0; i < sizeof(command_lists)/sizeof(entry); i++) {
+    for (unsigned int i = 0; i < sizeof(command_lists) / sizeof(entry); i++) {
         if ((entry = command_lists[i])) {
             /* iterating over commands in command_lists entry */
             while (entry->name != NULL) {
@@ -90,7 +90,7 @@ static void print_help(const shell_command_t *command_list)
 
 static void handle_input_line(shell_t *shell, char *line)
 {
-    char line_copy[SHELL_BUFFER_SIZE];
+    char line_copy[shell->shell_buffer_size];
     char *saveptr;
     strncpy(line_copy, line, sizeof(line_copy));
     char *command = strtok_r(line_copy, " ", &saveptr);
@@ -152,7 +152,7 @@ static inline void print_prompt(shell_t *shell)
 
 void shell_run(shell_t *shell)
 {
-    char line_buf[SHELL_BUFFER_SIZE];
+    char line_buf[shell->shell_buffer_size];
 
     print_prompt(shell);
 
@@ -167,9 +167,11 @@ void shell_run(shell_t *shell)
     }
 }
 
-void shell_init(shell_t *shell, const shell_command_t *shell_commands, int(*readchar)(void), void(*put_char)(int))
+void shell_init(shell_t *shell, const shell_command_t *shell_commands,
+                uint16_t shell_buffer_size, int(*readchar)(void), void(*put_char)(int))
 {
     shell->command_list = shell_commands;
+    shell->shell_buffer_size = shell_buffer_size;
     shell->readchar = readchar;
     shell->put_char = put_char;
 }
diff --git a/sys/uart0/uart0.c b/sys/uart0/uart0.c
index 5153f408d644db73612c4a99bc09b3bde8e6c5c8..40d7b714b05cdb3bcdc358020f20953670865b64 100644
--- a/sys/uart0/uart0.c
+++ b/sys/uart0/uart0.c
@@ -1,5 +1,6 @@
 #include <stdio.h>
 
+#include "cpu-conf.h"
 #include "chardev_thread.h"
 #include "ringbuffer.h"
 #include "thread.h"
@@ -9,7 +10,10 @@
 
 #include "board_uart0.h"
 
-#define UART0_BUFSIZE 		(32)
+#ifndef UART0_BUFSIZE
+#define UART0_BUFSIZE       (128)
+#endif
+
 #define UART0_STACKSIZE 	(MINIMUM_STACK_SIZE + 256)
 
 ringbuffer_t uart0_ringbuffer;
@@ -28,13 +32,13 @@ void board_uart0_init(void)
 {
     ringbuffer_init(&uart0_ringbuffer, buffer, UART0_BUFSIZE);
     int pid = thread_create(
-            uart0_thread_stack,
-            sizeof(uart0_thread_stack),
-            PRIORITY_MAIN - 1,
-            CREATE_STACKTEST|CREATE_SLEEPING,
-            uart0_loop,
-            "uart0"
-            );
+                  uart0_thread_stack,
+                  sizeof(uart0_thread_stack),
+                  PRIORITY_MAIN - 1,
+                  CREATE_STACKTEST | CREATE_SLEEPING,
+                  uart0_loop,
+                  "uart0"
+              );
     uart0_handler_pid = pid;
     thread_wakeup(pid);
     puts("uart0_init() [OK]");