Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/python
# -*- coding: utf-8 -*-
import cmd, serial, sys, socket, threading, readline, time, os
if __name__ == "__main__":
ser = serial.Serial(port="/dev/ttyUSB0", baudrate=115200, dsrdtr=0, rtscts=0)
ser.setDTR(0)
ser.setRTS(0)
2013-12-23 16:59:37,956 - INFO # pid | name | state Q | pri | stack ( used) location | runtime | switches
2013-12-23 16:59:37,964 - INFO # 0 | idle | pending Q | 31 | 160 ( 148) 0x4000000c | nan% | 4294967295
2013-12-23 16:59:37,976 - INFO # 1 | main | running Q | 15 | 4608 ( 2284) 0x400000ac | nan% | 4294967295
2013-12-23 16:59:37,981 - INFO # 2 | uart0 | bl rx _ | 14 | 324 ( 236) 0x40001398 | nan% | 4294967295
2013-12-23 16:59:37,991 - INFO # 3 | udp_packet_handler | bl rx _ | 15 | 4608 ( 208) 0x40008de0 | nan% | 4294967295
2013-12-23 16:59:38,000 - INFO # 4 | tcp_packet_handler | bl rx _ | 15 | 512 ( 200) 0x40008bdc | nan% | 4294967295
2013-12-23 16:59:38,013 - INFO # 5 | tcp_general_timer | sleeping _ | 16 | 512 ( 216) 0x40009ff0 | nan% | 4294967295
2013-12-23 16:59:38,018 - INFO # 6 | radio | bl rx _ | 13 | 4608 ( 212) 0x40006d5c |
Program received signal SIGSEGV, Segmentation fault.
0x0804a727 in native_isr_entry (sig=29, info=0x808f44c <sigalt_stk+7212>,
context=0x808f4cc <sigalt_stk+7340>) at irq_cpu.c:319
319 _native_cur_ctx = (ucontext_t *)active_thread->sp;
(gdb) bt
#0 0x0804a727 in native_isr_entry (sig=29, info=0x808f44c <sigalt_stk+7212>,
context=0x808f4cc <sigalt_stk+7340>) at irq_cpu.c:319
#1 <signal handler called>
#2 0xf7fdb430 in __kernel_vsyscall ()
#3 0xf7ecc933 in write () from /lib/i386-linux-gnu/libc.so.6
diff --cc native/drivers/native-uart0.c
index 7e8489b,38720fd..0000000
--- a/native/drivers/native-uart0.c
+++ b/native/drivers/native-uart0.c
@@@ -8,15 -8,6 +8,18 @@@
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
++<<<<<<< HEAD
+#include <sys/types.h>
@benpicco
benpicco / main.c
Created October 28, 2013 16:38
second message is lost
#include <stdio.h>
#include "vtimer.h"
#include "thread.h"
#include "msg.h"
char timer_stack[KERNEL_CONF_STACKSIZE_DEFAULT];
struct timer_msg {
char* msg;
@benpicco
benpicco / main.c
Created October 28, 2013 04:09
Calculation gets interrupted, one timer is lost
#include <stdio.h>
#include "vtimer.h"
#include "thread.h"
#include "msg.h"
char timer_stack[KERNEL_CONF_STACKSIZE_DEFAULT];
struct timer_msg {
vtimer_t timer;